Closed
Bug 512640
Opened 15 years ago
Closed 15 years ago
nanojit: refactor Assembler::findRegFor()
Categories
(Core :: JavaScript Engine, defect)
Tracking
()
RESOLVED
FIXED
People
(Reporter: n.nethercote, Assigned: n.nethercote)
References
Details
(Whiteboard: fixed-in-tracemonkey)
Attachments
(1 file)
4.33 KB,
patch
|
edwsmith
:
review+
|
Details | Diff | Splinter Review |
findRegFor() currently involves a hard-to-follow combination of complex control flow and assignments. This patch refactors it so it's much easier to follow. I did the refactoring by carefully making a succession of small, mechanical changes, so I'm fairly confident it's correct. The logic is certainly clearer, esp. that there are four main cases. There is some repetition in the new version relating to hint() and the registerAlloc()/addActive() pair, but I don't think that's so bad. (The registerAlloc()/addActive() cases could be cleaned up by better handling of RegAlloc invariants, as mentioned in bug 512634.) The source code is a little shorter, the binary code is a little longer, and SunSpider speed hasn't changed.
Attachment #396670 -
Flags: review?(edwsmith)
Updated•15 years ago
|
Attachment #396670 -
Flags: review?(edwsmith) → review+
Assignee | ||
Comment 1•15 years ago
|
||
http://hg.mozilla.org/tracemonkey/rev/6c0862612a4a
Whiteboard: fixed-in-tracemonkey
Assignee | ||
Comment 2•15 years ago
|
||
Follow-up commit to remove a stray debugging printf(): http://hg.mozilla.org/tracemonkey/rev/430c1f40b6cd
Comment 3•15 years ago
|
||
http://hg.mozilla.org/mozilla-central/rev/6c0862612a4a
Status: ASSIGNED → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
Comment 4•15 years ago
|
||
http://hg.mozilla.org/mozilla-central/rev/430c1f40b6cd
Comment 5•15 years ago
|
||
http://hg.mozilla.org/releases/mozilla-1.9.2/rev/386507096392
Flags: wanted1.9.2+
You need to log in
before you can comment on or make changes to this bug.
Description
•