You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
> **Note**: On x86 we treat `reg_byte` differently from `reg` because the compiler can allocate `al` and `ah` separately whereas `reg` reserves the whole register.
475
478
>
476
479
> Note #2: On x86-64 the high byte registers (e.g. `ah`) are only available when used as an explicit register. Specifying the `reg_byte` register class for an operand will always allocate a low byte register.
480
+
>
481
+
> Note #3: On NVPTX, register names are not supported.
477
482
478
483
Additional register classes may be added in the future based on demand (e.g. MMX, x87, etc).
479
484
@@ -495,14 +500,17 @@ Each register class has constraints on which value types they can be used with.
495
500
| ARM |`sreg`|`vfp2`|`i32`, `f32`|
496
501
| ARM |`dreg`|`vfp2`|`i64`, `f64`, `i8x8`, `i16x4`, `i32x2`, `i64x1`, `f32x2`|
497
502
| ARM |`qreg`|`neon`|`i8x16`, `i16x8`, `i32x4`, `i64x2`, `f32x4`|
> **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).
504
512
505
-
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.
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.
506
514
507
515
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.
508
516
@@ -610,6 +618,9 @@ The supported modifiers are a subset of LLVM's (and GCC's) [asm template argumen
0 commit comments