Closed Bug 670626 Opened 11 years ago Closed 11 years ago

IonMonkey: Replace LSRA vregs with operator-overloady class

Categories

(Core :: JavaScript Engine, defect)

x86_64
Linux
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: adrake, Assigned: adrake)

References

Details

Attachments

(1 file)

It would clean up LSRA code quite a bit if the virtual register map could be indexed by definition and use instead of just by integer.
Attached patch Patch v0Splinter Review
Well, you asked for more operator overloading, so here you go! I feel a bit dirtier for having written "operator" this many times in a single patch.

It seems to have cleaned up the register allocator a little bit, but it's no miracle. Thoughts?
Attachment #545204 - Flags: review?(dvander)
Comment on attachment 545204 [details] [diff] [review]
Patch v0

Seems to be marginally cleaner, but like you said no miracle. Up to you. Seems slightly better than passing uint32 register IDs around since the key acts like a stricter type.
Attachment #545204 - Flags: review?(dvander) → review+
That's a good point -- I hadn't considered the stricter typing. That's a nice win, I think.

http://hg.mozilla.org/users/danderson_mozilla.com/ionmonkey/rev/f1ee6077ef96
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.