Ignore:
Timestamp:
Oct 31, 2011, 6:15:06 PM (14 years ago)
Author:
[email protected]
Message:

De-virtualize JSObject::defaultValue
https://bugs.webkit.org/show_bug.cgi?id=71146

Reviewed by Sam Weinig.

Source/JavaScriptCore:

Added defaultValue to the MethodTable. Replaced all virtual versions of
defaultValue with static versions. Replaced all call sites with lookups in the
MethodTable.

(JSC::InterruptedExecutionError::defaultValue):
(JSC::TerminatedExecutionError::defaultValue):

  • runtime/ExceptionHelpers.h:
  • runtime/JSCell.cpp:

(JSC::JSCell::defaultValue):

  • runtime/JSCell.h:
  • runtime/JSNotAnObject.cpp:

(JSC::JSNotAnObject::defaultValue):

  • runtime/JSNotAnObject.h:
  • runtime/JSObject.cpp:

(JSC::JSObject::getPrimitiveNumber):
(JSC::JSObject::defaultValue):

  • runtime/JSObject.h:

(JSC::JSObject::toPrimitive):

Source/WebCore:

No new tests.

Added defaultValue to the MethodTable. Replaced all virtual versions of
defaultValue with static versions. Replaced all call sites with lookups in the
MethodTable.

  • WebCore.exp.in:
  • bridge/objc/objc_runtime.h:
  • bridge/objc/objc_runtime.mm:

(JSC::Bindings::ObjcFallbackObjectImp::defaultValue):

  • bridge/runtime_object.cpp:

(JSC::Bindings::RuntimeObject::defaultValue):

  • bridge/runtime_object.h:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/runtime/ExceptionHelpers.h

    r97292 r98932  
    6363    }
    6464
    65     virtual JSValue defaultValue(ExecState*, PreferredPrimitiveType) const;
     65    static JSValue defaultValue(const JSObject*, ExecState*, PreferredPrimitiveType);
    6666
    6767public:
     
    9090    }
    9191
    92     virtual JSValue defaultValue(ExecState*, PreferredPrimitiveType) const;
     92    static JSValue defaultValue(const JSObject*, ExecState*, PreferredPrimitiveType);
    9393
    9494public:
Note: See TracChangeset for help on using the changeset viewer.