[PATCH] D19310: X86 TRUNCATE (v16i32 to v16i8) cost change in SSE4.1 mode

Ashutosh Nema via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 20 08:00:55 PDT 2016


ashutosh.nema updated this revision to Diff 54371.
ashutosh.nema added a comment.

Incorporated comments from Simon.


Repository:
  rL LLVM

http://reviews.llvm.org/D19310

Files:
  lib/Target/X86/X86TargetTransformInfo.cpp
  test/Analysis/CostModel/X86/sse-itoi.ll

Index: test/Analysis/CostModel/X86/sse-itoi.ll
===================================================================
--- test/Analysis/CostModel/X86/sse-itoi.ll
+++ test/Analysis/CostModel/X86/sse-itoi.ll
@@ -279,7 +279,7 @@
 ; SSE2: cost of 7 {{.*}} trunc
 ;
 ; SSE41: truncate_v16i32_to_v16i8
-; SSE41: cost of 30 {{.*}} trunc
+; SSE41: cost of 7 {{.*}} trunc
 ;
   %1 = load <16 x i32>, <16 x i32>* %a
   %2 = trunc <16 x i32> %1 to <16 x i8>
Index: lib/Target/X86/X86TargetTransformInfo.cpp
===================================================================
--- lib/Target/X86/X86TargetTransformInfo.cpp
+++ lib/Target/X86/X86TargetTransformInfo.cpp
@@ -731,10 +731,8 @@
     { ISD::TRUNCATE,    MVT::v16i16, MVT::v16i32, 6 },
     { ISD::TRUNCATE,    MVT::v8i16,  MVT::v8i32,  3 },
     { ISD::TRUNCATE,    MVT::v4i16,  MVT::v4i32,  1 },
-    { ISD::TRUNCATE,    MVT::v16i8,  MVT::v16i32, 30 },
     { ISD::TRUNCATE,    MVT::v8i8,   MVT::v8i32,  3 },
     { ISD::TRUNCATE,    MVT::v4i8,   MVT::v4i32,  1 },
-    { ISD::TRUNCATE,    MVT::v16i8,  MVT::v16i16, 3 },
     { ISD::TRUNCATE,    MVT::v8i8,   MVT::v8i16,  1 },
     { ISD::TRUNCATE,    MVT::v4i8,   MVT::v4i16,  2 },
   };


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D19310.54371.patch
Type: text/x-patch
Size: 1185 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160420/b0240b39/attachment.bin>


More information about the llvm-commits mailing list