• gsathya's avatar
    Promises: Make debug calls only when debugging · 9eb320ad
    gsathya authored
    Previously, certain calls to DebugPushPromise and DebugPopPromise
    happened always, without any check to see if we were in a debugging
    environment. This patch adds a conditional check before making these
    debug calls to make sure they aren't called when not needed.
    
    Before the patch, running --prof over the bluebird benchmarks,
    brings up these unprotected debug calls --
    ticks    cpp   total   name
    16    6.7%    2.0%  v8::internal::Runtime_DebugPushPromise(int, v8::internal::Object**, v8::internal::Isolate*)
    7    2.9%    0.9%  v8::internal::Runtime_DebugPopPromise(int, v8::internal::Object**, v8::internal::Isolate*)
    
    This patch removes the above calls and provides a 4% improvement (with
    a 2% variance over 10 runs) in the bluebird benchmark.
    
    Review-Url: https://codereview.chromium.org/1985293002
    Cr-Commit-Position: refs/heads/master@{#36451}
    9eb320ad
Name
Last commit
Last update
benchmarks Loading commit data...
build_overrides Loading commit data...
docs Loading commit data...
gypfiles Loading commit data...
include Loading commit data...
infra Loading commit data...
samples Loading commit data...
src Loading commit data...
test Loading commit data...
testing Loading commit data...
third_party/binutils Loading commit data...
tools Loading commit data...
.clang-format Loading commit data...
.gitignore Loading commit data...
.gn Loading commit data...
.ycm_extra_conf.py Loading commit data...
AUTHORS Loading commit data...
BUILD.gn Loading commit data...
CODE_OF_CONDUCT.md Loading commit data...
ChangeLog Loading commit data...
DEPS Loading commit data...
LICENSE Loading commit data...
LICENSE.strongtalk Loading commit data...
LICENSE.v8 Loading commit data...
LICENSE.valgrind Loading commit data...
Makefile Loading commit data...
Makefile.android Loading commit data...
Makefile.nacl Loading commit data...
OWNERS Loading commit data...
PRESUBMIT.py Loading commit data...
README.md Loading commit data...
WATCHLISTS Loading commit data...
codereview.settings Loading commit data...
snapshot_toolchain.gni Loading commit data...