Skip to content

Commit 70cd375

Browse files
committed
Corrected statement about zero-extension in docs.
1 parent ed559b3 commit 70cd375

File tree

1 file changed

+1
-1
lines changed
  • src/doc/unstable-book/src/library-features

1 file changed

+1
-1
lines changed

src/doc/unstable-book/src/library-features/asm.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -510,7 +510,7 @@ Each register class has constraints on which value types they can be used with.
510510

511511
> **Note**: For the purposes of the above table pointers, function pointers and `isize`/`usize` are treated as the equivalent integer type (`i16`/`i32`/`i64` depending on the target).
512512
513-
If a value is of a smaller size than the register it is allocated in then the upper bits of that register will have an undefined value for inputs and will be ignored for outputs. The only exceptions are the `freg` register class on RISC-V where `f32` values are NaN-boxed in a `f64` as required by the RISC-V architecture, and the register classes on NVPTX where values are zero-extended.
513+
If a value is of a smaller size than the register it is allocated in then the upper bits of that register will have an undefined value for inputs and will be ignored for outputs. The only exception is the `freg` register class on RISC-V where `f32` values are NaN-boxed in a `f64` as required by the RISC-V architecture.
514514

515515
When separate input and output expressions are specified for an `inout` operand, both expressions must have the same type. The only exception is if both operands are pointers or integers, in which case they are only required to have the same size. This restriction exists because the register allocators in LLVM and GCC sometimes cannot handle tied operands with different types.
516516

0 commit comments

Comments
 (0)