aboutsummaryrefslogtreecommitdiff
path: root/test/CodeGen
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2015-02-19 20:57:58 +0000
committerDimitry Andric <dim@FreeBSD.org>2015-02-19 20:57:58 +0000
commitbda3d407185047106bde6af5367ddab7d3a3142f (patch)
treeb0d1eaed14959a7722ff246ffa303348922e9fb5 /test/CodeGen
parentec12bbe359799efc32df6bde5e872cb2713c0b19 (diff)
Notes
Diffstat (limited to 'test/CodeGen')
-rw-r--r--test/CodeGen/x86_64-arguments.c22
1 files changed, 22 insertions, 0 deletions
diff --git a/test/CodeGen/x86_64-arguments.c b/test/CodeGen/x86_64-arguments.c
index 5d01d3bf69ed..e82e7b067ada 100644
--- a/test/CodeGen/x86_64-arguments.c
+++ b/test/CodeGen/x86_64-arguments.c
@@ -184,6 +184,28 @@ struct v4f32wrapper f27(struct v4f32wrapper X) {
return X;
}
+// PR22563 - We should unwrap simple structs and arrays to pass
+// and return them in the appropriate vector registers if possible.
+
+typedef float v8f32 __attribute__((__vector_size__(32)));
+struct v8f32wrapper {
+ v8f32 v;
+};
+
+struct v8f32wrapper f27a(struct v8f32wrapper X) {
+ // AVX-LABEL: define <8 x float> @f27a(<8 x float> %X.coerce)
+ return X;
+}
+
+struct v8f32wrapper_wrapper {
+ v8f32 v[1];
+};
+
+struct v8f32wrapper_wrapper f27b(struct v8f32wrapper_wrapper X) {
+ // AVX-LABEL: define <8 x float> @f27b(<8 x float> %X.coerce)
+ return X;
+}
+
// rdar://5711709
struct f28c {
double x;