Closed
Bug 1480594
Opened 6 years ago
Closed 6 years ago
make the jit compilable under aarch64 windows
Categories
(Core :: JavaScript Engine: JIT, enhancement, P2)
Tracking
()
RESOLVED
FIXED
mozilla64
People
(Reporter: froydnj, Assigned: froydnj)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
1.69 KB,
patch
|
sstangl
:
review+
|
Details | Diff | Splinter Review |
Trying to compile any of the JIT code under aarch64 windows results in a mess of compilation errors. It appears that Microsoft has defined macros for every aarch64 instruction, or something like that? You get errors about "not enough arguments for function-like macro invocation mvn" or "move32". There's also some weird warnings about undeclared identifiers like opeqneoneg. We can sort those out later. Note: this is not about actually providing JIT support for aarch64 windows; this is just getting the code to compile. I suspect we'll want to turn the JIT off initially, or something like that.
Updated•6 years ago
|
status-firefox63:
--- → fix-optional
Priority: -- → P2
Updated•6 years ago
|
Flags: needinfo?(ajones)
Assignee | ||
Comment 1•6 years ago
|
||
Various assembler methods don't play nicely with Windows headers and their constant macro definitions, so we have to #undef a few things along the way. I'm not sure what the Right Way is to patch vixl, so posting this as a sort of starting point.
Attachment #9005004 -
Flags: review?(jitbugs)
Updated•6 years ago
|
Attachment #9005004 -
Flags: review?(jitbugs) → review?(sstangl)
Comment 2•6 years ago
|
||
You could also add this to js/src/util/Windows.h maybe? https://searchfox.org/mozilla-central/source/js/src/util/Windows.h
Assignee | ||
Comment 3•6 years ago
|
||
(In reply to Jan de Mooij [:jandem] from comment #2) > You could also add this to js/src/util/Windows.h maybe? > > https://searchfox.org/mozilla-central/source/js/src/util/Windows.h Empirical evidence says that this is insufficient. The macros are defined in arm64_neon.h, and if I understand the include paths correctly, we have something like: vm/Time.h -> intrin.h -> arm64_neon.h and vm/Time.h gets pulled in through various sources (vm/JSScript.h, vm/Realm.h, vm/DateTime.h), which I assume somehow get pulled into the macro assembler headers in some fashion?
Assignee | ||
Comment 4•6 years ago
|
||
Hm, no, intrin.h only gets pulled in on x86-ish machines. So maybe I really do have to struggle through /showIncludes to figure out what's going on.
Assignee | ||
Comment 5•6 years ago
|
||
OK, so the intrin.h include comes via mozilla/MathAlgorithms.h -> cmath -> intrin.h, which is probably quite difficult to fix "properly". =/ I guess we could include the undefs in MathAlgorithms.h, but that feels like a hack.
Comment 6•6 years ago
|
||
Ah fair enough, thanks for checking. I thought this came in via <windows.h>
Comment 7•6 years ago
|
||
Comment on attachment 9005004 [details] [diff] [review] undefine a few macros for aarch64 windows's benefit Review of attachment 9005004 [details] [diff] [review]: ----------------------------------------------------------------- It is an odd move on Microsoft's part to effectively reserve keywords with such short names. This patch is perfectly OK for the moment if it helps get things compiling.
Attachment #9005004 -
Flags: review?(sstangl) → review+
Pushed by nfroyd@mozilla.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/2ab5c5c57528 undefine a few macros for aarch64 windows's benefit; r=sstangl
Comment 9•6 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/2ab5c5c57528
Status: NEW → RESOLVED
Closed: 6 years ago
status-firefox64:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla64
Updated•6 years ago
|
Assignee: nobody → nfroyd
Updated•6 years ago
|
Updated•6 years ago
|
Flags: needinfo?(ajones)
You need to log in
before you can comment on or make changes to this bug.
Description
•