Title: [94484] trunk/Source/_javascript_Core
- Revision
- 94484
- Author
- [email protected]
- Date
- 2011-09-03 00:49:15 -0700 (Sat, 03 Sep 2011)
Log Message
DFG variable predictions only work for local variables, not temporaries
https://bugs.webkit.org/show_bug.cgi?id=67554
Reviewed by Gavin Barraclough.
This appears to be a slight speed-up in Kraken (0.3% but significant)
and neutral elsewhere.
* dfg/DFGGraph.h:
(JSC::DFG::Graph::predict):
Modified Paths
Diff
Modified: trunk/Source/_javascript_Core/ChangeLog (94483 => 94484)
--- trunk/Source/_javascript_Core/ChangeLog 2011-09-03 07:45:30 UTC (rev 94483)
+++ trunk/Source/_javascript_Core/ChangeLog 2011-09-03 07:49:15 UTC (rev 94484)
@@ -1,3 +1,16 @@
+2011-09-03 Filip Pizlo <[email protected]>
+
+ DFG variable predictions only work for local variables, not temporaries
+ https://bugs.webkit.org/show_bug.cgi?id=67554
+
+ Reviewed by Gavin Barraclough.
+
+ This appears to be a slight speed-up in Kraken (0.3% but significant)
+ and neutral elsewhere.
+
+ * dfg/DFGGraph.h:
+ (JSC::DFG::Graph::predict):
+
2011-09-02 Filip Pizlo <[email protected]>
DFG JIT speculation failure does recovery of additions in reverse and
Modified: trunk/Source/_javascript_Core/dfg/DFGGraph.h (94483 => 94484)
--- trunk/Source/_javascript_Core/dfg/DFGGraph.h 2011-09-03 07:45:30 UTC (rev 94483)
+++ trunk/Source/_javascript_Core/dfg/DFGGraph.h 2011-09-03 07:49:15 UTC (rev 94484)
@@ -140,8 +140,15 @@
if (operandIsArgument(operand)) {
unsigned argument = operand + m_argumentPredictions.size() + RegisterFile::CallFrameHeaderSize;
mergePrediction(m_argumentPredictions[argument].m_value, makePrediction(prediction, source));
- } else if ((unsigned)operand < m_variablePredictions.size())
- mergePrediction(m_variablePredictions[operand].m_value, makePrediction(prediction, source));
+ return;
+ }
+
+ if ((unsigned)operand >= m_variablePredictions.size()) {
+ ASSERT(operand >= 0);
+ m_variablePredictions.resize(operand + 1);
+ }
+
+ mergePrediction(m_variablePredictions[operand].m_value, makePrediction(prediction, source));
}
void predictGlobalVar(unsigned varNumber, PredictedType prediction, PredictionSource source)
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes