parseInt fast path should return integers instead of doubles

RESOLVED FIXED

Status

()

Core
JavaScript Engine
RESOLVED FIXED
6 years ago
6 years ago

People

(Reporter: jandem, Assigned: jandem)

Tracking

({perf})

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 1 obsolete attachment)

(Assignee)

Description

6 years ago
Many inline paths don't handle doubles so this can cause large performance problems. The TI branch had a fix for this but it regressed again, probably after merging bug 653153.
(Assignee)

Comment 1

6 years ago
Created attachment 537984 [details] [diff] [review]
Patch

Strictly speaking this is not a TI bug, but since TI will merge soon I think we should fix it there to prevent merge problems.
Attachment #537984 - Flags: review?(bhackett1024)
Comment on attachment 537984 [details] [diff] [review]
Patch

setNumber returns whether the number is an int32 (JM branch only), so this can be simplified a bit.
Attachment #537984 - Flags: review?(bhackett1024) → review+
(Assignee)

Comment 3

6 years ago
Created attachment 538063 [details] [diff] [review]
Patch

Rewrote some other calls that use the same setNumber pattern.
Attachment #537984 - Attachment is obsolete: true
Attachment #538063 - Flags: review?(bhackett1024)
Comment on attachment 538063 [details] [diff] [review]
Patch

Nice!
Attachment #538063 - Flags: review?(bhackett1024) → review+
(Assignee)

Comment 5

6 years ago
http://hg.mozilla.org/projects/jaegermonkey/rev/73d2e2357b5b
Status: ASSIGNED → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.