diff options
| author | Chris Lattner <sabre@nondot.org> | 2011-01-16 02:27:38 +0000 |
|---|---|---|
| committer | Chris Lattner <sabre@nondot.org> | 2011-01-16 02:27:38 +0000 |
| commit | 2d186574a690f7957e5f77cd167f9b4648e8b4b4 (patch) | |
| tree | 65fba0a007ea6aaa7b2940a4f875ab44b8fee6e6 /llvm/lib/Target/X86/X86FastISel.cpp | |
| parent | 8b4952fcf722d4beafa057e0d65bec996dc46cc6 (diff) | |
| download | bcm5719-llvm-2d186574a690f7957e5f77cd167f9b4648e8b4b4.tar.gz bcm5719-llvm-2d186574a690f7957e5f77cd167f9b4648e8b4b4.zip | |
reapply my fix for PR8961 with a tweak to properly handle
multi-instruction sequences like calls. Many thanks to Jakob for
finding a testcase.
llvm-svn: 123559
Diffstat (limited to 'llvm/lib/Target/X86/X86FastISel.cpp')
| -rw-r--r-- | llvm/lib/Target/X86/X86FastISel.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Target/X86/X86FastISel.cpp b/llvm/lib/Target/X86/X86FastISel.cpp index f29d127c85d..9d42ac2e470 100644 --- a/llvm/lib/Target/X86/X86FastISel.cpp +++ b/llvm/lib/Target/X86/X86FastISel.cpp @@ -1933,7 +1933,7 @@ bool X86FastISel::TryToFoldLoad(MachineInstr *MI, unsigned OpNo, XII.foldMemoryOperandImpl(*FuncInfo.MF, MI, OpNo, AddrOps, Size, Alignment); if (Result == 0) return false; - MI->getParent()->insert(MI, Result); + FuncInfo.MBB->insert(FuncInfo.InsertPt, Result); MI->eraseFromParent(); return true; } |

