[compiler-rt] [compiler-rt][test][builtins] Check linker support for --start-group (NFC) (PR #205610)
Joseph Huber via llvm-commits
llvm-commits at lists.llvm.org
Wed Jun 24 12:50:54 PDT 2026
================
@@ -107,9 +107,19 @@ def get_libgcc_file_name():
if config.target_os == "Haiku":
config.substitutions.append(("%librt ", base_lib + " -lroot "))
else:
- config.substitutions.append(
- ("%librt ", "-lm -Wl,--start-group " + base_lib + " -lc -Wl,--end-group ")
+ # Check if the linker supports --start-group and --end-group
+ linker_supports_start_group = get_required_attr(
+ config, "linker_supports_start_group"
)
+ if linker_supports_start_group:
----------------
jhuber6 wrote:
Yeah, probably the easiest solution. If we did it 'correctly' it would just return false in all cases for NVPTX, kind of annoying but it's hacks to work around NVIDIA's closed system.
https://github.com/llvm/llvm-project/pull/205610
More information about the llvm-commits
mailing list