mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-20 12:31:40 +00:00
must not peephole away side effects
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@113848 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
1685caffed
commit
4f7d107d1d
@ -269,7 +269,8 @@ bool PeepholeOptimizer::runOnMachineFunction(MachineFunction &MF) {
|
|||||||
MII = I->begin(), MIE = I->end(); MII != MIE; ) {
|
MII = I->begin(), MIE = I->end(); MII != MIE; ) {
|
||||||
MachineInstr *MI = &*MII;
|
MachineInstr *MI = &*MII;
|
||||||
|
|
||||||
if (MI->getDesc().isCompare()) {
|
if (MI->getDesc().isCompare() &&
|
||||||
|
!MI->getDesc().hasUnmodeledSideEffects()) {
|
||||||
if (OptimizeCmpInstr(MI, MBB, MII))
|
if (OptimizeCmpInstr(MI, MBB, MII))
|
||||||
Changed = true;
|
Changed = true;
|
||||||
else
|
else
|
||||||
|
Loading…
x
Reference in New Issue
Block a user