Title: [128898] trunk/Source/_javascript_Core
Revision
128898
Author
[email protected]
Date
2012-09-18 08:22:29 -0700 (Tue, 18 Sep 2012)

Log Message

DFGOperations doesn't use NativeCallFrameTracer in enough places
https://bugs.webkit.org/show_bug.cgi?id=96987

Reviewed by Mark Hahnenberg.

Anything that can GC should use it.

* dfg/DFGOperations.cpp:

Modified Paths

Diff

Modified: trunk/Source/_javascript_Core/ChangeLog (128897 => 128898)


--- trunk/Source/_javascript_Core/ChangeLog	2012-09-18 15:14:57 UTC (rev 128897)
+++ trunk/Source/_javascript_Core/ChangeLog	2012-09-18 15:22:29 UTC (rev 128898)
@@ -1,3 +1,14 @@
+2012-09-18  Filip Pizlo  <[email protected]>
+
+        DFGOperations doesn't use NativeCallFrameTracer in enough places
+        https://bugs.webkit.org/show_bug.cgi?id=96987
+
+        Reviewed by Mark Hahnenberg.
+
+        Anything that can GC should use it.
+
+        * dfg/DFGOperations.cpp:
+
 2012-09-18  Mark Lam  <[email protected]>
 
         Not reviewed. Attempt at greening the WinCairo bot. Touching

Modified: trunk/Source/_javascript_Core/dfg/DFGOperations.cpp (128897 => 128898)


--- trunk/Source/_javascript_Core/dfg/DFGOperations.cpp	2012-09-18 15:14:57 UTC (rev 128897)
+++ trunk/Source/_javascript_Core/dfg/DFGOperations.cpp	2012-09-18 15:22:29 UTC (rev 128898)
@@ -1193,9 +1193,11 @@
 
 EncodedJSValue DFG_OPERATION operationGetArgumentsLength(ExecState* exec, int32_t argumentsRegister)
 {
+    JSGlobalData& globalData = exec->globalData();
+    NativeCallFrameTracer tracer(&globalData, exec);
     // Here we can assume that the argumernts were created. Because otherwise the JIT code would
     // have not made this call.
-    Identifier ident(&exec->globalData(), "length");
+    Identifier ident(&globalData, "length");
     JSValue baseValue = exec->uncheckedR(argumentsRegister).jsValue();
     PropertySlot slot(baseValue);
     return JSValue::encode(baseValue.get(exec, ident, slot));
@@ -1203,6 +1205,9 @@
 
 EncodedJSValue DFG_OPERATION operationGetArgumentByVal(ExecState* exec, int32_t argumentsRegister, int32_t index)
 {
+    JSGlobalData& globalData = exec->globalData();
+    NativeCallFrameTracer tracer(&globalData, exec);
+
     JSValue argumentsValue = exec->uncheckedR(argumentsRegister).jsValue();
     
     // If there are no arguments, and we're accessing out of bounds, then we have to create the
@@ -1216,6 +1221,9 @@
 EncodedJSValue DFG_OPERATION operationGetInlinedArgumentByVal(
     ExecState* exec, int32_t argumentsRegister, InlineCallFrame* inlineCallFrame, int32_t index)
 {
+    JSGlobalData& globalData = exec->globalData();
+    NativeCallFrameTracer tracer(&globalData, exec);
+
     JSValue argumentsValue = exec->uncheckedR(argumentsRegister).jsValue();
     
     // If there are no arguments, and we're accessing out of bounds, then we have to create the
@@ -1239,6 +1247,10 @@
 JSCell* DFG_OPERATION operationNewFunctionExpression(ExecState* exec, JSCell* functionExecutableAsCell)
 {
     ASSERT(functionExecutableAsCell->inherits(&FunctionExecutable::s_info));
+
+    JSGlobalData& globalData = exec->globalData();
+    NativeCallFrameTracer tracer(&globalData, exec);
+
     FunctionExecutable* functionExecutable =
         static_cast<FunctionExecutable*>(functionExecutableAsCell);
     return JSFunction::create(exec, functionExecutable, exec->scope());
@@ -1257,6 +1269,8 @@
 void DFG_OPERATION operationReallocateStorageAndFinishPut(ExecState* exec, JSObject* base, Structure* structure, PropertyOffset offset, EncodedJSValue value)
 {
     JSGlobalData& globalData = exec->globalData();
+    NativeCallFrameTracer tracer(&globalData, exec);
+
     ASSERT(structure->outOfLineCapacity() > base->structure()->outOfLineCapacity());
     ASSERT(!globalData.heap.storageAllocator().fastPathShouldSucceed(structure->outOfLineCapacity() * sizeof(JSValue)));
     base->setStructureAndReallocateStorageIfNecessary(globalData, structure);
@@ -1265,27 +1279,39 @@
 
 char* DFG_OPERATION operationAllocatePropertyStorageWithInitialCapacity(ExecState* exec)
 {
+    JSGlobalData& globalData = exec->globalData();
+    NativeCallFrameTracer tracer(&globalData, exec);
+
     return reinterpret_cast<char*>(
-        Butterfly::createUninitialized(exec->globalData(), 0, initialOutOfLineCapacity, false, 0));
+        Butterfly::createUninitialized(globalData, 0, initialOutOfLineCapacity, false, 0));
 }
 
 char* DFG_OPERATION operationAllocatePropertyStorage(ExecState* exec, size_t newSize)
 {
+    JSGlobalData& globalData = exec->globalData();
+    NativeCallFrameTracer tracer(&globalData, exec);
+
     return reinterpret_cast<char*>(
-        Butterfly::createUninitialized(exec->globalData(), 0, newSize, false, 0));
+        Butterfly::createUninitialized(globalData, 0, newSize, false, 0));
 }
 
 char* DFG_OPERATION operationReallocateButterflyToHavePropertyStorageWithInitialCapacity(ExecState* exec, JSObject* object)
 {
+    JSGlobalData& globalData = exec->globalData();
+    NativeCallFrameTracer tracer(&globalData, exec);
+
     ASSERT(!object->structure()->outOfLineCapacity());
-    Butterfly* result = object->growOutOfLineStorage(exec->globalData(), 0, initialOutOfLineCapacity);
+    Butterfly* result = object->growOutOfLineStorage(globalData, 0, initialOutOfLineCapacity);
     object->setButterflyWithoutChangingStructure(result);
     return reinterpret_cast<char*>(result);
 }
 
 char* DFG_OPERATION operationReallocateButterflyToGrowPropertyStorage(ExecState* exec, JSObject* object, size_t newSize)
 {
-    Butterfly* result = object->growOutOfLineStorage(exec->globalData(), object->structure()->outOfLineCapacity(), newSize);
+    JSGlobalData& globalData = exec->globalData();
+    NativeCallFrameTracer tracer(&globalData, exec);
+
+    Butterfly* result = object->growOutOfLineStorage(globalData, object->structure()->outOfLineCapacity(), newSize);
     object->setButterflyWithoutChangingStructure(result);
     return reinterpret_cast<char*>(result);
 }
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to