Compressed debug info sections and big-endian targets
- Reply: Brooks Davis : "Re: Compressed debug info sections and big-endian targets"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 07 Aug 2021 16:07:39 UTC
GCC and Clang/LLVM support coimpressed debug info, which compresses the .debug_* ELF sections in objects, archives, libraries, and executables. I recently committed build infrastructure changes to turn this on (c910570e7573) but it broke the build on big-endian targets (mips, powerpc) and so disabled it again (89ed2ecb14ce). PR257638 has more details. The lld bug is now fixed in main thanks to Simon Atanasyan upstream and dim@ for merging it over (d69d07569ee2), and I would like to enable it again. An outstanding issue is that the bug is triggered by the linker's input, and so this will occur if we attempt to link against a base system .a archive using a buggy lld. In the short term I think we have no choice but to leave compressed debug disabled on BE targets, until fixed lld versions are available in ports/packages. I have a review open to enable it for LE targets only: https://reviews.freebsd.org/D31454. I'd like to apply that change for now, but would like to enable compressed debug across all targets in the future. This would break, on big-endian targets, any port that has a build-dependency on an older lld and links against a base system archive. Such a port could be fixed by switching to linking with binutils ld, or lld from the base system or a newer package. What do big-endian mips or powerpc users think?