On Thu, 6 Aug 2020, Maciej W. Rozycki via Gcc-patches wrote: > Given that for the `riscv64-linux-gnu' target and the ilp32d multilib > glibc currently fails to link against libgcc.a built at -O0 I first ran > reference testing with target libraries built at -O2, but comparing that > to change-under-test -O2 results revealed another issue with GCC target > libraries built at -O0 causing link failures across testsuites, namely > libgcov.a referring atomic primitives where libatomic.a has not been > linked in. I haven't figured out yet if the issue is in libgcov, the > testsuite or the specs. Examples of failures:
That --as-needed -latomic --no-as-needed should be used by default to link in libatomic when required (with consequent changes needed for all testsuites) is a known issue; see bug 81358. Having such references in libgcov simply makes that known issue more visible. -- Joseph S. Myers jos...@codesourcery.com