Closed
Bug 586224
Opened 14 years ago
Closed 14 years ago
Use clz on android even for armv5 target
Categories
(Core Graveyard :: Nanojit, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: glandium, Assigned: glandium)
References
Details
(Whiteboard: fixed-in-nanojit, fixed-in-tamarin)
Attachments
(2 files)
1.37 KB,
patch
|
jbramley
:
review+
|
Details | Diff | Splinter Review |
1.50 KB,
patch
|
Details | Diff | Splinter Review |
The android gcc compiler refuses to compile 'clz' for armv5, even though it is a legal instruction there, but it can still be tricked into compiling it. This was already discussed in bug 552624
Assignee | ||
Updated•14 years ago
|
Attachment #464742 -
Attachment is patch: true
Attachment #464742 -
Attachment mime type: application/octet-stream → text/plain
Attachment #464742 -
Flags: review?(Jacob.Bramley)
Comment 1•14 years ago
|
||
Comment on attachment 464742 [details] [diff] [review] Patch >-#elif defined(__GNUC__) && !(defined(ANDROID) && __ARM_ARCH__ <= 5) >+#elif defined(__GNUC__) && (NJ_COMPILER_ARM_ARCH >= 5) Ooh, actually the original code was broken here. Thanks for the fix! ---- A couple of tweaks: > // GCC can use inline assembler to insert a CLZ instruction. > __asm ( >+#if defined(ANDROID) && (NJ_COMPILER_ARM_ARCH <= 5) I think this should be "NJ_COMPILER_ARM_ARCH < 7" (or "<= 6"). An Android+ARMv6 build will be broken with your current patch. >+ // On Android gcc compiler, the clz instruction is not supported with a >+ // target smaller than armv7, despite it being legal for armv5+. >+ " .arch armv7\n" ARMv7-M only supports Thumb, so things might get confused as ".arch armv7" is supposed to represent a common set of all profiles. I think ".arch armv7-a" would be better.
Attachment #464742 -
Flags: review?(Jacob.Bramley) → review+
Assignee | ||
Comment 2•14 years ago
|
||
Updated patch with your comments. Where should that land? nanojit-central?
Assignee: nobody → mh+mozilla
Assignee | ||
Comment 3•14 years ago
|
||
http://hg.mozilla.org/projects/nanojit-central/rev/5a56d9f0b2d6
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Whiteboard: fixed-in-nanojit
Assignee | ||
Comment 4•14 years ago
|
||
Reopening, as I've been told nanojit bugs get closed when landing on m-c.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Comment 5•14 years ago
|
||
merged into tamarin-redux http://hg.mozilla.org/tamarin-redux/rev/c97ccde53276
Whiteboard: fixed-in-nanojit → fixed-in-nanojit, fixed-in-tamarin
Comment 6•14 years ago
|
||
http://hg.mozilla.org/mozilla-central/rev/4924f4e8d88f
Status: REOPENED → RESOLVED
Closed: 14 years ago → 14 years ago
Resolution: --- → FIXED
Updated•10 years ago
|
Product: Core → Core Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•