Title: [165078] trunk/Source/_javascript_Core
- Revision
- 165078
- Author
- [email protected]
- Date
- 2014-03-04 14:40:50 -0800 (Tue, 04 Mar 2014)
Log Message
Get to Structures more efficiently in JSCell::methodTable().
<https://webkit.org/b/129702>
In JSCell::methodTable(), get the VM once and pass that along to
structure(VM&) instead of using the heavier structure().
In JSCell::methodTable(VM&), replace calls to structure() with
calls to structure(VM&).
Reviewed by Mark Hahnenberg.
* runtime/JSCellInlines.h:
(JSC::JSCell::methodTable):
Modified Paths
Diff
Modified: trunk/Source/_javascript_Core/ChangeLog (165077 => 165078)
--- trunk/Source/_javascript_Core/ChangeLog 2014-03-04 22:40:46 UTC (rev 165077)
+++ trunk/Source/_javascript_Core/ChangeLog 2014-03-04 22:40:50 UTC (rev 165078)
@@ -1,3 +1,19 @@
+2014-03-04 Andreas Kling <[email protected]>
+
+ Get to Structures more efficiently in JSCell::methodTable().
+ <https://webkit.org/b/129702>
+
+ In JSCell::methodTable(), get the VM once and pass that along to
+ structure(VM&) instead of using the heavier structure().
+
+ In JSCell::methodTable(VM&), replace calls to structure() with
+ calls to structure(VM&).
+
+ Reviewed by Mark Hahnenberg.
+
+ * runtime/JSCellInlines.h:
+ (JSC::JSCell::methodTable):
+
2014-03-04 Joseph Pecoraro <[email protected]>
Web Inspector: Listen for the XPC_ERROR_CONNECTION_INVALID event to deref
Modified: trunk/Source/_javascript_Core/runtime/JSCellInlines.h (165077 => 165078)
--- trunk/Source/_javascript_Core/runtime/JSCellInlines.h 2014-03-04 22:40:46 UTC (rev 165077)
+++ trunk/Source/_javascript_Core/runtime/JSCellInlines.h 2014-03-04 22:40:50 UTC (rev 165078)
@@ -189,9 +189,10 @@
inline const MethodTable* JSCell::methodTable() const
{
- Structure* structure = this->structure();
- if (Structure* rootStructure = structure->structure())
- RELEASE_ASSERT(rootStructure == rootStructure->structure());
+ VM& vm = *Heap::heap(this)->vm();
+ Structure* structure = this->structure(vm);
+ if (Structure* rootStructure = structure->structure(vm))
+ RELEASE_ASSERT(rootStructure == rootStructure->structure(vm));
return &structure->classInfo()->methodTable;
}
@@ -199,8 +200,8 @@
inline const MethodTable* JSCell::methodTable(VM& vm) const
{
Structure* structure = this->structure(vm);
- if (Structure* rootStructure = structure->structure())
- RELEASE_ASSERT(rootStructure == rootStructure->structure());
+ if (Structure* rootStructure = structure->structure(vm))
+ RELEASE_ASSERT(rootStructure == rootStructure->structure(vm));
return &structure->classInfo()->methodTable;
}
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes