Do not model all INLINEASM instructions as having unmodelled side effects.
authorEvan Cheng <evan.cheng@apple.com>
Fri, 7 Jan 2011 23:50:32 +0000 (23:50 +0000)
committerEvan Cheng <evan.cheng@apple.com>
Fri, 7 Jan 2011 23:50:32 +0000 (23:50 +0000)
commitc36b7069b42bece963b7e6adf020353ce990ef76
treefdbe6e1cede36ae3485403b9165bfdc039056eeb
parent067a16c974fef473fd3bca1d58db0d50c59882ce
Do not model all INLINEASM instructions as having unmodelled side effects.
Instead encode llvm IR level property "HasSideEffects" in an operand (shared
with IsAlignStack). Added MachineInstrs::hasUnmodeledSideEffects() to check
the operand when the instruction is an INLINEASM.

This allows memory instructions to be moved around INLINEASM instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123044 91177308-0d34-0410-b5e6-96231b3b80d8
21 files changed:
include/llvm/CodeGen/ISDOpcodes.h
include/llvm/CodeGen/MachineInstr.h
include/llvm/InlineAsm.h
include/llvm/Target/Target.td
lib/CodeGen/AsmPrinter/AsmPrinterInlineAsm.cpp
lib/CodeGen/DeadMachineInstructionElim.cpp
lib/CodeGen/MachineCSE.cpp
lib/CodeGen/MachineInstr.cpp
lib/CodeGen/PeepholeOptimizer.cpp
lib/CodeGen/PrologEpilogInserter.cpp
lib/CodeGen/ScheduleDAGInstrs.cpp
lib/CodeGen/SelectionDAG/InstrEmitter.cpp
lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
lib/CodeGen/TargetInstrInfoImpl.cpp
lib/CodeGen/TwoAddressInstructionPass.cpp
lib/CodeGen/VirtRegRewriter.cpp
lib/Target/ARM/ARMLoadStoreOptimizer.cpp
lib/Target/MBlaze/MBlazeDelaySlotFiller.cpp
lib/Target/X86/X86FastISel.cpp
test/CodeGen/X86/2008-09-17-inline-asm-1.ll