We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
It seems like assembly for Apple Clang changed:
https://github.com/mratsim/constantine/actions/runs/8862799707/job/24336160802?pr=370
/Users/runner/work/constantine/constantine/constantine/nimcache/libcurves_headers/@m..@sconstantine@splatforms@sisa@scpudetect_x86.nim.c:80:8: error: invalid output constraint '=a' in asm :"=a"(result.eax), "=b"(result.ebx), "=c"(result.ecx), "=d"(result.edx) ^
constantine/constantine/platforms/isa/cpudetect_x86.nim
Lines 17 to 36 in 976c8bb
The text was updated successfully, but these errors were encountered:
It seems like the MacOS CI is now using ARM CPUs:
and the make_headers task assumes it is running on x86
make_headers
Executing task make_lib in /Users/runner/work/constantine/constantine/constantine/constantine.nimble Compiling static library: lib/libconstantine.a.arm Compiling static library: lib/libconstantine.a.x64 Compiling dynamic library: lib/libconstantine.dylib.arm ld: warning: ignoring duplicate libraries: '-lm' Compiling dynamic library: lib/libconstantine.dylib.x64 ld: warning: ignoring duplicate libraries: '-lm' Executing task make_headers in /Users/runner/work/constantine/constantine/constantine/constantine.nimble /Users/runner/work/constantine/constantine/constantine/nimcache/libcurves_headers/@m..@sconstantine@splatforms@sisa@scpudetect_x86.nim.c:80:8: error: invalid output constraint '=a' in asm :"=a"(result.eax), "=b"(result.ebx), "=c"(result.ecx), "=d"(result.edx) ^
However building a fat binary for both x86 and ARM works well.
Sorry, something went wrong.
Cross-compiling for Linux ARM64 on Linux x86 host works with Clang.
However looking at the error message we can see Nim Compiler version 1.6.21 [MacOSX: amd64] but the host is actually arm64-apple-darwin23.4.0
Nim Compiler version 1.6.21 [MacOSX: amd64]
arm64-apple-darwin23.4.0
So I suspect Nim is actually running through Rosetta and "thinks" it is on a x86 platform, which leads to this const X86 check being mistakenly true:
const X86
constantine/constantine/platforms/config.nim
Lines 12 to 13 in 976c8bb
No branches or pull requests
It seems like assembly for Apple Clang changed:
https://github.com/mratsim/constantine/actions/runs/8862799707/job/24336160802?pr=370
constantine/constantine/platforms/isa/cpudetect_x86.nim
Lines 17 to 36 in 976c8bb
The text was updated successfully, but these errors were encountered: