• mstarzinger@chromium.org's avatar
    Force context allocation for variables in generator scopes. · b6efbd79
    mstarzinger@chromium.org authored
    * src/scopes.h (ForceContextAllocation, has_forced_context_allocation):
      New interface to force context allocation for an entire function's
      scope.
    
    * src/scopes.cc: Unless a new scope is a function scope, if its outer
      scope has forced context allocation, it should also force context
      allocation.
      (MustAllocateInContext): Return true if the scope as a whole has
      forced context allocation.
      (CollectStackAndContextLocals): Allow temporaries to be
      context-allocated.
    
    * src/parser.cc (ParseFunctionLiteral): Force context allocation for
      generator scopes.
    
    * src/v8globals.h (VariableMode): Update comment on TEMPORARY.
    
    * src/arm/full-codegen-arm.cc (Generate):
    * src/ia32/full-codegen-ia32.cc (Generate):
    * src/x64/full-codegen-x64.cc (Generate): Assert that generators have no
      stack slots.
    
    * test/mjsunit/harmony/generators-instantiation.js: New test.
    
    BUG=v8:2355
    TEST=mjsunit/harmony/generators-instantiation
    
    Review URL: https://codereview.chromium.org/13408005
    Patch from Andy Wingo <wingo@igalia.com>.
    
    git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14152 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
    b6efbd79
Name
Last commit
Last update
..
block-conflicts.js Loading commit data...
block-const-assign.js Loading commit data...
block-early-errors.js Loading commit data...
block-for.js Loading commit data...
block-lazy-compile.js Loading commit data...
block-leave.js Loading commit data...
block-let-crankshaft.js Loading commit data...
block-let-declaration.js Loading commit data...
block-let-semantics.js Loading commit data...
block-scoping.js Loading commit data...
collections.js Loading commit data...
debug-blockscopes.js Loading commit data...
debug-evaluate-blockscopes.js Loading commit data...
debug-function-scopes.js Loading commit data...
generators-instantiation.js Loading commit data...
generators-parsing.js Loading commit data...
module-linking.js Loading commit data...
module-parsing.js Loading commit data...
module-recompile.js Loading commit data...
module-resolution.js Loading commit data...
object-observe.js Loading commit data...
proxies-example-membrane.js Loading commit data...
proxies-for.js Loading commit data...
proxies-function.js Loading commit data...
proxies-hash.js Loading commit data...
proxies-json.js Loading commit data...
proxies-symbols.js Loading commit data...
proxies.js Loading commit data...
symbols.js Loading commit data...
typedarrays.js Loading commit data...
typeof.js Loading commit data...