Title: [157301] trunk/Source/_javascript_Core
Revision
157301
Author
[email protected]
Date
2013-10-11 08:26:11 -0700 (Fri, 11 Oct 2013)

Log Message

Pass VM instead of ExecState to JSGenericTypedArrayViewPrototype.
<https://webkit.org/b/122632>

Reviewed by Sam Weinig.

This code was only using the ExecState to find the VM.

Modified Paths

Diff

Modified: trunk/Source/_javascript_Core/ChangeLog (157300 => 157301)


--- trunk/Source/_javascript_Core/ChangeLog	2013-10-11 15:07:12 UTC (rev 157300)
+++ trunk/Source/_javascript_Core/ChangeLog	2013-10-11 15:26:11 UTC (rev 157301)
@@ -1,3 +1,12 @@
+2013-10-11  Andreas Kling  <[email protected]>
+
+        Pass VM instead of ExecState to JSGenericTypedArrayViewPrototype.
+        <https://webkit.org/b/122632>
+
+        Reviewed by Sam Weinig.
+
+        This code was only using the ExecState to find the VM.
+
 2013-10-11  Julien Brianceau  <[email protected]>
 
         [sh4] Fix build after r157209.

Modified: trunk/Source/_javascript_Core/runtime/JSGenericTypedArrayViewPrototype.h (157300 => 157301)


--- trunk/Source/_javascript_Core/runtime/JSGenericTypedArrayViewPrototype.h	2013-10-11 15:07:12 UTC (rev 157300)
+++ trunk/Source/_javascript_Core/runtime/JSGenericTypedArrayViewPrototype.h	2013-10-11 15:26:11 UTC (rev 157301)
@@ -37,11 +37,11 @@
 
 protected:
     JSGenericTypedArrayViewPrototype(VM&, Structure*);
-    void finishCreation(ExecState*, JSGlobalObject*);
+    void finishCreation(VM&, JSGlobalObject*);
 
 public:
     static JSGenericTypedArrayViewPrototype* create(
-        ExecState*, JSGlobalObject*, Structure*);
+        VM&, JSGlobalObject*, Structure*);
     
     DECLARE_INFO;
     

Modified: trunk/Source/_javascript_Core/runtime/JSGenericTypedArrayViewPrototypeInlines.h (157300 => 157301)


--- trunk/Source/_javascript_Core/runtime/JSGenericTypedArrayViewPrototypeInlines.h	2013-10-11 15:07:12 UTC (rev 157300)
+++ trunk/Source/_javascript_Core/runtime/JSGenericTypedArrayViewPrototypeInlines.h	2013-10-11 15:26:11 UTC (rev 157301)
@@ -132,10 +132,8 @@
 
 template<typename ViewClass>
 void JSGenericTypedArrayViewPrototype<ViewClass>::finishCreation(
-    ExecState* exec, JSGlobalObject* globalObject)
+    VM& vm, JSGlobalObject* globalObject)
 {
-    VM& vm = exec->vm();
-    
     Base::finishCreation(vm);
     
     ASSERT(inherits(info()));
@@ -148,12 +146,12 @@
 template<typename ViewClass>
 JSGenericTypedArrayViewPrototype<ViewClass>*
 JSGenericTypedArrayViewPrototype<ViewClass>::create(
-    ExecState* exec, JSGlobalObject* globalObject, Structure* structure)
+    VM& vm, JSGlobalObject* globalObject, Structure* structure)
 {
     JSGenericTypedArrayViewPrototype* prototype =
-        new (NotNull, allocateCell<JSGenericTypedArrayViewPrototype>(exec->vm().heap))
-        JSGenericTypedArrayViewPrototype(exec->vm(), structure);
-    prototype->finishCreation(exec, globalObject);
+        new (NotNull, allocateCell<JSGenericTypedArrayViewPrototype>(vm.heap))
+        JSGenericTypedArrayViewPrototype(vm, structure);
+    prototype->finishCreation(vm, globalObject);
     return prototype;
 }
 

Modified: trunk/Source/_javascript_Core/runtime/JSGlobalObject.cpp (157300 => 157301)


--- trunk/Source/_javascript_Core/runtime/JSGlobalObject.cpp	2013-10-11 15:07:12 UTC (rev 157300)
+++ trunk/Source/_javascript_Core/runtime/JSGlobalObject.cpp	2013-10-11 15:26:11 UTC (rev 157301)
@@ -248,15 +248,15 @@
     m_objectPrototype->putDirectNonIndexAccessor(vm, vm.propertyNames->underscoreProto, protoAccessor, Accessor | DontEnum);
     m_functionPrototype->structure()->setPrototypeWithoutTransition(vm, m_objectPrototype.get());
     
-    m_typedArrays[toIndex(TypeInt8)].prototype.set(vm, this, JSInt8ArrayPrototype::create(exec, this, JSInt8ArrayPrototype::createStructure(vm, this, m_objectPrototype.get())));
-    m_typedArrays[toIndex(TypeInt16)].prototype.set(vm, this, JSInt16ArrayPrototype::create(exec, this, JSInt16ArrayPrototype::createStructure(vm, this, m_objectPrototype.get())));
-    m_typedArrays[toIndex(TypeInt32)].prototype.set(vm, this, JSInt32ArrayPrototype::create(exec, this, JSInt32ArrayPrototype::createStructure(vm, this, m_objectPrototype.get())));
-    m_typedArrays[toIndex(TypeUint8)].prototype.set(vm, this, JSUint8ArrayPrototype::create(exec, this, JSUint8ArrayPrototype::createStructure(vm, this, m_objectPrototype.get())));
-    m_typedArrays[toIndex(TypeUint8Clamped)].prototype.set(vm, this, JSUint8ClampedArrayPrototype::create(exec, this, JSUint8ClampedArrayPrototype::createStructure(vm, this, m_objectPrototype.get())));
-    m_typedArrays[toIndex(TypeUint16)].prototype.set(vm, this, JSUint16ArrayPrototype::create(exec, this, JSUint16ArrayPrototype::createStructure(vm, this, m_objectPrototype.get())));
-    m_typedArrays[toIndex(TypeUint32)].prototype.set(vm, this, JSUint32ArrayPrototype::create(exec, this, JSUint32ArrayPrototype::createStructure(vm, this, m_objectPrototype.get())));
-    m_typedArrays[toIndex(TypeFloat32)].prototype.set(vm, this, JSFloat32ArrayPrototype::create(exec, this, JSFloat32ArrayPrototype::createStructure(vm, this, m_objectPrototype.get())));
-    m_typedArrays[toIndex(TypeFloat64)].prototype.set(vm, this, JSFloat64ArrayPrototype::create(exec, this, JSFloat64ArrayPrototype::createStructure(vm, this, m_objectPrototype.get())));
+    m_typedArrays[toIndex(TypeInt8)].prototype.set(vm, this, JSInt8ArrayPrototype::create(vm, this, JSInt8ArrayPrototype::createStructure(vm, this, m_objectPrototype.get())));
+    m_typedArrays[toIndex(TypeInt16)].prototype.set(vm, this, JSInt16ArrayPrototype::create(vm, this, JSInt16ArrayPrototype::createStructure(vm, this, m_objectPrototype.get())));
+    m_typedArrays[toIndex(TypeInt32)].prototype.set(vm, this, JSInt32ArrayPrototype::create(vm, this, JSInt32ArrayPrototype::createStructure(vm, this, m_objectPrototype.get())));
+    m_typedArrays[toIndex(TypeUint8)].prototype.set(vm, this, JSUint8ArrayPrototype::create(vm, this, JSUint8ArrayPrototype::createStructure(vm, this, m_objectPrototype.get())));
+    m_typedArrays[toIndex(TypeUint8Clamped)].prototype.set(vm, this, JSUint8ClampedArrayPrototype::create(vm, this, JSUint8ClampedArrayPrototype::createStructure(vm, this, m_objectPrototype.get())));
+    m_typedArrays[toIndex(TypeUint16)].prototype.set(vm, this, JSUint16ArrayPrototype::create(vm, this, JSUint16ArrayPrototype::createStructure(vm, this, m_objectPrototype.get())));
+    m_typedArrays[toIndex(TypeUint32)].prototype.set(vm, this, JSUint32ArrayPrototype::create(vm, this, JSUint32ArrayPrototype::createStructure(vm, this, m_objectPrototype.get())));
+    m_typedArrays[toIndex(TypeFloat32)].prototype.set(vm, this, JSFloat32ArrayPrototype::create(vm, this, JSFloat32ArrayPrototype::createStructure(vm, this, m_objectPrototype.get())));
+    m_typedArrays[toIndex(TypeFloat64)].prototype.set(vm, this, JSFloat64ArrayPrototype::create(vm, this, JSFloat64ArrayPrototype::createStructure(vm, this, m_objectPrototype.get())));
     m_typedArrays[toIndex(TypeDataView)].prototype.set(vm, this, JSDataViewPrototype::create(vm, JSDataViewPrototype::createStructure(vm, this, m_objectPrototype.get())));
     
     m_typedArrays[toIndex(TypeInt8)].structure.set(vm, this, JSInt8Array::createStructure(vm, this, m_typedArrays[toIndex(TypeInt8)].prototype.get()));
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to