diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/CodeGen/CGBuiltin.cpp | 2 | ||||
-rw-r--r-- | lib/Headers/x86intrin.h | 6 |
2 files changed, 7 insertions, 1 deletions
diff --git a/lib/CodeGen/CGBuiltin.cpp b/lib/CodeGen/CGBuiltin.cpp index 038631e5ca..ff25609b67 100644 --- a/lib/CodeGen/CGBuiltin.cpp +++ b/lib/CodeGen/CGBuiltin.cpp @@ -2240,6 +2240,8 @@ Value *CodeGenFunction::EmitX86BuiltinExpr(unsigned BuiltinID, ID = Intrinsic::x86_3dnowa_pswapd; break; } + llvm::Type *MMXTy = llvm::Type::getX86_MMXTy(getLLVMContext()); + Ops[0] = Builder.CreateBitCast(Ops[0], MMXTy, "cast"); llvm::Function *F = CGM.getIntrinsic(ID); return Builder.CreateCall(F, Ops, name); } diff --git a/lib/Headers/x86intrin.h b/lib/Headers/x86intrin.h index 5f9bea7107..f5e4d883e8 100644 --- a/lib/Headers/x86intrin.h +++ b/lib/Headers/x86intrin.h @@ -26,6 +26,10 @@ #include <immintrin.h> +#ifdef __3dNOW__ +#include <mm3dnow.h> +#endif + #ifdef __BMI__ #include <bmiintrin.h> #endif @@ -46,6 +50,6 @@ #include <fma4intrin.h> #endif -// FIXME: SSE4A, 3dNOW, XOP, LWP, ABM +// FIXME: SSE4A, XOP, LWP, ABM #endif /* __X86INTRIN_H */ |