[PATCH][X86] Don't mark movabsq as cheap-as-move - it isn't that cheap.

Nadav Rotem nrotem at apple.com
Thu Feb 13 16:56:12 PST 2014


LGTM!

On Feb 13, 2014, at 4:55 PM, Juergen Ributzka <juergen at apple.com> wrote:

> On X86 a simple register copy is just 3 bytes, whereas movabsq is a 10 byte instruction. Marking movabsq as not beeing cheap will allow LICM to move it out of the loop and it also prevents unnecessary rematerializations if the value is needed in more than one register.
> 
> I run the test-suite and got around 5% improvement for hash2 and health, but they are rather small benchmark and very sensitive to changes. SPEC INT2000 perlbmk improved by ~2.4%.
> It also reduced the overall code size for some tiny benchmark up to 10%, but in the context of the whole test-suite the difference is neglegtible.
> 
> Cheers,
> Juergen
> 
> 
> <0001-X86-Don-t-mark-movabsq-as-cheap-as-move-it-isn-t-tha.patch>




More information about the llvm-commits mailing list