Closed
Bug 1588473
Opened 6 years ago
Closed 6 years ago
Move UINT32_CHAR_BUFFER_LENGTH length check from JSLinearString::isIndexSlow to fast path
Categories
(Core :: JavaScript Engine, task, P1)
Core
JavaScript Engine
Tracking
()
RESOLVED
FIXED
mozilla71
| Tracking | Status | |
|---|---|---|
| firefox71 | --- | fixed |
People
(Reporter: jandem, Assigned: jandem)
Details
Attachments
(1 file)
In https://phabricator.services.mozilla.com/D48495 Waldo suggests moving the UINT32_CHAR_BUFFER_LENGTH length check that's in the out-of-line isIndexSlow into the fast path. Because the fast path already has to check for length == 0, checking the upper bound there as well is cheap (compilers will combine them into a single check ).
| Assignee | ||
Comment 1•6 years ago
|
||
Er, forgot to improve the title.
Summary: Move length checks into JSLinearString::isIndex → Move UINT32_CHAR_BUFFER_LENGTH length check from JSLinearString::isIndexSlow to fast path
| Assignee | ||
Updated•6 years ago
|
Flags: needinfo?(jdemooij)
| Assignee | ||
Comment 2•6 years ago
|
||
We also have to handle |length == 0| there so by checking the upper bound too we
make it possible for C++ compilers to combine them into a single branch.
| Assignee | ||
Updated•6 years ago
|
Assignee: nobody → jdemooij
Status: NEW → ASSIGNED
Flags: needinfo?(jdemooij)
Updated•6 years ago
|
Priority: -- → P1
Pushed by jdemooij@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/1c3c4eeab4b1
Move |length > UINT32_CHAR_BUFFER_LENGTH| check from isIndexSlow slow path to the fast path. r=jwalden
Comment 4•6 years ago
|
||
| bugherder | ||
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
status-firefox71:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla71
You need to log in
before you can comment on or make changes to this bug.
Description
•