[PATCH] D18234: [WebAssembly] Stackify code emitted by eliminateFrameIndex and SP writeback
Derek Schuff via llvm-commits
llvm-commits at lists.llvm.org
Wed Mar 16 17:28:27 PDT 2016
dschuff created this revision.
dschuff added reviewers: sunfish, jfb.
dschuff added a subscriber: llvm-commits.
Herald added subscribers: dschuff, jfb.
MRI::eliminateFrameIndex can emit several instructions to do address
calculations; these can usually be stackified. Because instructions with
FI operands can have subsequent operands which may be expression trees,
find the top of the leftmost tree and insert the code before it, to keep
the LIFO property.
Also use stackified registers when writing back the SP value to memory
in the epilog; it's unnecessary because SP will not be used after the
epilog, and it results in better code.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 14938 bytes
Desc: not available
More information about the llvm-commits