rust-lang / rust-lang/rust

Figure out which target features are required/incompatible for which ABI

Open
#131,799 27 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

A-ABI A-floating-point A-target-feature C-tracking-issue T-compiler
Dominant language
Rust
Stars
119k
Forks
16.1k
PR merge metrics
PR metrics pending

Description

View all comments

The context for this is https://github.com/rust-lang/rust/issues/116344: some target features change the way floats are passed between functions. Changing those target features is unsound as code compiled for the same target may now use different ABIs.

In https://github.com/rust-lang/rust/pull/134794, I am adding the infrastructure to have the compiler recognize this. But this infrastructure needs to be fed with information about which ABIs exist (e.g. softfloat/hardfloat), and which target features they require or are incompatible with. This will have to be done for each architecture we support.

Tier 3 only:

  • bpf
  • csky
  • hexagon
  • mips
  • m68k
  • sparc32
  • more?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with issue #116344 and the compiler infrastructure described in pull request #134794, then review the architecture-specific ABI notes and linked follow-up issues in this issue. Begin with the unchecked nvptx entry and determine which target features and ABI options are required or incompatible. Done means the supported architectures have their ABI requirements recorded and the remaining tier 3 targets are addressed or explicitly scoped.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
compilers
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
32/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.