AVX: Fix bug with misdeclaration of blend intrinsic.

This was preventing the "convert an all-on blend to one of the
  operand values" optimization from kicking on in AVX.
This commit is contained in:
Matt Pharr
2011-09-12 06:42:38 -07:00
parent cf23cf9ef4
commit 6375ed9224

View File

@@ -424,8 +424,11 @@ IntrinsicsOpt::IntrinsicsOpt()
blendInstructions.push_back(BlendInstruction(
llvm::Intrinsic::getDeclaration(m->module, llvm::Intrinsic::x86_sse41_blendvps),
0xf, 0, 1, 2));
#if defined(LLVM_3_0) || defined(LLVM_3_0svn)
blendInstructions.push_back(BlendInstruction(
m->module->getFunction("llvm.x86.avx.blendvps"), 0xff, 0, 1, 2));
llvm::Intrinsic::getDeclaration(m->module, llvm::Intrinsic::x86_avx_blendv_ps_256),
0xff, 0, 1, 2));
#endif
}