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
Compiler: restore TCO of mutually recursive functions #1539
Conversation
This issue was spotted by a single package (ezjsonm) during the opam release. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don’t exactly understand how global DCE broke tail calls and why this fixes it, so I won’t comment beyond the surface level.
The call to |
Can you explain the reasons ? |
Obviously, it removes the deadcode introduced by |
d8fee6c
to
5c1923f
Compare
|
I've opened #1540 to get rid of rewrite_mutable. Is this the only reason ? |
I think so. |
@vouillon. @micahcantor #1503 breaks tail call as mentioned by @vouillon
Except the
Generate_closure
pass does care about tail calls as it rewrite mutually recursive functions using a trampoline.Do you see any issue with the change proposed here ?