Commit Graph

2 Commits

Author SHA1 Message Date
peterwmwong
986aa36b1f [builtins] Add Array.p.join fastpath for single element array.
This is resurrecting an optimization from the pre-torque version.
Avoid allocating another sequential string for the result when there's only one
element, just return the ToString-ed element.  This not only saves time writing
to this destination string, but also reduce GC pressure.

The System Health Memory Benchmark (load:media:google_images) exposed this missing
optimization with a 15% regression in memory usage.  Very large external strings
were being copied into V8's heap as sequential string.

Bug: chromium:896612
Change-Id: Ieb61906f64100cdc15bf96f3ebcccb1207f75356
Reviewed-on: https://chromium-review.googlesource.com/c/1316620
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Commit-Queue: Peter Wong <peter.wm.wong@gmail.com>
Cr-Commit-Position: refs/heads/master@{#57241}
2018-11-05 14:45:34 +00:00
kozyatinskiy
3903817e0e [inspector] introduced memory size limit for console message storage
Without this CL we have only limit for amount of console messages and if user are dumping a huge messages we pretty soon run out of memory.
So let's introduce limit for memory consumption it would help chromium and Node.js as well.

BUG=chromium:671489
R=dgozman@chomium.org,alph@chromium.org, hpayer@chromium.org, ulan@chromium.org

Review-Url: https://codereview.chromium.org/2653293003
Cr-Commit-Position: refs/heads/master@{#42780}
2017-01-30 17:05:58 +00:00