[llvm-commits] [llvm] r140280 - /llvm/trunk/lib/VMCore/Verifier.cpp
Bill Wendling
isanbard at gmail.com
Wed Sep 21 15:57:02 PDT 2011
Author: void
Date: Wed Sep 21 17:57:02 2011
New Revision: 140280
URL: http://llvm.org/viewvc/llvm-project?rev=140280&view=rev
Log:
The last verification check for the new EH model.
This makes sure that the unwind destination of an invoke is a landing pad.
Modified:
llvm/trunk/lib/VMCore/Verifier.cpp
Modified: llvm/trunk/lib/VMCore/Verifier.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/VMCore/Verifier.cpp?rev=140280&r1=140279&r2=140280&view=diff
==============================================================================
--- llvm/trunk/lib/VMCore/Verifier.cpp (original)
+++ llvm/trunk/lib/VMCore/Verifier.cpp Wed Sep 21 17:57:02 2011
@@ -1167,6 +1167,12 @@
void Verifier::visitInvokeInst(InvokeInst &II) {
VerifyCallSite(&II);
+
+ // Verify that there is a landingpad instruction as the first non-PHI
+ // instruction of the 'unwind' destination.
+ Assert1(II.getUnwindDest()->isLandingPad(),
+ "The unwind destination does not have a landingpad instruction!",&II);
+
visitTerminatorInst(II);
}
More information about the llvm-commits
mailing list