diff options
-rw-r--r-- | lib/CodeGen/TargetInfo.cpp | 8 | ||||
-rw-r--r-- | test/CodeGen/x86_64-arguments.c | 11 |
2 files changed, 10 insertions, 9 deletions
diff --git a/lib/CodeGen/TargetInfo.cpp b/lib/CodeGen/TargetInfo.cpp index a08e7f4b80..c5b858dbfa 100644 --- a/lib/CodeGen/TargetInfo.cpp +++ b/lib/CodeGen/TargetInfo.cpp @@ -1294,12 +1294,8 @@ GetSSETypeAtOffset(const llvm::Type *IRType, unsigned IROffset, // offset+0 and offset+4. Walk the LLVM IR type to find out if this is the // case. if (ContainsFloatAtOffset(IRType, IROffset, getTargetData()) && - ContainsFloatAtOffset(IRType, IROffset+4, getTargetData())) { - // FIXME: <2 x float> doesn't pass as one XMM register yet. Don't enable - // this code until it does. - //return llvm::VectorType::get(llvm::Type::getFloatTy(getVMContext()), 2); - - } + ContainsFloatAtOffset(IRType, IROffset+4, getTargetData())) + return llvm::VectorType::get(llvm::Type::getFloatTy(getVMContext()), 2); return llvm::Type::getDoubleTy(getVMContext()); } diff --git a/test/CodeGen/x86_64-arguments.c b/test/CodeGen/x86_64-arguments.c index 9fd08dd4a8..039dd27869 100644 --- a/test/CodeGen/x86_64-arguments.c +++ b/test/CodeGen/x86_64-arguments.c @@ -1,5 +1,4 @@ -// RUN: %clang_cc1 -triple x86_64-unknown-unknown -emit-llvm -o %t %s -// RUN: FileCheck < %t %s +// RUN: %clang_cc1 -triple x86_64-unknown-unknown -emit-llvm -o - %s| FileCheck %s // CHECK: %0 = type { i64, double } @@ -215,8 +214,14 @@ void f30(struct S0 p_4) { // rdar://8251384 struct f31foo { float a, b, c; }; float f31(struct f31foo X) { - // CHECK: define float @f31(double %X.coerce0, float %X.coerce1) + // CHECK: define float @f31(<2 x float> %X.coerce0, float %X.coerce1) return X.c; } +_Complex float f32(_Complex float A, _Complex float B) { + // rdar://6379669 + // CHECK: define <2 x float> @f32(<2 x float> %A.coerce, <2 x float> %B.coerce) + return A+B; +} + |