[Webkit-unassigned] [Bug 25651] New: Allocation of BytecodeGenerator causes stack overflow

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri May 8 13:31:40 PDT 2009


https://bugs.webkit.org/show_bug.cgi?id=25651

           Summary: Allocation of BytecodeGenerator causes stack overflow
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: S60 Hardware
        OS/Version: S60 3rd edition
            Status: UNCONFIRMED
          Severity: Critical
          Priority: P2
         Component: JavaScriptCore
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: norbert.leser at nokia.com
                CC: hausmann at webkit.org, laszlo.1.gombos at nokia.com


The BytecodeGenerator objects are currently instantiated on stack (in
Nodes.cpp), which takes up ~38kB per instance (each instance includes copy of
JSC::CodeBlock with large SymbolTable, etc.). Specifically, since there is
nested invocation (e.g., GlobalCode --> FunctionCode), the stack overflows
immediately on Symbian hardware (max. 80 kB stack allowed). 

Proposed change allocates generator objects on heap. Performance impact (if
any) should be negligible and change is proposed as general fix, rather than
ifdef'd for SYMBIAN. I ran a couple of rounds of sunspider each, on code with
stack and with heap allocation (see attached sunspider log). The results stray
from slightly faster to slightly slower in each case and support the assertion
of negligibility. 

Proposed patch is attached.


-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the webkit-unassigned mailing list