You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
nodejs 24.0.1 tries and fails to link v8's maglev on s390x #58954
Linux ce914293929347cba01065b95f8f20e8 6.15.4-200.fc42.x86_64 #1 SMP PREEMPT_DYNAMIC Fri Jun 27 15:32:46 UTC 2025 s390x GNU/Linux
Subsystem
No response
What steps will reproduce the bug?
Try to build nodejs 24.0.1 on s390x without touching any configure options specifically mentioning v8 or it's maglev subsystem.
How often does it reproduce? Is there a required condition?
Always.
What is the expected behavior? Why is that the expected behavior?
Node compiles and links into usable artifacts.
What do you see instead?
The compilation proceeds up until trying to link v8, at which point ld fails with bunch of duplicate definitions in maglev. One example for all:
/usr/bin/ld: obj/tools/v8_gypfiles/../../deps/v8/src/maglev/v8_compiler.maglev-compilation-info.o (symbol from plugin): in function `v8::internal::maglev::MaglevCompilationInfo::ReopenAndCanonicalizeHandlesInNewScope(v8::internal::Isolate*)':
(.text+0x0): multiple definition of `v8::internal::maglev::MaglevCompilationInfo::ReopenAndCanonicalizeHandlesInNewScope(v8::internal::Isolate*)'; obj/tools/v8_gypfiles/../../deps/v8/src/maglev/v8_base_without_compiler.maglev-compilation-info.o:/builddir/build/BUILD/nodejs24-24.0.1-build/node-v24.0.1/out/Release/../../deps/v8/src/maglev/maglev-compilation-info.cc:162: first defined here
The issue does not manifest on v22, namely version 22.17.0 compiles and links successfully in the same environment and with the same configuration options.
According to configure.py output, 'v8_enable_maglev': 0, but the sources are still compiled and attempted to be linked.
I don't need maglev to work on s390x; disabling it's compilation properly is acceptable outcome.
changed the title [-]nodejs 24.0.1 tries and fails to link maglev on s390x[/-][+]nodejs 24.0.1 tries and fails to link v8's maglev on s390x[/+]on Jul 4, 2025
@khardix Would you be able to see if #58861 changes anything since it concerns "duplicate symbols during linking if maglev is disabled or not available for the target"?
Also we're not seeing this on the builds here -- differences between our builds and the Fedora build log that could cause a difference:
builds here
Fedora
gcc 12.2.1
gcc 15.1.1
built with make
built with ninja
no LTO
LTO enabled
@miladfarca have we hit anything similar in upstream V8 on s390x?
Activity
khardix commentedon Jul 4, 2025
@richardlau FYI; not sure if you are the right person to pull in.
[-]nodejs 24.0.1 tries and fails to link maglev on s390x[/-][+]nodejs 24.0.1 tries and fails to link v8's maglev on s390x[/+]richardlau commentedon Jul 4, 2025
@khardix Would you be able to see if #58861 changes anything since it concerns "duplicate symbols during linking if maglev is disabled or not available for the target"?
Also we're not seeing this on the builds here -- differences between our builds and the Fedora build log that could cause a difference:
makeninja@miladfarca have we hit anything similar in upstream V8 on s390x?
khardix commentedon Jul 4, 2025
We did try disabling (not enabling) LTO previously, it looks like it has no impact on this. Results are the same in both cases.
I'll test whether the linker PR will have an impact.
miladfarca commentedon Jul 4, 2025
No we haven't hit anything similar, keep in mind we build with maglev enabled on s390x by default.
Some files do get built even with maglev disabled and
maglev-compilation-info.ccis one of them:https://github.com/v8/v8/blob/abe8d490e99a33e707e129a6a69dbd44917e95f7/BUILD.gn#L5225
That specific symbol should also only be defined here: https://github.com/v8/v8/blob/abe8d490e99a33e707e129a6a69dbd44917e95f7/src/maglev/maglev-compilation-info.cc#L152
richardlau commentedon Jul 4, 2025
I've reproduced this on test-ibm-rhel8-s390x-4 with gcc 12 and
It did not happen with
I'm going to check with
--sharedbut without ninja.richardlau commentedon Jul 4, 2025
Reproduces with
i.e. it's something to do with
--sharedand not related to make/ninja.richardlau commentedon Jul 4, 2025
It does appear that #58861 should fix this. @khardix it would be great if you're able to confirm.
khardix commentedon Jul 7, 2025
Confirming that #58861 seems to fix this. Thanks for the pointer!
I would like to leave this open until the PR lands, but I'm not sure whether someone will notice and close it then.
tools: compile maglev files into v8_compiler if maglev is disabled
tools: compile maglev files into v8_compiler if maglev is disabled