diff options
author | Benjamin Kramer <benny.kra@googlemail.com> | 2013-10-23 21:06:07 +0000 |
---|---|---|
committer | Benjamin Kramer <benny.kra@googlemail.com> | 2013-10-23 21:06:07 +0000 |
commit | bb41c75ab51fcfc3ad36d3f8a438652b141e0fc0 (patch) | |
tree | 1bb8f7c09feb260afbdaedf1b4ce48f42c0d3024 /lib/Target/X86/X86TargetTransformInfo.cpp | |
parent | d7da59004fc9262f33c96ad2736b36ff1235ce7b (diff) | |
download | external_llvm-bb41c75ab51fcfc3ad36d3f8a438652b141e0fc0.zip external_llvm-bb41c75ab51fcfc3ad36d3f8a438652b141e0fc0.tar.gz external_llvm-bb41c75ab51fcfc3ad36d3f8a438652b141e0fc0.tar.bz2 |
X86: Custom lower sext v16i8 to v16i16, and the corresponding truncate.
Also update the cost model.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193270 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/X86/X86TargetTransformInfo.cpp')
-rw-r--r-- | lib/Target/X86/X86TargetTransformInfo.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/Target/X86/X86TargetTransformInfo.cpp b/lib/Target/X86/X86TargetTransformInfo.cpp index 36bfeb1..f88a666 100644 --- a/lib/Target/X86/X86TargetTransformInfo.cpp +++ b/lib/Target/X86/X86TargetTransformInfo.cpp @@ -401,12 +401,15 @@ unsigned X86TTI::getCastInstrCost(unsigned Opcode, Type *Dst, Type *Src) const { static const TypeConversionCostTblEntry<MVT::SimpleValueType> AVXConversionTbl[] = { + { ISD::SIGN_EXTEND, MVT::v16i16, MVT::v16i8, 1 }, + { ISD::ZERO_EXTEND, MVT::v16i16, MVT::v16i8, 1 }, { ISD::SIGN_EXTEND, MVT::v8i32, MVT::v8i16, 1 }, { ISD::ZERO_EXTEND, MVT::v8i32, MVT::v8i16, 1 }, { ISD::SIGN_EXTEND, MVT::v4i64, MVT::v4i32, 1 }, { ISD::ZERO_EXTEND, MVT::v4i64, MVT::v4i32, 1 }, { ISD::TRUNCATE, MVT::v4i32, MVT::v4i64, 1 }, { ISD::TRUNCATE, MVT::v8i16, MVT::v8i32, 1 }, + { ISD::TRUNCATE, MVT::v16i8, MVT::v16i16, 2 }, { ISD::SINT_TO_FP, MVT::v8f32, MVT::v8i1, 8 }, { ISD::SINT_TO_FP, MVT::v8f32, MVT::v8i8, 8 }, |