You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now DCE is run in a single pass at the Program.exit. But this blocks other optimisations that could be performed after DCE - such as simplify.
an example - from #420 ... if_return optimisation (simplify) after DCE is not happening here because DCE is at the end, and requires a second pass.
Also, if the function is an arrow function, after DCE, an arrow function with a single return statement could be further simplified to remove the BlockStatement, which is also not happening now because of the same reasons.
// inputfunctionfoo(...args){if(!i)return;else{constx={args};while(false);returnx;}};// outfunctionfoo(...a){if(!i)return;return{args: a};}// could reduce tofunctionfoo(...a){if(i)return{args: a};}
The text was updated successfully, but these errors were encountered:
Related #61 , #317
Right now DCE is run in a single pass at the Program.exit. But this blocks other optimisations that could be performed after DCE - such as simplify.
an example - from #420 ... if_return optimisation (simplify) after DCE is not happening here because DCE is at the end, and requires a second pass.
Also, if the function is an arrow function, after DCE, an arrow function with a single return statement could be further simplified to remove the BlockStatement, which is also not happening now because of the same reasons.
The text was updated successfully, but these errors were encountered: