Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Backport 5786 to v4.x (memory growth with 'vm' module) #6871

Merged
merged 5 commits into from
May 20, 2016

Commits on May 20, 2016

  1. contextify: cleanup weak ref for global proxy

    Cleanup how node_contextify keeps weak references in order to prepare
    for new style phantom weakness API. We didn't need to keep a weak
    reference to the context's global proxy, as the context holds it.
    
    PR-URL: nodejs#5392
    Reviewed-By: Ben Noordhuis <[email protected]>
    ofrobots authored and rvagg committed May 20, 2016
    Configuration menu
    Copy the full SHA
    faa94ff View commit details
    Browse the repository at this point in the history
  2. contextify: cleanup weak ref for sandbox

    Simplify how node_contextify was keeping a weak reference to the
    sandbox object in order to prepare for new style phantom weakness V8
    API. It is simpler (and more robust) for the context to hold a
    reference to the sandbox in an embedder data field. Doing otherwise
    meant that the sandbox could become weak while the context was still
    alive. This wasn't a problem because we would make the reference
    strong at that point.
    
    Since the sandbox must live at least as long as the context, it
    would be better for the context to hold onto the sandbox.
    
    PR-URL: nodejs#5392
    Reviewed-By: Ben Noordhuis <[email protected]>
    ofrobots authored and rvagg committed May 20, 2016
    Configuration menu
    Copy the full SHA
    3d56671 View commit details
    Browse the repository at this point in the history
  3. contextify: replace deprecated SetWeak usage

    PR-URL: nodejs#5392
    Reviewed-By: Ben Noordhuis <[email protected]>
    ofrobots authored and rvagg committed May 20, 2016
    Configuration menu
    Copy the full SHA
    ab00cf5 View commit details
    Browse the repository at this point in the history
  4. contextify: cache sandbox and context in locals

    PR-URL: nodejs#5392
    Reviewed-By: Ben Noordhuis <[email protected]>
    ofrobots authored and rvagg committed May 20, 2016
    Configuration menu
    Copy the full SHA
    4d48400 View commit details
    Browse the repository at this point in the history
  5. contextify: tie lifetimes of context & sandbox

    When the previous set of changes (bfff07b) it was possible to have the
    context get garbage collected while sandbox was still live. We need to
    tie the lifetime of the context to the lifetime of the sandbox.
    
    This is a backport of nodejs#5786 to v5.x.
    
    Ref: nodejs#5786
    PR-URL: nodejs#5800
    Reviewed-By: Ben Noordhuis <[email protected]>
    Reviewed-By: Colin Ihrig <[email protected]>
    Reviewed-By: James M Snell <[email protected]>
    ofrobots authored and rvagg committed May 20, 2016
    Configuration menu
    Copy the full SHA
    c6db822 View commit details
    Browse the repository at this point in the history