- 04 Mar, 2019 1 commit
-
-
Benedikt Meurer authored
In the early days of Chrome when we used WebKit there was no support for ASCII strings on the C++ side, so we put a hint onto these two-byte strings that said "string only contains one byte data", such that internally in V8 when these were involved in string operations, we could instead create the *cheaper* one byte strings. Nowadays Blink properly supports one-byte string representations and this additional hint only comes with overhead, since we check it in quite a few places (i.e. on the hot path for string concatenation), plus we end up consuming more memory due to the additional string maps. Removing the hint also frees one bit in the InstanceType zoo for strings. This alone improves performance on the `bench-dom-serialize.js` test case by around **3%**. Tbr: mstarzinger@chromium.org Bug: v8:6622, v8:8834, v8:8939 Cq-Include-Trybots: luci.chromium.try:linux-blink-rel Change-Id: I0753f2859cee7b5a37b6f0da64d8ec39fcb044ff Doc: https://bit.ly/fast-string-concatenation-in-javascript Reviewed-on: https://chromium-review.googlesource.com/c/1498478 Commit-Queue: Benedikt Meurer <bmeurer@chromium.org> Reviewed-by:
Yang Guo <yangguo@chromium.org> Cr-Commit-Position: refs/heads/master@{#60006}
-
- 21 Feb, 2019 1 commit
-
-
Igor Sheludko authored
With 32-bit kTaggedSize small strings may be not externalizable. Bug: v8:7703 Change-Id: I34002568214742dadb2358fca97dfb4b92a5342a Reviewed-on: https://chromium-review.googlesource.com/c/1480373Reviewed-by:
Toon Verwaest <verwaest@chromium.org> Commit-Queue: Igor Sheludko <ishell@chromium.org> Cr-Commit-Position: refs/heads/master@{#59770}
-
- 30 Nov, 2017 2 commits
-
-
Michael Achenbach authored
This reverts commit e42e7fc8. Reason for revert: Speculative revert for: https://crbug.com/v8/7149 Original change's description: > [objects] No longer create short external strings. > > This fixes String::MakeExternal() to bail out if the subject string > doesn't fit a regular ExternalString, instead of creating a short > external string. The observation here is that for short external strings > the overhead of having to have the StringResource plus going to the > runtime/C++ for each and every character access from JavaScript land > is probably bigger than the anticipated benefits. > > If this turns out to be wrong and there's a real benefit, we should make > use of ThinStrings instead of having a separate way to represent > external strings. > > Bug: v8:6621, v8:7109, v8:7145 > Change-Id: I4b75da08b82a72027c782a69de9c8eaf3cca1d4d > Reviewed-on: https://chromium-review.googlesource.com/799750 > Reviewed-by: Yang Guo <yangguo@chromium.org> > Commit-Queue: Benedikt Meurer <bmeurer@chromium.org> > Cr-Commit-Position: refs/heads/master@{#49735} TBR=yangguo@chromium.org,bmeurer@chromium.org Change-Id: I3f5cfa9ab5c99ddce1d61ede9ed9515cb3936cdd No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: v8:6621, v8:7109, v8:7145, v8:7149 Reviewed-on: https://chromium-review.googlesource.com/801675Reviewed-by:
Michael Achenbach <machenbach@chromium.org> Commit-Queue: Michael Achenbach <machenbach@chromium.org> Cr-Commit-Position: refs/heads/master@{#49770}
-
Benedikt Meurer authored
This fixes String::MakeExternal() to bail out if the subject string doesn't fit a regular ExternalString, instead of creating a short external string. The observation here is that for short external strings the overhead of having to have the StringResource plus going to the runtime/C++ for each and every character access from JavaScript land is probably bigger than the anticipated benefits. If this turns out to be wrong and there's a real benefit, we should make use of ThinStrings instead of having a separate way to represent external strings. Bug: v8:6621, v8:7109, v8:7145 Change-Id: I4b75da08b82a72027c782a69de9c8eaf3cca1d4d Reviewed-on: https://chromium-review.googlesource.com/799750Reviewed-by:
Yang Guo <yangguo@chromium.org> Commit-Queue: Benedikt Meurer <bmeurer@chromium.org> Cr-Commit-Position: refs/heads/master@{#49735}
-
- 07 Mar, 2017 1 commit
-
-
mvstanton authored
BUG=v8:5267, chromium:692409 Review-Url: https://codereview.chromium.org/2720713003 Cr-Commit-Position: refs/heads/master@{#43638}
-
- 10 Sep, 2014 1 commit
-
-
yangguo@chromium.org authored
R=dcarney@chromium.org, marja@chromium.org Review URL: https://codereview.chromium.org/559913002 git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@23840 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 25 Nov, 2011 1 commit
-
-
yangguo@chromium.org authored
TEST=test/mjsunit/string-external-cached.js Review URL: http://codereview.chromium.org/8680010 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10070 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 23 Nov, 2011 3 commits
-
-
yangguo@chromium.org authored
Review URL: http://codereview.chromium.org/8677006 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10054 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
yangguo@chromium.org authored
Review URL: http://codereview.chromium.org/8681007 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10050 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
yangguo@chromium.org authored
BUG= TEST= Review URL: http://codereview.chromium.org/8635011 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10049 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 17 Nov, 2011 1 commit
-
-
yangguo@chromium.org authored
TEST=test/mjsunit/string-externalize.js Review URL: http://codereview.chromium.org/8513010 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10023 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 28 Oct, 2010 1 commit
-
-
erik.corry@gmail.com authored
Review URL: http://codereview.chromium.org/4116005 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5724 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 17 Jun, 2010 1 commit
-
-
vitalyr@chromium.org authored
If a two-byte string only contains ascii characters, then we can save memory when flattening a cons string containing it. Similarly we can use this in Array.prototype.join implementation. To track this a new bit is added to instance type. This bit is used as a hint in generated code and in runtime functions. To enable testing a new V8 extension is added controlled by --expose-externalize-string flag. Review URL: http://codereview.chromium.org/2762008 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@4894 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-