Enable SSEDomainFix pass for AVX mode.

llvm-svn: 139816
This commit is contained in:
Bruno Cardoso Lopes 2011-09-15 18:27:32 +00:00
parent c94c967656
commit 62d79875d3
1 changed files with 7 additions and 4 deletions

View File

@ -130,16 +130,19 @@ bool X86TargetMachine::addPostRegAlloc(PassManagerBase &PM,
bool X86TargetMachine::addPreEmitPass(PassManagerBase &PM,
CodeGenOpt::Level OptLevel) {
if (OptLevel != CodeGenOpt::None && Subtarget.hasSSE2()) {
bool ShouldPrint = false;
if (OptLevel != CodeGenOpt::None &&
(Subtarget.hasSSE2() || Subtarget.hasAVX())) {
PM.add(createSSEDomainFixPass());
return true;
ShouldPrint = true;
}
if (Subtarget.hasAVX() && UseVZeroUpper) {
PM.add(createX86IssueVZeroUpperPass());
return true;
ShouldPrint = true;
}
return false;
return ShouldPrint;
}
bool X86TargetMachine::addCodeEmitter(PassManagerBase &PM,