Landing: e5ca6a0963a9
Project / Subsystem
gcc / gcc/risc-v
Date
2026-02-28
Author
Bohan Lei
Commit
e5ca6a0963a9000e0deb1274ef5e3e699d5b85d0
Source
github
Perf win
No
Breaking
No
All attributes
- project
- gcc
- subsystem
- gcc/risc-v
- patch_id
- —
- commit_hash
- e5ca6a0963a9000e0deb1274ef5e3e699d5b85d0
- source_type
- github
- headline
- RISC-V: Specify -mcpu When --with-cpu Is Used
- tldr
- The compiler now consistently uses `-mcpu` instead of `-march` when the `--with-cpu` option is used for RISC-V, aligning its behavior with explicit `-mcpu` usa…
- author
- Bohan Lei
- outcome
- committed
- performance_win
- false
- breaking_change
- false
- series_id
- —
- series_parts
- []
- tags
-
- • risc-v
- • configuration
- discussion_id_link
- —
- bugzilla_pr
- —
- date
- 2026-02-28T00:00:00.000Z
This commit addresses an inconsistency in how the --with-cpu option is handled for RISC-V architectures. Previously, it specified only the -march option, which defines the instruction set architecture. This commit changes the behavior to specify -mcpu instead, which encompasses both -march (architecture) and -mtune (tuning for a specific processor), ensuring that --with-cpu acts consistently with an explicit -mcpu option. This change provides a more complete and expected configuration for users.