#1016628 gcc-12: makes nodejs testsuite fail on mips64el/riscv64 only

Package:
gcc-12
Source:
gcc-12
Description:
GNU C compiler
Submitter:
Jérémy Lal
Date:
2026-07-27 17:35:09 UTC
Severity:
normal
Tags:
#1016628#5
Date:
2022-08-04 07:08:02 UTC
From:
To:
Hi,

If nodejs 18.6.0 is built using gcc-12, several tests fail,
but not when built using gcc-11 (all other things being equal).

*Only* on mips64el and riscv64.

In the logs, some new warnings show up, maybe that can help:
https://buildd.debian.org/status/fetch.php?pkg=nodejs&arch=mips64el&ver=18.6.0%2Bdfsg-4&stamp=1659454899&raw=0

in particular:
/usr/include/c++/12/bits/atomic_base.h:488:31: warning: ‘long unsigned int __atomic_load_8(const volatile void*, int)’ writing 8 bytes into a region of size 0 overflows the destination [-Wstringop-overflow=]
  488 |         return __atomic_load_n(&_M_i, int(__m));

Jérémy

#1016628#16
Date:
2022-08-04 10:18:12 UTC
From:
To:
Jérémy Lal <kapouer@melix.org> 于2022年8月4日周四 15:12写道:

@Xi Ruoyao Is this what you are working on?

#1016628#21
Date:
2022-08-04 10:38:43 UTC
From:
To:
Le jeu. 4 août 2022 à 12:36, Xi Ruoyao <xry111@xry111.site> a écrit :


No evidence yet.
Upstream nodejs says it might very well be a bug on their side.
I'll reassign accordingly.

#1016628#26
Date:
2022-08-04 10:36:12 UTC
From:
To:
If we have evidence showing it's a GCC code generation bug, I'll try to
fix it.  I don't have any interest in node.js.

#1016628#31
Date:
2022-08-05 01:09:41 UTC
From:
To:
Jérémy Lal <kapouer@melix.org> 于2022年8月4日周四 18:39写道:

I mean is it about then zero legth var in C++?

#1016628#36
Date:
2022-08-05 01:21:52 UTC
From:
To:
I don't think they are related.  "writing x bytes into a region of size
0" is a common false warning with GCC 12.  There are multiple PRs about
it and I think this is likely https://gcc.gnu.org/PR104475.