{"action":"created","issue":{"url":"https://api.github.com/repos/MiniZinc/libminizinc/issues/112","repository_url":"https://api.github.com/repos/MiniZinc/libminizinc","labels_url":"https://api.github.com/repos/MiniZinc/libminizinc/issues/112/labels{/name}","comments_url":"https://api.github.com/repos/MiniZinc/libminizinc/issues/112/comments","events_url":"https://api.github.com/repos/MiniZinc/libminizinc/issues/112/events","html_url":"https://github.com/MiniZinc/libminizinc/issues/112","id":172855724,"number":112,"title":"Disappearing redefinitions of linear constraints","user":{"login":"nickd4","id":21211188,"avatar_url":"https://avatars3.githubusercontent.com/u/21211188?v=4","gravatar_id":"","url":"https://api.github.com/users/nickd4","html_url":"https://github.com/nickd4","followers_url":"https://api.github.com/users/nickd4/followers","following_url":"https://api.github.com/users/nickd4/following{/other_user}","gists_url":"https://api.github.com/users/nickd4/gists{/gist_id}","starred_url":"https://api.github.com/users/nickd4/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nickd4/subscriptions","organizations_url":"https://api.github.com/users/nickd4/orgs","repos_url":"https://api.github.com/users/nickd4/repos","events_url":"https://api.github.com/users/nickd4/events{/privacy}","received_events_url":"https://api.github.com/users/nickd4/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-08-24T03:18:44Z","updated_at":"2017-10-04T06:24:35Z","closed_at":"2017-10-04T06:24:35Z","author_association":"NONE","body":"I notice that 2.0.13 changelog lists the following entry:\n\"Fix a bug in the Common Subexpression Elimination table of the compiler, which could lead to some constraints being dropped (especially when using linear redefinitions).\"\n\nWe still seem to have a problem like this, as of 2.0.14. I'm trying to run Opturion CPX using Minizinc 2.0 as the frontend/compiler, but the mznlib from Opturion CPX does not work properly with new Minizinc.\n\nIt seems Opturion CPX relies on translating constraints like int_ne_reif to int_lin_ne_reif, which is a sensible thing to do (I tried doing the same in my own work earlier this year, but gave up due to the same strange translation issues, and ended up just putting the same translation in my Flatzinc solver binary instead of doing it in Minizinc).\n\nI have checked into this problem and discovered it's a regression Minizinc 2.0.8 -> 2.0.9. I have attached the necessary files to duplicate the issue. When the issue occurs (with Minizinc 2.0.9), the generated Flatzinc is significantly shorter and does not contain the int_lin_ne_reif constraints or the variables associated with them. So it just defines a trivial grid colouring problem where all cells can be set to 1 and the objective comes out as 1. When the issue does not occur (with Minizinc 2.0.8) the generated Flatzinc has \"int_lin_ne_reif\" constraints in it and solves correctly with Opturion CPX.\n\n[int_lin_ne_reif_issue.zip](https://github.com/MiniZinc/libminizinc/files/433969/int_lin_ne_reif_issue.zip)\n"},"comment":{"url":"https://api.github.com/repos/MiniZinc/libminizinc/issues/comments/334061019","html_url":"https://github.com/MiniZinc/libminizinc/issues/112#issuecomment-334061019","issue_url":"https://api.github.com/repos/MiniZinc/libminizinc/issues/112","id":334061019,"user":{"login":"Dekker1","id":1564252,"avatar_url":"https://avatars1.githubusercontent.com/u/1564252?v=4","gravatar_id":"","url":"https://api.github.com/users/Dekker1","html_url":"https://github.com/Dekker1","followers_url":"https://api.github.com/users/Dekker1/followers","following_url":"https://api.github.com/users/Dekker1/following{/other_user}","gists_url":"https://api.github.com/users/Dekker1/gists{/gist_id}","starred_url":"https://api.github.com/users/Dekker1/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Dekker1/subscriptions","organizations_url":"https://api.github.com/users/Dekker1/orgs","repos_url":"https://api.github.com/users/Dekker1/repos","events_url":"https://api.github.com/users/Dekker1/events{/privacy}","received_events_url":"https://api.github.com/users/Dekker1/received_events","type":"User","site_admin":false},"created_at":"2017-10-04T06:24:35Z","updated_at":"2017-10-04T06:24:35Z","author_association":"CONTRIBUTOR","body":"This issue is being closed in a cleanup of our GitHub repository. It seems it\r\nhas been fully discussed to not be an (compiler) issue, already solved, or no\r\nlonger relevant.\r\n\r\nIf this not be the case, feel free to comment below and we'll reconsider the\r\nissue again."}}
{"actor":{"display_login":"Dekker1"}}