eirproject / eir

Erlang ecosystem common IR
Apache License 2.0
253 stars 6 forks source link

Implement tail call promotion pass #9

Closed hansihe closed 4 years ago

hansihe commented 5 years ago

Right now there is an unnecessary continuation generated when doing what should be tail calls.

Implement a pass for tail call promotion so the CSP transform pass can correctly omit generating a continuation, and simply pass the return continuations directly.

hansihe commented 4 years ago

This is done by graph simplification pass.