This is an archive of the discontinued LLVM Phabricator instance.

[WebAssembly] Optimize away returns using fallthroughs
ClosedPublic

Authored by sunfish on May 19 2016, 2:59 PM.

Details

Reviewers
dschuff
Summary

In WebAssembly, when control reaches the end of a function body, the function returns automatically, so an explicit return operator isn't needed there. This patch optimizes away these return opcodes.

Diff Detail

Repository
rL LLVM

Event Timeline

sunfish updated this revision to Diff 57861.May 19 2016, 2:59 PM
sunfish retitled this revision from to [WebAssembly] Optimize away returns using fallthroughs.
sunfish updated this object.
sunfish added a reviewer: dschuff.
sunfish set the repository for this revision to rL LLVM.
dschuff accepted this revision.May 19 2016, 11:59 PM
dschuff edited edge metadata.
This revision is now accepted and ready to land.May 19 2016, 11:59 PM
Eugene.Zelenko added a subscriber: Eugene.Zelenko.

Committed in r270294.