Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

JavaSMT term transforming: inproper handling of function declarations #270

Open
RipplB opened this issue Jun 22, 2024 · 3 comments
Open
Assignees
Labels
solver Issue is mainly about SMT solvers

Comments

@RipplB
Copy link
Contributor

RipplB commented Jun 22, 2024

Currently in JavaSMTTermTransformer#transformApp, we are depending on the name of the function declaration to match in the environment variable. I believe (might not be true) that this is not standardized across solvers, for example some names back from mathsat5:

  • `not` while we are expecting not
  • `<=int` while we are expecting <=

JavaSMT helps however through FunctionDeclaration#getKind which returns a value from FunctionDeclarationKind. We should probably switch from String keys to FunctionDeclarationKind keys in the environment map, and use the getKind as lookup instead of getName.

@leventeBajczi
Copy link
Contributor

You're right, we should not be using the string keys. Can you possibly send in a fix?

@RipplB
Copy link
Contributor Author

RipplB commented Jun 25, 2024

My next PR will include the proposed fix, but won't be perfect - for some of our existing cases I could not find the proper counterpart, and many of their options will be unhandled.

@leventeBajczi
Copy link
Contributor

Please document these cases here, and we'll ask @baierd for some help. Thanks!

@RipplB RipplB mentioned this issue Jul 6, 2024
@AdamZsofi AdamZsofi added the solver Issue is mainly about SMT solvers label Nov 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
solver Issue is mainly about SMT solvers
Projects
None yet
Development

No branches or pull requests

3 participants