diff options
author | Arnold Schwaighofer <aschwaighofer@apple.com> | 2013-04-17 20:04:53 +0000 |
---|---|---|
committer | Arnold Schwaighofer <aschwaighofer@apple.com> | 2013-04-17 20:04:53 +0000 |
commit | 9c63f0d687cf1130ee2e76a6fdc87d71ae9d3961 (patch) | |
tree | c2cf4c26228e0545ebb5e74407fd3e3fc9db094e /test/Analysis/CostModel | |
parent | d58b50b99b04bcb8199c2b0273618b6a37d61015 (diff) | |
download | external_llvm-9c63f0d687cf1130ee2e76a6fdc87d71ae9d3961.zip external_llvm-9c63f0d687cf1130ee2e76a6fdc87d71ae9d3961.tar.gz external_llvm-9c63f0d687cf1130ee2e76a6fdc87d71ae9d3961.tar.bz2 |
X86 cost model: Exit before calling getSimpleVT on non-simple VTs
getSimpleVT can only handle simple value types.
radar://13676022
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@179714 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Analysis/CostModel')
-rw-r--r-- | test/Analysis/CostModel/X86/uitofp.ll | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/Analysis/CostModel/X86/uitofp.ll b/test/Analysis/CostModel/X86/uitofp.ll index aed3f2a..a41a04d 100644 --- a/test/Analysis/CostModel/X86/uitofp.ll +++ b/test/Analysis/CostModel/X86/uitofp.ll @@ -1,6 +1,11 @@ ; RUN: llc -mtriple=x86_64-apple-darwin -mcpu=core2 < %s | FileCheck --check-prefix=SSE2-CODEGEN %s ; RUN: opt -mtriple=x86_64-apple-darwin -mcpu=core2 -cost-model -analyze < %s | FileCheck --check-prefix=SSE2 %s +; In X86TargetTransformInfo::getCastInstrCost we have code that depends on +; getSimpleVT on a value type. On AVX2 we execute this code. Make sure we exit +; early if the type is not a simple value type before we call this function. +; RUN: opt -mtriple=x86_64-apple-darwin -mcpu=core-avx2 -cost-model -analyze < %s + define <2 x double> @uitofpv2i8v2double(<2 x i8> %a) { ; SSE2: uitofpv2i8v2double ; SSE2: cost of 20 {{.*}} uitofp @@ -360,3 +365,4 @@ define <32 x float> @uitofpv32i64v32float(<32 x i64> %a) { %1 = uitofp <32 x i64> %a to <32 x float> ret <32 x float> %1 } + |