[Scummvm-cvs-logs] SF.net SVN: scummvm:[50011] tools/branches/gsoc2010-decompiler/decompiler/ control_flow.cpp
pidgeot at users.sourceforge.net
pidgeot at users.sourceforge.net
Fri Jun 18 11:06:55 CEST 2010
Revision: 50011
http://scummvm.svn.sourceforge.net/scummvm/?rev=50011&view=rev
Author: pidgeot
Date: 2010-06-18 09:06:54 +0000 (Fri, 18 Jun 2010)
Log Message:
-----------
Emit warning if multiple paths to same instruction provide different
expected stack levels
Modified Paths:
--------------
tools/branches/gsoc2010-decompiler/decompiler/control_flow.cpp
Modified: tools/branches/gsoc2010-decompiler/decompiler/control_flow.cpp
===================================================================
--- tools/branches/gsoc2010-decompiler/decompiler/control_flow.cpp 2010-06-18 08:53:09 UTC (rev 50010)
+++ tools/branches/gsoc2010-decompiler/decompiler/control_flow.cpp 2010-06-18 09:06:54 UTC (rev 50011)
@@ -106,8 +106,11 @@
void ControlFlow::setStackLevel(GraphVertex g, int level) {
Group gr = GET(g);
- if (gr._stackLevel != -1)
+ if (gr._stackLevel != -1) {
+ if (gr._stackLevel != level)
+ std::cerr << boost::format("WARNING: Inconsistency in expected stack level for instruction at address 0x%08x (current: %d, requested: %d)\n") % gr._start->_address % gr._stackLevel % level;
return;
+ }
gr._stackLevel = level;
PUT(g, gr)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list