Optimize more key types for GetElem/SetElem
Categories
(Core :: JavaScript Engine: JIT, task, P2)
Tracking
()
People
(Reporter: jandem, Unassigned)
References
(Blocks 1 open bug)
Details
(Whiteboard: [sp3])
The VMFunction list in bug 1935626 shows we have 435312 calls to IonGetPropertyIC::update on Speedometer 3.
I looked into this more and 80% of these are for a megamorphic GetElem property access in react-stockcharts where the property key is sometimes a boolean. Fortunately it's easy to fix our CacheIR generator to treat these as "true"/"false" keys.
The #2 case with ~7% uses an array index of -1. This is the same issue as bug 1932864 comment 4.
The upside is that apart from these edge cases we have great CacheIR coverage for property accesses nowadays.
| Reporter | ||
Updated•1 year ago
|
Updated•1 year ago
|
Updated•1 year ago
|
| Reporter | ||
Comment 1•1 year ago
|
||
Handling negative integers such as -1 is more complicated because typed arrays have different behavior for negative integers vs regular named properties.
| Reporter | ||
Comment 2•1 year ago
|
||
(In reply to Jan de Mooij [:jandem] from comment #1)
Handling negative integers such as
-1is more complicated because typed arrays have different behavior for negative integers vs regular named properties.
Actually this isn't an issue because we already have to support string keys like object["-1"], so turning object[-1] into object["-1"] should be completely fine for typed arrays too.
| Reporter | ||
Updated•1 year ago
|
Updated•1 year ago
|
Comment 3•4 months ago
|
||
Anything left to do here?
Updated•1 month ago
|
Description
•