Closed Bug 610323 Opened 14 years ago Closed 13 years ago

[TraceMonkey] Implement Jaegermonkey Sparc back-end.

Categories

(Core :: JavaScript Engine, defect)

Sun
Solaris
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: leon.sha, Assigned: leon.sha)

Details

(Whiteboard: fixed-in-tracemonkey)

Attachments

(3 files, 3 obsolete files)

Attached patch patch (obsolete) — Splinter Review
Need to implement Jaegermonkey Sparc back-end.
Attachment #488819 - Attachment is patch: true
Attachment #488819 - Attachment mime type: application/octet-stream → text/plain
Attachment #488819 - Flags: review?(dvander)
Assignee: general → leon.sha
Status: NEW → ASSIGNED
Attached patch Patch to add PolyIC support (obsolete) — Splinter Review
Attachment #488819 - Attachment is obsolete: true
Attachment #491082 - Flags: review?
Attachment #488819 - Flags: review?(dvander)
Attachment #491082 - Flags: review? → review?(dvander)
Comment on attachment 491082 [details] [diff] [review] Patch to add PolyIC support Not done reviewing yet, but here's some initial comments... >+ static void cacheFlush(void* code, size_t size) >+ { >+ caddr_t v = (caddr_t)code; >+ caddr_t end = v + size; >+ caddr_t p = v; >+ while (p < end) { >+ asm("flush %0" : : "r" (p)); >+ p += 32; >+ } >+ } Not sure what happened with spacing here. >+#if WTF_CPU_BIG_ENDIAN >+ static const uint32 PAYLOAD_OFFSET = 4; >+ static const uint32 TAG_OFFSET = 0; >+#else > static const uint32 PAYLOAD_OFFSET = 0; > static const uint32 TAG_OFFSET = 4; >+#endif Use IS_BIG_ENDIAN here to avoid WTF_* leaking outside of assembler. >+#if defined JS_CPU_X86 || defined JS_CPU_ARM || defined JS_CPU_SPARC > static const int CanonicalNaNType = 0x7FF80000; > masm.setPtr(oppositeCond, treg, Imm32(CanonicalNaNType), result); > #elif defined JS_CPU_X64 > static const void *CanonicalNaNType = (void *)0x7FF8000000000000; > masm.move(ImmPtr(CanonicalNaNType), JSC::X86Registers::r11); > masm.setPtr(oppositeCond, treg, JSC::X86Registers::r11, result); > #endif #ifndef JS_64BIT ... #else should be good enough here. Bonus points if you change that r11 to be scratchRegister. >+#if WTF_CPU_BIG_ENDIAN >+ static const uint32 POLY_PAYLOAD_OFFSET = 4; >+ static const uint32 POLY_TAG_OFFSET = 0; >+#else >+ static const uint32 POLY_PAYLOAD_OFFSET = 0; >+ static const uint32 POLY_TAG_OFFSET = 4; Why do we need to dupliate this from BaseAssembler? CC'ing Chris Leary for the regex changes.
Attachment #491082 - Flags: review?(cdleary)
Attached patch Patch v2 with David's comments. (obsolete) — Splinter Review
Make some changes according to David's Comments. Also I changed some bit value type from int to int32. Also I expand the size of "secondShapeGuard" to 11 bits since 8 bits is not enough for Sparc.
Attachment #491082 - Attachment is obsolete: true
Attachment #494895 - Flags: review?(dvander)
Attachment #491082 - Flags: review?(dvander)
Attachment #491082 - Flags: review?(cdleary)
Attachment #494895 - Flags: review?(cdleary)
I know it's not my bug but -- review ping? I'd like to see this get merged in with the mainline before it rots. According to these SunSpiders numbers, it's already shipping as a contrib build: Both: 1653 TM Only: 2012 JM Only: 1769 Interp Only: 7015 (SunFire v240, lightly loaded, 2x1503MHz cores, 4096MB physmem, 5.10 in a sparse-root zone)
Attachment #494895 - Attachment is obsolete: true
Attachment #494895 - Flags: review?(dvander)
Attachment #494895 - Flags: review?(cdleary)
Attached patch Patch part 2Splinter Review
Attachment #522932 - Flags: review?(dvander)
Attachment #522933 - Flags: review?(dvander)
Attachment #522932 - Flags: review?(dvander) → review+
Comment on attachment 522933 [details] [diff] [review] Patch part 2 Sorry about the delay, and thanks for fixing all the payloadOf() misuses! > // obj->getFlatClosureUpvars() > masm.loadPtr(Address(reg, offsetof(JSObject, slots)), reg); > Address upvarAddress(reg, JSObject::JSSLOT_FLAT_CLOSURE_UPVARS * sizeof(Value)); >- masm.loadPrivate(upvarAddress, reg); >+ masm.loadPrivate(masm.payloadOf(upvarAddress), reg); loadPrivate() always takes a Value*, so I would move the payloadOf() call into loadPrivate(). r=me with that
Attachment #522933 - Flags: review?(dvander) → review+
Attached patch patch part 2 v2Splinter Review
I put the payloadof inside loadprivate. Also I change the cacheFlush to be the same as flushICache in nanojit.
Attachment #526677 - Flags: review?(dvander)
Attachment #526677 - Flags: review?(dvander) → review+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: