[PATCH] [X86] Convert esp-relative movs of function arguments to pushes, step 1
Michael Kuperstein
michael.m.kuperstein at intel.com
Wed Dec 3 08:06:16 PST 2014
Hi nadav, delena, eliben,
I've started working on using pushes instead of esp-relative movs to pass function arguments.
The main motivation is code size (e.g. 2 bytes instead of 7 to pass an 8-bit immediate), but it some cases it is also faster.
This is just the first step, that handles the simplest case:
1) x86-32 calling convention, everything is passed through the stack.
2) There is no reserved frame (for x86 this happens is there is a dynamic stack allocation in the caller).
Does this look reasonably sane?
http://reviews.llvm.org/D6503
Files:
lib/Target/X86/X86FrameLowering.cpp
lib/Target/X86/X86FrameLowering.h
test/CodeGen/X86/force-align-stack-alloca.ll
test/CodeGen/X86/inalloca-ctor.ll
test/CodeGen/X86/inalloca-invoke.ll
test/CodeGen/X86/inalloca-stdcall.ll
test/CodeGen/X86/mem-intrin-base-reg.ll
test/CodeGen/X86/movtopush.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D6503.16864.patch
Type: text/x-patch
Size: 13073 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20141203/610595c5/attachment.bin>
More information about the llvm-commits
mailing list