[LLVMdev] AVX2 Cost Table in X86TargetTransformInfo

suyog sarda sardask01 at gmail.com
Mon May 4 02:36:32 PDT 2015


Hi all,

I have a query regarding Cost Table for AVX2 in TargetTransformInfo.

The table consist of entries for shift and div operations only. There are
no entries for ADD, SUB and MUL for AVX2 cost table. Those entries are
present in Cost Table for AVX.

The reason for query is - when my sub target feature is AVX2, in SLP
Vectorization,  while calculating scalar cost of ADD, it doesn't see the
entry in cost table and falls back to default implementation returning cost
1. While for AVX, it finds the ADD in cost table and returns 4 as scalar
cost.

I am suspecting this is something specific to architecture difference
between AVX and AVX2. I am naive to architecture specifics in this case.

I would be glad if someone clarifies on this.

Thanks.

Regards,
Suyog Sarda
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20150504/6bef97b3/attachment.html>


More information about the llvm-dev mailing list