summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2007-05-04 00:51:23 +0000
committerChris Lattner <sabre@nondot.org>2007-05-04 00:51:23 +0000
commit2b1b18b2db78d7b1d8a1e3b4ea51c21345e6db86 (patch)
tree65b2ea7095bf45d14f5d226a9197e38eead41bd2
parent874eb28ee6ad17e54b9d446decf6d311720c5f54 (diff)
downloadbcm5719-llvm-2b1b18b2db78d7b1d8a1e3b4ea51c21345e6db86.tar.gz
bcm5719-llvm-2b1b18b2db78d7b1d8a1e3b4ea51c21345e6db86.zip
new testcase
llvm-svn: 36722
-rw-r--r--llvm/test/C++Frontend/2007-05-03-VectorInit.cpp17
1 files changed, 17 insertions, 0 deletions
diff --git a/llvm/test/C++Frontend/2007-05-03-VectorInit.cpp b/llvm/test/C++Frontend/2007-05-03-VectorInit.cpp
new file mode 100644
index 00000000000..b87f4d4665c
--- /dev/null
+++ b/llvm/test/C++Frontend/2007-05-03-VectorInit.cpp
@@ -0,0 +1,17 @@
+// RUN: %llvmgxx %s -S -emit-llvm -O0 -o -
+// PR1378
+
+typedef float v4sf __attribute__((vector_size(16)));
+
+typedef v4sf float4;
+
+static float4 splat4(float a)
+{
+ float4 tmp = {a,a,a,a};
+ return tmp;
+}
+
+float4 foo(float a)
+{
+ return splat4(a);
+}
OpenPOWER on IntegriCloud