Ignore:
Timestamp:
Oct 19, 2007, 10:18:23 PM (18 years ago)
Author:
ggaren
Message:

Reviewed by Darin Adler.


To improve encapsulation, moved processDeclarations call into
FunctionBodyNode::execute. Also marked processDeclarations
ALWAYS_INLINE, since it has only 1 caller now. This is a .71% speedup
on command-line JS iBench.

  • kjs/function.cpp: (KJS::FunctionImp::callAsFunction): (KJS::GlobalFuncImp::callAsFunction):
  • kjs/function.h:
  • kjs/interpreter.cpp: (KJS::Interpreter::evaluate):
  • kjs/nodes.cpp: (FunctionBodyNode::execute):
  • kjs/nodes.h:
File:
1 edited

Legend:

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

    r26715 r26808  
    7777
    7878  passInParameters(&newExec, args);
    79   processVarDecls(&newExec);
    8079
    8180  Debugger* dbg = exec->dynamicInterpreter()->debugger();
     
    270269      return result;
    271270  return Completion(Normal, jsUndefined()); // TODO: or ReturnValue ?
    272 }
    273 
    274 void FunctionImp::processVarDecls(ExecState* exec)
    275 {
    276     body->processDeclarations(exec);
    277271}
    278272
     
    782776        }
    783777       
    784         // execute the code
    785         progNode->processDeclarations(&newExec);
    786778        Completion c = progNode->execute(&newExec);
    787779         
Note: See TracChangeset for help on using the changeset viewer.