Ignore:
Timestamp:
Sep 30, 2013, 11:58:51 AM (12 years ago)
Author:
[email protected]
Message:

Pass VM instead of JSGlobalObject to RegExp constructor.
<https://webkit.org/b/122113>

Reviewed by Darin Adler.

RegExps don't need anything from the global object during their
construction and only use it to get to the VM. Reduce loads by
simply passing the VM around instead.

JSC release binary size -= 120 bytes(!)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/llint/LLIntSlowPaths.cpp

    r156602 r156668  
    477477    if (!regExp->isValid())
    478478        LLINT_THROW(createSyntaxError(exec, "Invalid flag supplied to RegExp constructor."));
    479     LLINT_RETURN(RegExpObject::create(vm, exec->lexicalGlobalObject(), exec->lexicalGlobalObject()->regExpStructure(), regExp));
     479    LLINT_RETURN(RegExpObject::create(vm, exec->lexicalGlobalObject()->regExpStructure(), regExp));
    480480}
    481481
Note: See TracChangeset for help on using the changeset viewer.