mirror of
https://github.com/rust-lang/rust.git
synced 2025-10-02 10:18:25 +00:00

rustc_codegen_ssa: More comprehensive RISC-V ELF flags This change implements more conformant, more comprehensive RISC-V ELF flags handling when generating certain object files directly from rustc. * Use `"zca"` instead of `"c"` The "Zca" extension (a subset of "C") is the minimal configuration for compressed instructions to set `EF_RISCV_RVC` flag. * Set TSO flag from `"ztso"` The "Ztso" extension denotes that the program depends on the RVTSO (Total Store Ordering) memory consistency model, which is stronger than the standard RVWMO (Weak Memory Ordering) consistency model and on ELF targets, we need to set `EF_RISCV_TSO` flag.