Change TII::foldMemoryOperand API to require the machine instruction to be
authorJakob Stoklund Olesen <stoklund@2pi.dk>
Fri, 9 Jul 2010 17:29:08 +0000 (17:29 +0000)
committerJakob Stoklund Olesen <stoklund@2pi.dk>
Fri, 9 Jul 2010 17:29:08 +0000 (17:29 +0000)
commite05442d50806e2850eae1571958816028093df85
tree09a695fc42188f75cef100c5da5994bc8c411f99
parente664267ae7af018a5e3802667e5420f8e8282888
Change TII::foldMemoryOperand API to require the machine instruction to be
inserted in a MBB, and return an already inserted MI.

This target API change is necessary to allow foldMemoryOperand to call
storeToStackSlot and loadFromStackSlot when folding a COPY to a stack slot
reference in a target independent way.

The foldMemoryOperandImpl hook is going to change in the same way, but I'll wait
until COPY folding is actually implemented. Most targets only fold copies and
won't need to specialize this hook at all.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107991 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/Target/TargetInstrInfo.h
lib/CodeGen/InlineSpiller.cpp
lib/CodeGen/LiveIntervalAnalysis.cpp
lib/CodeGen/PreAllocSplitting.cpp
lib/CodeGen/TargetInstrInfoImpl.cpp
lib/CodeGen/VirtRegRewriter.cpp