Title: [88093] trunk/Source/_javascript_Core
- Revision
- 88093
- Author
- [email protected]
- Date
- 2011-06-03 22:25:01 -0700 (Fri, 03 Jun 2011)
Log Message
Add debug code to break on speculation failures.
Reviewed by Sam Weinig.
* dfg/DFGJITCompiler.cpp:
(JSC::DFG::JITCompiler::jumpFromSpeculativeToNonSpeculative):
(JSC::DFG::JITCompiler::compileFunction):
* dfg/DFGNode.h:
Modified Paths
Diff
Modified: trunk/Source/_javascript_Core/ChangeLog (88092 => 88093)
--- trunk/Source/_javascript_Core/ChangeLog 2011-06-04 05:13:44 UTC (rev 88092)
+++ trunk/Source/_javascript_Core/ChangeLog 2011-06-04 05:25:01 UTC (rev 88093)
@@ -2,6 +2,17 @@
Reviewed by Sam Weinig.
+ Add debug code to break on speculation failures.
+
+ * dfg/DFGJITCompiler.cpp:
+ (JSC::DFG::JITCompiler::jumpFromSpeculativeToNonSpeculative):
+ (JSC::DFG::JITCompiler::compileFunction):
+ * dfg/DFGNode.h:
+
+2011-06-03 Gavin Barraclough <[email protected]>
+
+ Reviewed by Sam Weinig.
+
https://bugs.webkit.org/show_bug.cgi?id=62082
DFG JIT - bug passing arguments that need swap
Modified: trunk/Source/_javascript_Core/dfg/DFGJITCompiler.cpp (88092 => 88093)
--- trunk/Source/_javascript_Core/dfg/DFGJITCompiler.cpp 2011-06-04 05:13:44 UTC (rev 88092)
+++ trunk/Source/_javascript_Core/dfg/DFGJITCompiler.cpp 2011-06-04 05:25:01 UTC (rev 88093)
@@ -109,6 +109,13 @@
// Link the jump from the Speculative path to here.
check.m_check.link(this);
+#if DFG_DEBUG_VERBOSE
+ fprintf(stderr, "Speculation failure for Node @%d at JIT offset 0x%x\n", (int)check.m_nodeIndex, debugOffset());
+#endif
+#if DFG_JIT_BREAK_ON_SPECULATION_FAILURE
+ breakpoint();
+#endif
+
// Does this speculation check require any additional recovery to be performed,
// to restore any state that has been overwritten before we enter back in to the
// non-speculative path.
@@ -280,6 +287,10 @@
// Link the bail-outs from the speculative path to the corresponding entry points into the non-speculative one.
linkSpeculationChecks(speculative, nonSpeculative);
} else {
+#if DFG_DEBUG_VERBOSE
+ fprintf(stderr, "SpeculativeJIT was terminated.\n");
+#endif
+
// If compilation through the SpeculativeJIT failed, throw away the code we generated.
m_calls.clear();
m_propertyAccesses.clear();
Modified: trunk/Source/_javascript_Core/dfg/DFGNode.h (88092 => 88093)
--- trunk/Source/_javascript_Core/dfg/DFGNode.h 2011-06-04 05:13:44 UTC (rev 88092)
+++ trunk/Source/_javascript_Core/dfg/DFGNode.h 2011-06-04 05:25:01 UTC (rev 88093)
@@ -38,6 +38,8 @@
#define DFG_JIT_BREAK_ON_EVERY_BLOCK 0
// Emit a breakpoint into the head of every generated node, to aid debugging in GDB.
#define DFG_JIT_BREAK_ON_EVERY_NODE 0
+// Emit a breakpoint into the speculation failure code.
+#define DFG_JIT_BREAK_ON_SPECULATION_FAILURE 0
// Disable the DFG JIT without having to touch Platform.h!
#define DFG_DEBUG_LOCAL_DISBALE 0
// Disable the SpeculativeJIT without having to touch Platform.h!
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes