Package name
firefox
openRuyi version
151.0.4
Relevant log output
Firefox 151.0.4 fails to build on riscv64 when MOZ_PGO=1 is enabled. This happens on both rva20 and rva23 build targets.
The build is configured with crashreporter disabled on riscv64:
ac_add_options --disable-crashreporter
ac_add_options MOZ_PGO=1
The Wayland compositor used for the PGO profile run appears to start successfully:
KWin is running, /home/abuild/firefox-pgo-wayland-0 is here.
However, the build fails before the actual PGO profile run, during the instrumented build link step for libxul.so:
toolkit/library/build/libxul.so
/bin/clang++ ... -fprofile-generate ... -o ../../../dist/bin/libxul.so ...
clang++: error: unable to execute command: Aborted (core dumped)
clang++: error: linker command failed due to signal
The failure happens on both rva20 & rva23.
Additional context
This issue was found while trying to enable PGO for the Firefox package on riscv64.
The current packaging already disables Firefox crashreporter on riscv64 because the C++ Breakpad crash reporter code is not yet ported to riscv64. After disabling crashreporter, the build proceeds further, but PGO still fails during the instrumented libxul.so link stage.
The current suspicion is that the riscv64 PGO instrumented build is too heavy for the current LLVM/lld setup, especially because %{optflags} still contains LTO-related flags such as:
-flto=auto
-ffat-lto-objects
The failing link line also contains -fprofile-generate, so the problematic combination may be:
riscv64 + Firefox libxul.so + PGO instrumentation + LTO/lld
I assert that this issue is relevant for openRuyi
Package name
firefox
openRuyi version
151.0.4
Relevant log output
Firefox 151.0.4 fails to build on riscv64 when
MOZ_PGO=1is enabled. This happens on both rva20 and rva23 build targets.The build is configured with crashreporter disabled on riscv64:
The Wayland compositor used for the PGO profile run appears to start successfully:
However, the build fails before the actual PGO profile run, during the instrumented build link step for
libxul.so:The failure happens on both rva20 & rva23.
Additional context
This issue was found while trying to enable PGO for the Firefox package on riscv64.
The current packaging already disables Firefox crashreporter on riscv64 because the C++ Breakpad crash reporter code is not yet ported to riscv64. After disabling crashreporter, the build proceeds further, but PGO still fails during the instrumented
libxul.solink stage.The current suspicion is that the riscv64 PGO instrumented build is too heavy for the current LLVM/lld setup, especially because
%{optflags}still contains LTO-related flags such as:The failing link line also contains
-fprofile-generate, so the problematic combination may be:I assert that this issue is relevant for openRuyi