Closed Bug 541886 Opened 14 years ago Closed 14 years ago

nanojit: move compile() into class Assembler

Categories

(Core Graveyard :: Nanojit, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
Future

People

(Reporter: n.nethercote, Assigned: n.nethercote)

Details

(Whiteboard: fixed-in-nanojit, fixed-in-tracemonkey, fixed-in-tamarin)

Attachments

(2 files)

Attached patch NJ patchSplinter Review
compile() doesn't belong to any class, oddly enough.  Class Assembler is a more sensible place for it, especially since the Assembler object is currently passed as its first argument.  Having moved it, several currently-public Assembler members can be made private.

The only changes with compile() itself are the removal of various 'assm->' qualifiers, and the removal of the local variable 'log' in favour of the class member '_log'.
Attachment #423286 - Flags: review?(rreitmai)
Attached patch TM patchSplinter Review
TM patch.

I haven't done a TR patch yet, there are enough NJ-central patches that haven't yet been merged to TR that it's a pain to do.  Actually, there might not even end up being a TR patch as TR doesn't use compile(), but I'll need to test with TR to make sure that it uses none of the newly-private members.
Attachment #423288 - Flags: review?(dvander)
Comment on attachment 423286 [details] [diff] [review]
NJ patch

Tamarin unfortunately doesn't use compile(), see CodegenLIR.emitMD().

At some point we should, but then we'll also need to add support for disabling some of the pipes; e.g StackFilter.

Also, not sure if _logc being private is going to cause issues with tamarin, but you've probably already checked.
Attachment #423286 - Flags: review?(rreitmai) → review+
Attachment #423288 - Flags: review?(dvander) → review+
http://hg.mozilla.org/tracemonkey/rev/61c3742613eb
Whiteboard: fixed-in-nanojit → fixed-in-nanojit, fixed-in-tracemonkey
Whoops, forgot to commit the TM-specific patch:

http://hg.mozilla.org/tracemonkey/rev/3e6b54b28144
We could also pull the implementation into TM and just leave the declaration in the header.
TR: http://hg.mozilla.org/tamarin-redux/rev/3644
OS: Mac OS X → All
Hardware: x86 → All
Whiteboard: fixed-in-nanojit, fixed-in-tracemonkey → fixed-in-nanojit, fixed-in-tracemonkey, fixed-in-tamarin
Target Milestone: --- → Future
http://hg.mozilla.org/mozilla-central/rev/61c3742613eb
http://hg.mozilla.org/mozilla-central/rev/3e6b54b28144
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: