[PATCH] SLP Vectorizer: Extract cost will only be added once even if the scalar has multiple external uses

Yi Jiang yjiang at apple.com
Thu Nov 21 17:46:51 PST 2013


Hi Nadav,

Thank you for your comments. I added the test case and the comment in the new patch. 

On Nov 21, 2013, at 2:49 PM, Nadav Rotem <nrotem at apple.com> wrote:

> The change looks good to me but we need a small test case for the change. 
> 
> Thanks,
> Nadav
> 
> On Nov 21, 2013, at 1:59 PM, Yi Jiang <yjiang at apple.com> wrote:
> 
>> Hi,
>> 
>> This patch is about cost model of SLP Vectorizer. Now the extract cost of all external uses of the scalars will be calculated and added up to the total cost. Actually, only once is enough for each scalar even if it has multiple external uses since we usually just generate one extractelement operation.  It will expose more SLP vectorization opportunities on Olden/power and we see 11% improvement on that case. Any comments is highly appreciated. 
>> 
>> MultiSource/Benchmarks/Olden/power/power          -11.41%   1.6936          1.5004
>> 
>> 
>> <slpextractcost.patch>
>> _______________________________________________
>> llvm-commits mailing list
>> llvm-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20131121/a3ae647b/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: slpextractcost.patch
Type: application/octet-stream
Size: 3139 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20131121/a3ae647b/attachment.obj>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20131121/a3ae647b/attachment-0001.html>


More information about the llvm-commits mailing list