rust-lang / rust-lang/rust

Compiler does not recognize the reserve-r9 target feature

Open
#129,558 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

A-LLVM A-target-feature O-Arm T-compiler
Dominant language
Rust
Stars
119k
Forks
16.1k
PR merge metrics
PR metrics pending

Description

This issue is similar to this issue. On the armv7a-none-eabi target, specifying the reserve-r9 target feature using the flag -Ctarget-feature=+reserve-r9 results in the following warning:

warning: unknown and unstable feature specified for `-Ctarget-feature`: `reserve-r9`
  |
  = note: it is still passed through to the codegen backend, but use of this feature might be unsound and the behavior of this feature can change in the future
  = help: consider filing a feature request

The feature is currently working and is used by me and others too.

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

Reproduce the warning for armv7a-none-eabi with -Ctarget-feature=+reserve-r9, then inspect the compiler's target-feature handling for this target and the related issue #121970. Done means reserve-r9 is recognized without the unknown-and-unstable warning while remaining passed through correctly to the codegen backend.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
compilers
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.