Reimplement String.prototype.{codePointAt, at} in C++
Categories
(Core :: JavaScript Engine: JIT, enhancement, P1)
Tracking
()
Tracking | Status | |
---|---|---|
firefox124 | --- | fixed |
People
(Reporter: anba, Assigned: anba)
References
(Blocks 1 open bug)
Details
Attachments
(11 files)
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review |
Re-implement String.prototype.{codePointAt, at} in C++ as an alternative to bug 1874373.
Assignee | ||
Comment 1•1 year ago
|
||
- Move
jit::StringFromCharCode
andjit::StringFromCodePoint
to "builtin/String.cpp". - Call
js::StringFrom{CharCode,CodePoint}
instead ofstr_from{CharCode,CodePoint}_one_arg
to avoid unnecessaryJS::Value
boxing. - Replace
str_charCodeAt_impl
by directly callingJSString::getChar
in "jit/Recover.cpp",
which allows to mergestr_charCodeAt_impl
andstr_charCodeAt
. - Add
ToStringIndex
to use a single implementation for the character index computation, but
mark it asMOZ_ALWAYS_INLINE
to ensure we don't observe any calling overhead. - Update spec references and step comments to match the latest spec draft.
- Add trailing comma after
JS_FS_END
for nicer clang-formatting.
Assignee | ||
Comment 2•1 year ago
|
||
Depends on D198557
Assignee | ||
Comment 3•1 year ago
|
||
Used in part 5.
Depends on D198558
Assignee | ||
Comment 4•1 year ago
|
||
Move the existing surrogate code point test code into MacroAssembler in
preparation for part 5.
Depends on D198559
Assignee | ||
Comment 5•1 year ago
|
||
Extend MacroAssembler::loadStringChar
and the corresponding branch methods to
support loading code points from a string.
Depends on D198560
Assignee | ||
Comment 6•1 year ago
|
||
Depends on D198561
Assignee | ||
Comment 7•1 year ago
|
||
Transpile LoadStringCodePoint
similar to how LoadStringCharCodeResult
is processed.
Depends on D198562
Assignee | ||
Comment 8•1 year ago
|
||
Depends on D198563
Assignee | ||
Comment 9•1 year ago
|
||
Used in part 10.
Depends on D198564
Assignee | ||
Comment 10•1 year ago
|
||
Depends on D198565
Assignee | ||
Comment 11•1 year ago
|
||
Transpile LoadStringAtResult
similar to how LoadStringCharResult
is processed.
Depends on D198566
Updated•1 year ago
|
Updated•1 year ago
|
Comment 12•1 year ago
|
||
Comment 13•1 year ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/8fd07a0373ed
https://hg.mozilla.org/mozilla-central/rev/167fa0e1edfc
https://hg.mozilla.org/mozilla-central/rev/041a4d1c5612
https://hg.mozilla.org/mozilla-central/rev/3300300f9bcc
https://hg.mozilla.org/mozilla-central/rev/018fe863b284
https://hg.mozilla.org/mozilla-central/rev/bfe3913d8912
https://hg.mozilla.org/mozilla-central/rev/e99e8882a3d7
https://hg.mozilla.org/mozilla-central/rev/6e500448d6a9
https://hg.mozilla.org/mozilla-central/rev/e267856d532c
https://hg.mozilla.org/mozilla-central/rev/2098e0be66bf
https://hg.mozilla.org/mozilla-central/rev/3f41e0c8e5a1
Description
•