Skip to content

Conversation

@pz9115
Copy link
Contributor

@pz9115 pz9115 commented Oct 25, 2024

This PR updates the default option of --with-arch from rv64imafdc to rv64gc. In newer gcc versions, gc is equivalent to imafdc_zicsr_zifencei, which provides CSR instructions reading from and writing to CSRs(Zicsr) and fence instruction ensuring memory consistency between code and data(Zifencei).

Most Linux distributions (such as Debian Arch, Gentoo for RISC-V) use the rv64gc architecture when building RISC-V user space and kernel to ensure that system-level applications have the necessary instruction support now.

And most RISC-V development boards now also set gc as their default supported arch.

@pz9115 pz9115 changed the title Set rv64gc as default --with-arch option. Set rv64gc the default for --with-arch option. Oct 25, 2024
@TommyMurphyTM1234
Copy link
Collaborator

Should it also be changed here, perhaps?

@pz9115
Copy link
Contributor Author

pz9115 commented Oct 25, 2024

Should it also be changed here, perhaps?

Thanks for the reminder, I think it needs a new PR, since the current one may not be accepted XD

@TommyMurphyTM1234
Copy link
Collaborator

Thanks for the reminder, I think it needs a new PR, since the current one may not be accepted XD

Why not?

@pz9115 pz9115 closed this Oct 25, 2024
@pz9115 pz9115 reopened this Oct 25, 2024
@kito-cheng
Copy link
Collaborator

LGTM, and I am OK with the separate PR for the multilib stuff updating, thanks Jiawei :)

@kito-cheng kito-cheng merged commit a4b355b into riscv-collab:master Nov 21, 2024
52 checks passed
@pz9115 pz9115 deleted the patch-1 branch May 9, 2025 06:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants