Ignore:
Timestamp:
May 2, 2008, 11:10:33 AM (17 years ago)
Author:
[email protected]
Message:

Reviewed by Darin.

Move call stack depth counter to global object.

  • kjs/ExecState.h: (KJS::ExecState::functionCallDepth): Added a recursion depth counter to per-thread data.
  • kjs/JSGlobalObject.cpp: (KJS::JSGlobalObject::init): Initialize PerThreadData.functionCallDepth.
  • kjs/JSGlobalObject.h: (KJS::JSGlobalObject::perThreadData): Made the result non-const.
  • kjs/object.cpp: (KJS::throwStackSizeExceededError): Moved throwError to a separate function, since it is now the only thing in JSObject::call that needs a PIC branch. (KJS::JSObject::call): Use a per-thread variable instead of local static for recursion depth tracking.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/kjs/JSGlobalObject.cpp

    r32807 r32819  
    231231    d()->perThreadData.propertyNames = CommonIdentifiers::shared();
    232232    d()->perThreadData.heap = Heap::threadHeap();
     233    d()->perThreadData.functionCallDepth = 0;
    233234
    234235    d()->globalExec.set(new GlobalExecState(this, thisValue));
Note: See TracChangeset for help on using the changeset viewer.