binutils Newspaper
JULY 29, 2026
ld/testsuite Proposed

ld/testsuite: add support for remote testing in ld-cdtest

Patch adds remote execution capabilities to ld-cdtest, enabling tests on both native and cross-compiled targets.

This patch revises the ld-cdtest testsuite to support remote execution, allowing tests to run on both native and cross-compiled targets. Maciej Rozycki has reviewed the changes, confirming their correctness on powerpc64le-linux-gnu (native) and mips-linux-gnu (remote) cross targets. He identifies a minor nitpick regarding the use of ‘remote_load’ and output handling that needs to be addressed.

In the Thread 2 participants
  1. Clément Chigot <chigot@adacore.com> proposer

    Submits a patched version of the `ld-cdtest` testsuite that uses `remote_load` to enable remote test execution.

    “Gentle ping to Maciej.”
  2. Maciej W. Rozycki <macro@orcam.me.uk> reviewer

    Confirms the patch works correctly on native and remote targets but notes a minor issue with `remote_load` usage and output handling.

    “I can see this works correctly here with native `powerpc64le-linux-gnu' system as well as remote `mips-linux-gnu' cross target, enabling the tests in the latter case. I have looked through the change and it seems good to me except for one nit across two places; see below.”

Technical Tradeoffs

  • Enables broader test coverage by supporting remote execution.
  • Introduces a dependency on the `remote_load` functionality, which might require specific test environment setup.

In Details

The ld-cdtest is a Tcl-based test harness within the binutils ld/testsuite designed to verify the linker's behavior. This patch refactors the test execution logic to use remote_load, a Tcl command likely provided by the test infrastructure, to run the cdtest program on the target system (either native or remote). This enables testing cross-linker configurations more effectively and reliably, moving away from direct exec calls which could be fragile.

For Context
ld-cdtest
A test within the binutils linker testsuite (ld/testsuite) that likely tests specific linker features or command-line options related to code distribution or compilation drivers.
remote_load
A Tcl command, presumably part of the binutils testing framework, used to load and execute a program on a remote target system.
cross-compiled target
A target system for which code is compiled on a different host system and architecture. For example, compiling code for an ARM processor on an x86-based Linux machine.
Filed Under: binutilslinkertestsuiteremote testingcross-compilation