• Andreas Haas's avatar
    [d8] Run the message loop in the same RealmScope as the script · 1016e625
    Andreas Haas authored
    In d8 a script is executed in a RealmScope. However, all micro task
    which are created by the script are not executed within the RealmScope
    at the moment. With this CL I move the execution of the micro task into
    the RealmScope.
    
    I thought about creating a new RealmScope for the micro tasks, but
    (1) It did not fix the crashing repro;
    (2) It seems wrong that the micro tasks are executed in a different
        realm than the script;
    
    Therefore I just moved the execution of the micro tasks into the
    RealmScope of the script.
    
    Thereby I moved the execution tasks also into the Context::Scope of the
    script. The problem is that the Context::Scope surrounds the RealmScope,
    and when I to open the RealmScope before the Context::Scope, not even
    the execution of the script works anymore.
    
    R=yangguo@chromium.org
    
    Bug: chromium:797846
    Change-Id: If152af282beec8f0b0564dcc9682fee8588e142c
    Reviewed-on: https://chromium-review.googlesource.com/856497Reviewed-by: 's avatarYang Guo <yangguo@chromium.org>
    Commit-Queue: Andreas Haas <ahaas@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#50442}
    1016e625
Name
Last commit
Last update
..
benchmarks Loading commit data...
cctest Loading commit data...
common Loading commit data...
debugger Loading commit data...
fuzzer Loading commit data...
inspector Loading commit data...
intl Loading commit data...
js-perf-test Loading commit data...
memory Loading commit data...
message Loading commit data...
mjsunit Loading commit data...
mkgrokdump Loading commit data...
mozilla Loading commit data...
preparser Loading commit data...
test262 Loading commit data...
unittests Loading commit data...
wasm-spec-tests Loading commit data...
webkit Loading commit data...
BUILD.gn Loading commit data...
bot_default.gyp Loading commit data...
bot_default.isolate Loading commit data...
default.gyp Loading commit data...
default.isolate Loading commit data...
optimize_for_size.gyp Loading commit data...
optimize_for_size.isolate Loading commit data...
perf.gyp Loading commit data...
perf.isolate Loading commit data...