projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5a62d0a
)
fix a common crash.
author
Chris Lattner
<sabre@nondot.org>
Sat, 5 Jan 2008 01:39:17 +0000
(
01:39
+0000)
committer
Chris Lattner
<sabre@nondot.org>
Sat, 5 Jan 2008 01:39:17 +0000
(
01:39
+0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@45614
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/CodeGen/MachineSink.cpp
patch
|
blob
|
history
diff --git
a/lib/CodeGen/MachineSink.cpp
b/lib/CodeGen/MachineSink.cpp
index 0665e87f67ad9a88e6aa42d0e32411dba6fc6cd9..dff60f6d395410a53a61f56ec5b7e74ce7462085 100644
(file)
--- a/
lib/CodeGen/MachineSink.cpp
+++ b/
lib/CodeGen/MachineSink.cpp
@@
-180,6
+180,10
@@
bool MachineSinking::SinkInstruction(MachineInstr *MI) {
}
}
+ // If there are no outputs, it must have side-effects.
+ if (SuccToSinkTo == 0)
+ return false;
+
// FIXME: Check that the instr doesn't have side effects etc.
DEBUG(cerr << "Sink instr " << *MI);