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

Semantics discrepancy in input to M calls in BIR generation #136

Open
Keryan-dev opened this issue Feb 25, 2022 · 0 comments
Open

Semantics discrepancy in input to M calls in BIR generation #136

Keryan-dev opened this issue Feb 25, 2022 · 0 comments

Comments

@Keryan-dev
Copy link
Collaborator

In Mpp_ir_to_bir.wrap_m_code_call, some assignments of the Mir program are set as input definition, regardless of the M actual definition, before converting them as Bir instructions.
When we consider M call as rules this has no effect on the generated Bir code as body of rules are converted elsewhere. In case on rule inlining (such as in an optimization setting) however, this will lead to affectations disappearing from the code. To my knowledge, this is not what the current INTER files would do, as it will call rule functions with all their assignments in place regardless of context.

I fear the only reason we haven't caught on this semantic discrepancy is because M++ files only assign variables that were already considered input by the M code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant