Changeset 55751 in webkit for trunk/JavaScriptCore/parser


Ignore:
Timestamp:
Mar 9, 2010, 3:32:58 PM (15 years ago)
Author:
[email protected]
Message:

This caused a performance regression, by breaking the code
generator's logic to calculate the skip level for resolving
variables (traced by rdar:7683350) Reverting for now.

Reviewed by NOBODY (reverting r54510).

  • parser/Grammar.y:
  • parser/NodeConstructors.h:

(JSC::ContinueNode::ContinueNode):
(JSC::BreakNode::BreakNode):
(JSC::ForInNode::ForInNode):

  • runtime/CommonIdentifiers.cpp:

(JSC::CommonIdentifiers::CommonIdentifiers):

  • runtime/CommonIdentifiers.h:
  • runtime/FunctionPrototype.cpp:

(JSC::FunctionPrototype::FunctionPrototype):

  • runtime/Identifier.cpp:

(JSC::Identifier::add):

  • runtime/PropertyNameArray.cpp:

(JSC::PropertyNameArray::add):

Location:
trunk/JavaScriptCore/parser
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/parser/Grammar.y

    r54510 r55751  
    11481148
    11491149TryStatement:
    1150     TRY Block FINALLY Block             { $$ = createNodeDeclarationInfo<StatementNode*>(new (GLOBAL_DATA) TryNode(GLOBAL_DATA, $2.m_node, GLOBAL_DATA->propertyNames->emptyIdentifier, false, 0, $4.m_node),
     1150    TRY Block FINALLY Block             { $$ = createNodeDeclarationInfo<StatementNode*>(new (GLOBAL_DATA) TryNode(GLOBAL_DATA, $2.m_node, GLOBAL_DATA->propertyNames->nullIdentifier, false, 0, $4.m_node),
    11511151                                                                                         mergeDeclarationLists($2.m_varDeclarations, $4.m_varDeclarations),
    11521152                                                                                         mergeDeclarationLists($2.m_funcDeclarations, $4.m_funcDeclarations),
     
    11891189
    11901190FunctionExpr:
    1191     FUNCTION '(' ')' OPENBRACE FunctionBody CLOSEBRACE { $$ = createNodeInfo(new (GLOBAL_DATA) FuncExprNode(GLOBAL_DATA, GLOBAL_DATA->propertyNames->emptyIdentifier, $5, GLOBAL_DATA->lexer->sourceCode($4, $6, @4.first_line)), ClosureFeature, 0); setStatementLocation($5, @4, @6); }
     1191    FUNCTION '(' ')' OPENBRACE FunctionBody CLOSEBRACE { $$ = createNodeInfo(new (GLOBAL_DATA) FuncExprNode(GLOBAL_DATA, GLOBAL_DATA->propertyNames->nullIdentifier, $5, GLOBAL_DATA->lexer->sourceCode($4, $6, @4.first_line)), ClosureFeature, 0); setStatementLocation($5, @4, @6); }
    11921192    | FUNCTION '(' FormalParameterList ')' OPENBRACE FunctionBody CLOSEBRACE
    11931193      {
    1194           $$ = createNodeInfo(new (GLOBAL_DATA) FuncExprNode(GLOBAL_DATA, GLOBAL_DATA->propertyNames->emptyIdentifier, $6, GLOBAL_DATA->lexer->sourceCode($5, $7, @5.first_line), $3.m_node.head), $3.m_features | ClosureFeature, 0);
     1194          $$ = createNodeInfo(new (GLOBAL_DATA) FuncExprNode(GLOBAL_DATA, GLOBAL_DATA->propertyNames->nullIdentifier, $6, GLOBAL_DATA->lexer->sourceCode($5, $7, @5.first_line), $3.m_node.head), $3.m_features | ClosureFeature, 0);
    11951195          if ($3.m_features & ArgumentsFeature)
    11961196              $6->setUsesArguments();
     
    19821982    else
    19831983        return 0;
    1984     return new (globalData) PropertyNode(globalData, name, new (globalData) FuncExprNode(globalData, globalData->propertyNames->emptyIdentifier, body, source, params), type);
     1984    return new (globalData) PropertyNode(globalData, name, new (globalData) FuncExprNode(globalData, globalData->propertyNames->nullIdentifier, body, source, params), type);
    19851985}
    19861986
  • trunk/JavaScriptCore/parser/NodeConstructors.h

    r54510 r55751  
    742742    inline ContinueNode::ContinueNode(JSGlobalData* globalData)
    743743        : StatementNode(globalData)
    744         , m_ident(globalData->propertyNames->emptyIdentifier)
     744        , m_ident(globalData->propertyNames->nullIdentifier)
    745745    {
    746746    }
     
    754754    inline BreakNode::BreakNode(JSGlobalData* globalData)
    755755        : StatementNode(globalData)
    756         , m_ident(globalData->propertyNames->emptyIdentifier)
     756        , m_ident(globalData->propertyNames->nullIdentifier)
    757757    {
    758758    }
     
    878878    inline ForInNode::ForInNode(JSGlobalData* globalData, ExpressionNode* l, ExpressionNode* expr, StatementNode* statement)
    879879        : StatementNode(globalData)
    880         , m_ident(globalData->propertyNames->emptyIdentifier)
     880        , m_ident(globalData->propertyNames->nullIdentifier)
    881881        , m_init(0)
    882882        , m_lexpr(l)
Note: See TracChangeset for help on using the changeset viewer.