[llvm-commits] Please Review: AVX code optimization

Demikhovsky, Elena elena.demikhovsky at intel.com
Wed Jul 11 03:34:01 PDT 2012


I'm not sure that all architectures will see performance gain. 
While building shuffles, I know that each shuffle will be replaced with one machine instruction.
I also know that shuffle is cheaper (1 cycle) than extract (3 cycles) and insert (2 cycles). 
I know that blend is better than other shuffle. And this information is specific for X86 and written in IA optimization guide.

- Elena
-----Original Message-----
From: Nick Lewycky [mailto:nicholas at mxc.ca] 
Sent: Wednesday, July 11, 2012 11:47
To: Demikhovsky, Elena
Cc: Commit Messages and Patches for LLVM
Subject: Re: [llvm-commits] Please Review: AVX code optimization

Demikhovsky, Elena wrote:
> I wrote an optimization for extractelement - insertelement sequences.
> Please review.

It looks like this is a dagcombine to turn insertelement+extractelement pairs into vector shuffles. Perhaps I'm missing a good reason, but why not do this as an IR optimization?

Nick
---------------------------------------------------------------------
Intel Israel (74) Limited

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.





More information about the llvm-commits mailing list