Skip to content

Commit

Permalink
Rename __riscv_v_max_eew/__riscv_v_max_eew_fp to __riscv_v_elen/__ris…
Browse files Browse the repository at this point in the history
…cv_v_elen_fp
  • Loading branch information
kito-cheng committed Jan 16, 2022
1 parent e2a9803 commit 2b59115
Showing 1 changed file with 16 additions and 16 deletions.
32 changes: 16 additions & 16 deletions riscv-c-api.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ https://creativecommons.org/licenses/by/4.0/.
| __riscv_flen | <ul><li>32 if the F extension is available **or**</li><li>64 if `D` extension available **or**</li><li>128 if `Q` extension available</li></ul> | `F` extension is available. |
| __riscv_32e | 1 | `E` extension is available. |
| __riscv_v_min_vlen | <N> (see [__riscv_v_min_vlen](#__riscv_v_min_vlen)) | The `V` extension or one of the `Zve*` extensions is available. |
| __riscv_v_max_eew | <N> (see [__riscv_v_max_eew](#__riscv_v_max_eew)) | The `V` extension or one of the `Zve*` extensions is available. |
| __riscv_v_max_eew_fp | <N> (see [__riscv_v_max_eew_fp](#__riscv_v_max_eew_fp)) | The `V` extension or one of the `Zve*` extensions is available. |
| __riscv_v_elen | <N> (see [__riscv_v_elen](#__riscv_v_elen)) | The `V` extension or one of the `Zve*` extensions is available. |
| __riscv_v_elen_fp | <N> (see [__riscv_v_elen_fp](#__riscv_v_elen_fp)) | The `V` extension or one of the `Zve*` extensions is available. |

### __riscv_v_min_vlen

Expand All @@ -65,33 +65,33 @@ Examples:
- `__riscv_v_min_vlen` is 256 for `rv32gcv_zvl32b_zvl256b`
- `__riscv_v_min_vlen` is 128 for `rv64gcv_zvl32b`

### __riscv_v_max_eew
### __riscv_v_elen

The `__riscv_v_max_eew` macro expands to the maximum EEW (effective element
width), in bits, of any non-floating-point vector operand of any vector
instruction in the available vector extension, if any. (Stricter upper bounds
may apply to particular operands of particular instructions.)
The `__riscv_v_elen` macro expands to the supported element length, in bits,
of any non-floating-point vector operand of any vector instruction in the
available vector extension, if any. (Stricter upper bounds may apply to
particular operands of particular instructions.)


The value of `__riscv_v_max_eew` is defined by the following rules:
The value of `__riscv_v_elen` is defined by the following rules:
- 64, if the `V` extension or one of the `Zve64{x,f,d}` extensions is present; and
- 32, if one of the `Zve32{x,f}` extensions is present.
If multiple rules apply, the maximum value is taken.
If none of the rules apply, `__riscv_v_max_eew` is undefined.
If none of the rules apply, `__riscv_v_elen` is undefined.

### __riscv_v_max_eew_fp
### __riscv_v_elen_fp

The `__riscv_v_max_eew_fp` macro expands to the maximum EEW (effective element
width), in bits, of any floating-point vector operand of any vector instruction
in the available vector extension, if any. (Stricter upper bounds may apply to
particular operands of particular instructions.)
The `__riscv_v_elen_fp` macro expands to the supported element length, in bits,
of any floating-point vector operand of any vector instruction in the available
vector extension, if any. (Stricter upper bounds may apply to particular
operands of particular instructions.)

The value of `__riscv_v_max_eew_fp` is defined by the following rules:
The value of `__riscv_v_elen_fp` is defined by the following rules:
- 64, if one of the `V` or `Zve64d` extensions is present;
- 32, if one of the `Zve{32,64}f` extensions is present; and
- 0, if one of the `Zve{32,64}x` extensions is present.
If multiple rules apply, the maximum value is taken.
If none of the rules apply, `__riscv_v_max_eew_fp` is undefined.
If none of the rules apply, `__riscv_v_elen_fp` is undefined.

### Architecture Extension Test Macro

Expand Down

0 comments on commit 2b59115

Please sign in to comment.