[PATCH] ld: testsuite: Associate C identifiers with the corresponding assembler or linker symbols in a target-independent manner.

Project / Subsystem

binutils / ld

Date

2026-07-18

Proposer

Jan Dubiec <jdx@o2.pl>

Source type

public_inbox

Consensus

Proposed

Sentiment

/10

Technical tradeoffs

  • Improves testsuite robustness and portability by explicitly defining symbol names, at the cost of slightly more verbose test code.

All attributes

project
binutils
subsystem
ld
patch_id
discussion_id
20260718075339.1022267-1-jdx@o2.pl
source_type
public_inbox
title
[PATCH] ld: testsuite: Associate C identifiers with the corresponding assembler or linker symbols in a target-independent manner.
headline
ld: testsuite: Associate C identifiers with the corresponding assembler or linker symbols in a target-independent manner.
tldr
Uses `asm` keyword to make C identifier to symbol mapping target-independent in linker tests.
proposer
Jan Dubiec <jdx@o2.pl>
consensus
Proposed
outcome
proposed
sentiment_score
technical_tradeoffs
  • Improves testsuite robustness and portability by explicitly defining symbol names, at the cost of slightly more verbose test code.
series_id
series_role
standalone
series_parts
[]
tags
  • binutils
  • ld
  • linker
  • testsuite
  • ABI
bugzilla_url
date
2026-07-18T00:00:00.000Z

[PATCH] ld: testsuite: Associate C identifiers with the corresponding assembler or linker symbols in a target-independent manner.

Jan Dubiec’s patch addresses issues in the linker testsuite where target-specific symbol naming conventions (like a leading underscore for C identifiers) cause problems when linking C and assembly code or when symbols are provided on the linker command line. By using the asm keyword, C identifiers are associated with their assembler/linker symbols in a manner that is independent of the target architecture, resolving these cross-language and command-line symbol resolution problems.