Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarify implications for fcsr #288

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions riscv-cc.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,11 @@ calls if they are no larger than the width of a floating-point register in the
targeted ABI. Therefore, these registers can always be considered temporaries
if targeting the base integer calling convention.

The Floating-Point Control and Status Register (fcsr) must have thread storage
duration in accordance with C11 section 7.6 "Floating-point environment
<fenv.h>".
In contexts where accesses or modifications to the C floating-point environment
(`fenv`) are meaningful, like when the `FENV_ACCESS` pragma is "on", the state of
`fenv` is coherent with that of the RISC-V floating-point control and status
register (`fcsr`). In these contexts, `fcsr` can be thought of as having thread
storage duration.

=== Vector Register Convention

Expand Down