diff options
author | Bob Wilson <bob.wilson@apple.com> | 2010-05-10 17:14:26 +0000 |
---|---|---|
committer | Bob Wilson <bob.wilson@apple.com> | 2010-05-10 17:14:26 +0000 |
commit | 01fcdaa7f5329ee88e59f6e7d7e152436f68b306 (patch) | |
tree | d644177954847d602ab5e4fe56dd00d0c7170c21 /llvm/lib/CodeGen/MachineSSAUpdater.cpp | |
parent | c8a7bdbcc4c040b518fb60d095c7502549de505e (diff) | |
download | llvm-01fcdaa7f5329ee88e59f6e7d7e152436f68b306.zip llvm-01fcdaa7f5329ee88e59f6e7d7e152436f68b306.tar.gz llvm-01fcdaa7f5329ee88e59f6e7d7e152436f68b306.tar.bz2 |
Fix PR7096. When a block containing multiple defs is tail duplicated, the
SSAUpdater for the value from the first def may see uses of undefined values,
because the later defs will not have been updated yet.
llvm-svn: 103407
Diffstat (limited to 'llvm/lib/CodeGen/MachineSSAUpdater.cpp')
-rw-r--r-- | llvm/lib/CodeGen/MachineSSAUpdater.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/MachineSSAUpdater.cpp b/llvm/lib/CodeGen/MachineSSAUpdater.cpp index 99fb99a..84d6df2 100644 --- a/llvm/lib/CodeGen/MachineSSAUpdater.cpp +++ b/llvm/lib/CodeGen/MachineSSAUpdater.cpp @@ -329,7 +329,7 @@ public: /// InstrIsPHI - Check if an instruction is a PHI. /// static MachineInstr *InstrIsPHI(MachineInstr *I) { - if (I->isPHI()) + if (I && I->isPHI()) return I; return 0; } |