summaryrefslogtreecommitdiffstats
path: root/llvm/test
diff options
context:
space:
mode:
authorKrzysztof Parzyszek <kparzysz@codeaurora.org>2017-11-22 20:56:23 +0000
committerKrzysztof Parzyszek <kparzysz@codeaurora.org>2017-11-22 20:56:23 +0000
commit942fa1631f7f3aea7de4e4aec22219f9b7faeeff (patch)
tree648926481bca5a3be5e9e05a709160fa1449938d /llvm/test
parentb9f33b32eeaccdf398910013d6916df2caf1c9db (diff)
downloadbcm5719-llvm-942fa1631f7f3aea7de4e4aec22219f9b7faeeff.tar.gz
bcm5719-llvm-942fa1631f7f3aea7de4e4aec22219f9b7faeeff.zip
[Hexagon] Implement buildVector32 and buildVector64 as utility functions
Change LowerBUILD_VECTOR to use those functions. This commit will tempora- rily affect constant vector generation (it will generate constant-extended values instead of non-extended combines), but the code for the general case should be better. The constant selection part will be fixed later. llvm-svn: 318877
Diffstat (limited to 'llvm/test')
-rw-r--r--llvm/test/CodeGen/Hexagon/constp-combine-neg.ll3
-rw-r--r--llvm/test/CodeGen/Hexagon/vect/vect-cst-v4i32.ll3
-rw-r--r--llvm/test/CodeGen/Hexagon/vect/vect-vsplatb.ll8
3 files changed, 12 insertions, 2 deletions
diff --git a/llvm/test/CodeGen/Hexagon/constp-combine-neg.ll b/llvm/test/CodeGen/Hexagon/constp-combine-neg.ll
index 089d9f6a998..283bd4801e9 100644
--- a/llvm/test/CodeGen/Hexagon/constp-combine-neg.ll
+++ b/llvm/test/CodeGen/Hexagon/constp-combine-neg.ll
@@ -1,3 +1,6 @@
+; XFAIL: *
+; Implement generic selection of a constant.
+
; RUN: llc -O2 -march=hexagon < %s | FileCheck %s --check-prefix=CHECK-TEST1
; RUN: llc -O2 -march=hexagon < %s | FileCheck %s --check-prefix=CHECK-TEST2
; RUN: llc -O2 -march=hexagon < %s | FileCheck %s --check-prefix=CHECK-TEST3
diff --git a/llvm/test/CodeGen/Hexagon/vect/vect-cst-v4i32.ll b/llvm/test/CodeGen/Hexagon/vect/vect-cst-v4i32.ll
index 4bba134a40c..12f9e00f0d0 100644
--- a/llvm/test/CodeGen/Hexagon/vect/vect-cst-v4i32.ll
+++ b/llvm/test/CodeGen/Hexagon/vect/vect-cst-v4i32.ll
@@ -1,3 +1,6 @@
+; XFAIL: *
+; Extract selecting of a constant into a generic utility function.
+;
; RUN: llc -march=hexagon -mcpu=hexagonv5 -disable-hsdr < %s | FileCheck %s
; This one should generate a combine with two immediates.
; CHECK: combine(#7,#7)
diff --git a/llvm/test/CodeGen/Hexagon/vect/vect-vsplatb.ll b/llvm/test/CodeGen/Hexagon/vect/vect-vsplatb.ll
index 097e2ccd600..faea9350a9d 100644
--- a/llvm/test/CodeGen/Hexagon/vect/vect-vsplatb.ll
+++ b/llvm/test/CodeGen/Hexagon/vect/vect-vsplatb.ll
@@ -5,7 +5,7 @@
@A = common global [400 x i8] zeroinitializer, align 8
@C = common global [400 x i8] zeroinitializer, align 8
-define void @run() nounwind {
+define void @run(i8 %v) nounwind {
entry:
br label %polly.loop_body
@@ -19,7 +19,11 @@ polly.loop_body: ; preds = %entry, %polly.loop_
%p_arrayidx = getelementptr [400 x i8], [400 x i8]* @B, i32 0, i32 %polly.loopiv25
%vector_ptr = bitcast i8* %p_arrayidx to <4 x i8>*
%_p_vec_full = load <4 x i8>, <4 x i8>* %vector_ptr, align 8
- %mulp_vec = mul <4 x i8> %_p_vec_full, <i8 7, i8 7, i8 7, i8 7>
+ %vec0 = insertelement <4 x i8> undef, i8 %v, i32 0
+ %vec1 = insertelement <4 x i8> %vec0, i8 %v, i32 1
+ %vec2 = insertelement <4 x i8> %vec1, i8 %v, i32 2
+ %vec3 = insertelement <4 x i8> %vec2, i8 %v, i32 3
+ %mulp_vec = mul <4 x i8> %_p_vec_full, %vec3
%vector_ptr14 = bitcast i8* %p_arrayidx1 to <4 x i8>*
%_p_vec_full15 = load <4 x i8>, <4 x i8>* %vector_ptr14, align 8
%addp_vec = add <4 x i8> %_p_vec_full15, %mulp_vec
OpenPOWER on IntegriCloud