Title: [122640] trunk/Source/_javascript_Core
- Revision
- 122640
- Author
- [email protected]
- Date
- 2012-07-13 16:12:14 -0700 (Fri, 13 Jul 2012)
Log Message
LLInt fails to mark structures stored in the bytecode
https://bugs.webkit.org/show_bug.cgi?id=91296
Reviewed by Geoffrey Garen.
LLInt stores structures in the bytecode, so we need to visit the appropriate
instructions as we would if we were running in the classic interpreter.
This requires adding additional checks for the LLInt specific opcodes, and
the lint specific variants of operand ordering.
* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::visitStructures):
(JSC::CodeBlock::stronglyVisitStrongReferences):
Modified Paths
Diff
Modified: trunk/Source/_javascript_Core/ChangeLog (122639 => 122640)
--- trunk/Source/_javascript_Core/ChangeLog 2012-07-13 22:57:16 UTC (rev 122639)
+++ trunk/Source/_javascript_Core/ChangeLog 2012-07-13 23:12:14 UTC (rev 122640)
@@ -1,3 +1,19 @@
+2012-07-13 Oliver Hunt <[email protected]>
+
+ LLInt fails to mark structures stored in the bytecode
+ https://bugs.webkit.org/show_bug.cgi?id=91296
+
+ Reviewed by Geoffrey Garen.
+
+ LLInt stores structures in the bytecode, so we need to visit the appropriate
+ instructions as we would if we were running in the classic interpreter.
+ This requires adding additional checks for the LLInt specific opcodes, and
+ the lint specific variants of operand ordering.
+
+ * bytecode/CodeBlock.cpp:
+ (JSC::CodeBlock::visitStructures):
+ (JSC::CodeBlock::stronglyVisitStrongReferences):
+
2012-07-13 Yong Li <[email protected]>
[BlackBerry] Implement GCActivityCallback with platform timer
Modified: trunk/Source/_javascript_Core/bytecode/CodeBlock.cpp (122639 => 122640)
--- trunk/Source/_javascript_Core/bytecode/CodeBlock.cpp 2012-07-13 22:57:16 UTC (rev 122639)
+++ trunk/Source/_javascript_Core/bytecode/CodeBlock.cpp 2012-07-13 23:12:14 UTC (rev 122640)
@@ -1840,11 +1840,11 @@
{
Interpreter* interpreter = m_globalData->interpreter;
- if (vPC[0].u.opcode == interpreter->getOpcode(op_get_by_id) && vPC[4].u.structure) {
+ if ((vPC[0].u.opcode == interpreter->getOpcode(op_get_by_id) || vPC[0].u.opcode == interpreter->getOpcode(op_get_by_id_out_of_line)) && vPC[4].u.structure) {
visitor.append(&vPC[4].u.structure);
return;
}
-
+
if (vPC[0].u.opcode == interpreter->getOpcode(op_get_by_id_self) || vPC[0].u.opcode == interpreter->getOpcode(op_get_by_id_getter_self) || vPC[0].u.opcode == interpreter->getOpcode(op_get_by_id_custom_self)) {
visitor.append(&vPC[4].u.structure);
return;
@@ -1860,6 +1860,16 @@
visitor.append(&vPC[5].u.structureChain);
return;
}
+#if ENABLE(LLINT)
+ if (vPC[0].u.opcode == interpreter->getOpcode(op_put_by_id_transition_direct) || vPC[0].u.opcode == interpreter->getOpcode(op_put_by_id_transition_direct_out_of_line) || vPC[0].u.opcode == interpreter->getOpcode(op_put_by_id_transition_normal) || vPC[0].u.opcode == interpreter->getOpcode(op_put_by_id_transition_normal_out_of_line)) {
+ visitor.append(&vPC[4].u.structure);
+ visitor.append(&vPC[6].u.structure);
+ if (vPC[7].u.structureChain)
+ visitor.append(&vPC[7].u.structureChain);
+ return;
+ }
+#endif
+
if (vPC[0].u.opcode == interpreter->getOpcode(op_put_by_id_transition)) {
visitor.append(&vPC[4].u.structure);
visitor.append(&vPC[5].u.structure);
@@ -1867,7 +1877,7 @@
visitor.append(&vPC[6].u.structureChain);
return;
}
- if (vPC[0].u.opcode == interpreter->getOpcode(op_put_by_id) && vPC[4].u.structure) {
+ if ((vPC[0].u.opcode == interpreter->getOpcode(op_put_by_id) || vPC[0].u.opcode == interpreter->getOpcode(op_put_by_id_out_of_line)) && vPC[4].u.structure) {
visitor.append(&vPC[4].u.structure);
return;
}
@@ -2238,6 +2248,14 @@
visitStructures(visitor, &instructions()[m_globalResolveInstructions[i]]);
}
#endif
+#if ENABLE(LLINT)
+ if (!m_globalData->interpreter->classicEnabled() && !!numberOfInstructions() && getJITType() < JITCode::bottomTierJIT()) {
+ for (size_t size = m_propertyAccessInstructions.size(), i = 0; i < size; ++i)
+ visitStructures(visitor, &instructions()[m_propertyAccessInstructions[i]]);
+ for (size_t size = m_globalResolveInstructions.size(), i = 0; i < size; ++i)
+ visitStructures(visitor, &instructions()[m_globalResolveInstructions[i]]);
+ }
+#endif
updateAllPredictions(Collection);
}
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes