v_cvt_f32_i32 GPU Native ISA AMD Vector
Vector Arithmetic
Per-lane conversion from signed 32-bit integer to single-precision float.
Encoding
The ENC_VOP1 layout from AMD's machine-readable ISA specification (AMD CDNA 5). Opcode 5 in OP rebuilds 0x7E000A00, an identifier AMD lists for this encoding. Bits marked unassigned have no field in the specification. Not the same in every generation: AMD CDNA 4 (field layout), AMD CDNA 3 (field layout), AMD CDNA 2 (field layout), AMD CDNA 1 (field layout), AMD RDNA 3.5 (field layout), AMD RDNA 3 (field layout), AMD RDNA 2 (field layout), AMD RDNA 1 (field layout). The same in AMD RDNA 4.
Operands
-
VDST
Destination VGPR -
S0
Source VGPR (i32)
GFX Target Compatibility
| Target | Support |
|---|---|
| gfx942 | ✅ Supported |
| gfx1100 | ✅ Supported |
Related PTX Concepts
Related
More in Vector Arithmetic
Reference
Description
Semantics
Example
v_cvt_f32_i32 v1, v0 // per-lane v1 = (float) v0Original illustrative example, written for this site (not reproduced from a specific AMD document).
Sources
- AMD Machine-Readable GPU ISA Specification ↗ - Advanced Micro Devices, Inc.