summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@gmail.com>2020-01-13 22:02:45 -0800
committerCraig Topper <craig.topper@gmail.com>2020-01-13 22:02:45 -0800
commitb1dcd84c7ea3c97ddd73f629441be24791f23624 (patch)
tree7a81dc3a62e380e5a8d48badaf0bcea6cfff871e /llvm/lib
parent1768ed7f8b1f53b5b4b3ff80da6ae2dce22b74a9 (diff)
downloadbcm5719-llvm-b1dcd84c7ea3c97ddd73f629441be24791f23624.tar.gz
bcm5719-llvm-b1dcd84c7ea3c97ddd73f629441be24791f23624.zip
[X86] Copy the nofpexcept flag when folding a load into an instruction using the load folding tables./
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/Target/X86/X86InstrInfo.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/llvm/lib/Target/X86/X86InstrInfo.cpp b/llvm/lib/Target/X86/X86InstrInfo.cpp
index f41a27aba3f..245346d8273 100644
--- a/llvm/lib/Target/X86/X86InstrInfo.cpp
+++ b/llvm/lib/Target/X86/X86InstrInfo.cpp
@@ -4704,6 +4704,10 @@ static MachineInstr *FuseInst(MachineFunction &MF, unsigned Opcode,
updateOperandRegConstraints(MF, *NewMI, TII);
+ // Copy the NoFPExcept flag from the instruction we're fusing.
+ if (MI.getFlag(MachineInstr::MIFlag::NoFPExcept))
+ NewMI->setFlag(MachineInstr::MIFlag::NoFPExcept);
+
MachineBasicBlock *MBB = InsertPt->getParent();
MBB->insert(InsertPt, NewMI);
OpenPOWER on IntegriCloud