• Z Nguyen-Huu's avatar
    Reland "Improve NumberToString when cache miss and Smi" · 22874998
    Z Nguyen-Huu authored
    This is a reland of 1b35c0fa
    
    Reason for revert: Seems to reliably break a numerics test:
    https://ci.chromium.org/p/v8/builders/ci/V8%20Linux%20-%20debug/31516
    
    It was really slow and timeout with debug build run this test
    mjsunit/math-exp-precision with --optimize-for-size because we resize
    cache in CSA. Default this to runtime would avoid the timeout.
    
    Also with --optimize-for-size, we don't have enough space to allocate
    full-size cache so avoid to resize cache in this case.
    
    In my local PC, time for this test decreases as follows.
    Before: 52s
    After: 3s
    
    Original change's description:
    > Improve NumberToString when cache miss and Smi
    >
    > Cache miss was handled in runtime before. This change add fast path for
    > Smi in this case.
    >
    > Perf show 30% improvement for the following example.
    > Before 67 ms
    > After 42 ms
    >
    > const start = new Date();
    > const MAX = 1000000;
    > for (var i = 0; i < MAX; i++) {
    >     i.toString();
    > }
    > const end = new Date();
    > console.log("Time :"+ (end-start));
    >
    > Change-Id: I162e9c35f58551ca6a5a0efe79fb7c7b482a8594
    > Bug: v8:10477
    > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2332866
    > Commit-Queue: Z Nguyen-Huu <duongn@microsoft.com>
    > Reviewed-by: Jakob Gruber <jgruber@chromium.org>
    > Cr-Commit-Position: refs/heads/master@{#69362}
    
    Bug: v8:10477
    Change-Id: I892a9007210032640d0bf22e61c8e7ad1a4377c4
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2351398Reviewed-by: 's avatarLeszek Swirski <leszeks@chromium.org>
    Reviewed-by: 's avatarCamillo Bruni <cbruni@chromium.org>
    Commit-Queue: Leszek Swirski <leszeks@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#69413}
    22874998
Name
Last commit
Last update
..
api Loading commit data...
asmjs Loading commit data...
ast Loading commit data...
base Loading commit data...
builtins Loading commit data...
codegen Loading commit data...
common Loading commit data...
compiler Loading commit data...
compiler-dispatcher Loading commit data...
d8 Loading commit data...
date Loading commit data...
debug Loading commit data...
deoptimizer Loading commit data...
diagnostics Loading commit data...
execution Loading commit data...
extensions Loading commit data...
flags Loading commit data...
handles Loading commit data...
heap Loading commit data...
ic Loading commit data...
init Loading commit data...
inspector Loading commit data...
interpreter Loading commit data...
json Loading commit data...
libplatform Loading commit data...
libsampler Loading commit data...
logging Loading commit data...
numbers Loading commit data...
objects Loading commit data...
parsing Loading commit data...
profiler Loading commit data...
protobuf Loading commit data...
regexp Loading commit data...
roots Loading commit data...
runtime Loading commit data...
sanitizer Loading commit data...
snapshot Loading commit data...
strings Loading commit data...
tasks Loading commit data...
third_party Loading commit data...
torque Loading commit data...
tracing Loading commit data...
trap-handler Loading commit data...
utils Loading commit data...
wasm Loading commit data...
zone Loading commit data...
DEPS Loading commit data...
OWNERS Loading commit data...