-
- Downloads
Bug 993438 - Infer the eventual compartment for OMT-compiled script when the...
Bug 993438 - Infer the eventual compartment for OMT-compiled script when the script is retrieved. r=billm Currently, the script gets put in a compartment specified when the compilation is initiated. Later on, when we retrieve that script and try to execute it, we won't necessarily be in the same compartment. Currently, SM just handles this and clones the script, but it's simpler and more efficient to just create the script in the compartment of whoever calls FinishOffThreadScript. Note that the existing code actually has a hazard in which the call to GetBuiltinPrototypePure returns null - it just wasn't exercised in automation (and was triggered by onNewScript-off-main-thread.js with this patch).
Showing
- content/base/src/nsScriptLoader.cpp 1 addition, 1 deletioncontent/base/src/nsScriptLoader.cpp
- content/xul/content/src/nsXULElement.cpp 1 addition, 1 deletioncontent/xul/content/src/nsXULElement.cpp
- js/src/jit-test/tests/debug/onNewScript-off-main-thread.js 1 addition, 1 deletionjs/src/jit-test/tests/debug/onNewScript-off-main-thread.js
- js/src/jsapi.cpp 2 additions, 2 deletionsjs/src/jsapi.cpp
- js/src/jsapi.h 3 additions, 3 deletionsjs/src/jsapi.h
- js/src/jsworkers.cpp 45 additions, 28 deletionsjs/src/jsworkers.cpp
- js/src/jsworkers.h 3 additions, 8 deletionsjs/src/jsworkers.h
- js/src/shell/js.cpp 1 addition, 1 deletionjs/src/shell/js.cpp
Loading
Please register or sign in to comment