-
Notifications
You must be signed in to change notification settings - Fork 30k
New issue
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
Compile failure in simdjson using GCC 14 or clang 18.1 (Node 20.12.1 - 22.1.0) #52876
Comments
Gentoo bug https://bugs.gentoo.org/931267 |
Can you elaborate? |
We've had a few people hit this. I can hit something similar with EDIT: @lemire, would you prefer it if I file a separate bug for the GCC 14 issue? It's probably related but it might well be distinct. |
Hmm seems it is happening with nodejs 20.12.1 too, I wonder if something has happened in a clang-18.1.x update |
I bet it's ninja 1.12.0 |
We had an issue that would be triggered by GCC 14... (e.g., see simdutf fix), but this was fixed (for simdutf) in 5.2.3. Node 22.1.0 has recent versions of simdutf and simdjson that are not affected by such issues. There is currently no known build issues reported directly against simdjson and simdutf (which share a similar runtime dispatching). I find it suspicious that there would be an issue affecting both GCC and LLVM at the same time... and going back to previous Node versions. |
I'll file my own bug (on the simdjson repo, or here?) with reproduction instructions once I have them for GCC 14, as I can still hit it with the fixes for that bug you linked. |
Yeah. If you have reproduction instructions, then file the bug with the libraries, we will fix it there. That would be best. It is easy afterward to bump automagically the fix to Node. Cheers!!!! |
gcc version 13.2.1 20240503 (Gentoo 13.2.1_p20240503 p15) works with Nodejs 20.12.1 & 21.1.0 from my logs I can see: 1712284321: ::: completed emerge (6 of 12) sys-devel/clang-18.1.3 to / |
@thesamesam @FireBurn Can you verify that you are building the correct dependencies in gentoo? That is, Node 22.1 should use simdjson 3.8.0 (or better) and simdutf 5.2.4 (or better). That is what the current Node releases are built with. |
If you want to build with GCC 14 (currently not used in Node.js releases), you need simdjson 3.9.1. Version 3.9.1 is not yet available in Node but should be shortly. |
I am currently installing gentoo (latest) and it seems to be using GCC 13.2.1. |
Yeah, we're not unbundling simdjson or simdutf, so we're using the versions in the nodejs-22.1 tarball.
I'll see if we can update within nodejs downstream for now. It's not critical, as users who are using GCC 14 are opting-in (see below), but it inhibits further testing with the new compiler. I'm going to play with this now. If it's too invasive, I'll just tell people to wait.
Yeah, I committed GCC 14 earlier today, but it's "unkeyworded" (not exposed to users by default). If you put Thank you for your assistance! |
For people reading this. GCC 14 introduced a breaking change (and possibly LLVM 18 followed suit though I am not sure) whereas the value of some macros can change within the same execution unit (something that did not happen before). This has caused breakage in some libraries. Gentoo users caught the issue because they are using a bleeding edge compiler (GCC 14) to compile Node from source. Bug https://bugs.gentoo.org/931150 was marked fixed : the patch is to update simdjson to 3.9.1 or better. Bug https://bugs.gentoo.org/931267 remains unconfirmed, but it is reported as not happening with GCC 13.2.1. At a glance, it looks like a duplicate of https://bugs.gentoo.org/931150 It is likely that all that is needed to fix this is for Node.js to adopt the latest versions of simdjson which should happen automagically. |
Version
20.12.1 - 22.1.0
Platform
Gentoo with GCC 14 or clang 18.1.
Subsystem
simdjson
What steps will reproduce the bug?
This didn't happen with node 20.12.1 which used the older simd(Comments indicate that the build issue is present with earlier versions of Node)How often does it reproduce? Is there a required condition?
No response
What is the expected behavior? Why is that the expected behavior?
No response
What do you see instead?
Compile failure
Additional information
No response
The text was updated successfully, but these errors were encountered: