Author: evancheng
Date: Thu Dec 20 18:24:17 2007
New Revision: 45275

URL: http://llvm.org/viewvc/llvm-project?rev=45275&view=rev
Log:
Bug fix: parameter is i32 so create a v4i32 and then cast it to v8i16.

Modified:
    llvm-gcc-4.2/trunk/gcc/config/i386/llvm-i386.cpp

Modified: llvm-gcc-4.2/trunk/gcc/config/i386/llvm-i386.cpp
URL: 
http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/config/i386/llvm-i386.cpp?rev=45275&r1=45274&r2=45275&view=diff

==============================================================================
--- llvm-gcc-4.2/trunk/gcc/config/i386/llvm-i386.cpp (original)
+++ llvm-gcc-4.2/trunk/gcc/config/i386/llvm-i386.cpp Thu Dec 20 18:24:17 2007
@@ -191,6 +191,7 @@
       Intrinsic::getDeclaration(TheModule, Intrinsic::x86_sse2_psra_w);
     Value *Undef = UndefValue::get(Type::Int32Ty);
     Ops[1] = BuildVector(Ops[1], Undef, Undef, Undef, NULL);
+    Ops[1] = Builder.CreateBitCast(Ops[1], Ops[0]->getType(), "tmp");
     Result = Builder.CreateCall(psraw, Ops.begin(), Ops.begin()+2, "tmp");
     Result = Builder.CreateBitCast(Result, ResultType, "tmp");
     return true;


_______________________________________________
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits

Reply via email to