Closed Bug 917509 Opened 11 years ago Closed 1 month ago

Need fast paths (ICs?) for indexed access on DOM lists

Categories

(Core :: JavaScript Engine, defect)

x86
macOS
defect

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: bzbarsky, Unassigned)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

Attached file Testcase
On the attached testcase, only 30% of the time is under the DOM proxy handler's get(), and only 50% is under Proxy::get().

If we had faster paths here we could use them for a self-hosted array_slice too, perhaps.
Is this op/s or time taken to complete?

My results are
Nightly: 77
Chrome 33: 93
IE 11: 386
The output of the testcase is nanoseconds per operation being tested.
And just for comparison, you should replace "l[j]" in the testcase with "l.item(j)", which is supposed to do more or less the same thing, to see how fast the code _could_ go in theory if this bug were fixed.
(In reply to Boris Zbarsky [:bz] (reviews will be slow; ask someone else) from comment #3)
> And just for comparison, you should replace "l[j]" in the testcase with
> "l.item(j)", which is supposed to do more or less the same thing, to see how
> fast the code _could_ go in theory if this bug were fixed.

Then I get:

Nightly - 50
Chrome doesn't seem to like your idea - 2600
IE 11 - 327
Interesting.  For me, Chrome (a 35 dev channel) build shows about the same number with both l.item(j) and l[j]...
Assignee: general → nobody
Blocks: 1105621
Browser: l[j] / l.item(j)
Chrome 39: 99 / 87
Firefox 34: 81 / 36

The difference got bigger in the last 9 months.
Blocks: dom-requests
Severity: normal → S3

Nightly: 15-16
Chrome: 20-22

Should we mark this as fixed? (ni? :mgaudet as he seems to be on triage duty today)

Flags: needinfo?(mgaudet)

Yeah, let's resolve this as WORKSFORME. Thanks for the ping :)

Status: NEW → RESOLVED
Closed: 1 month ago
Flags: needinfo?(mgaudet)
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: