Vector Arithmetic Instructions
558 AMDGPU instructions in this category - showing 100 per page, page 4 of 6 - click any row for encoding, pseudocode, and full documentation.
| Mnemonic | Syntax | Format | Summary |
|---|---|---|---|
| v_interp_p1ll_f16 | v_interp_p1ll_f16 | VOP3 | Given a single-precision float I coordinate in a vector register and an attribute specifier, load two half-precision float parameter values from the… |
| v_interp_p1lv_f16 | v_interp_p1lv_f16 | VOP3 | Given a single-precision float I coordinate in a vector register, a half-precision float P0 value in another vector register, and an attribute… |
| v_interp_p2_f16 | v_interp_p2_f16 | VOP3 | Given a single-precision float J coordinate in a vector register, an attribute specifier and the result of a prior V_INTERP_P1_F32 in another vector… |
| v_interp_p2_f16_opsel | v_interp_p2_f16_opsel | VOP3 | AMDGPU VOP3 vector instruction operating on f16 data. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_interp_p2_legacy_f16 | v_interp_p2_legacy_f16 | VOP3 | Half-precision interpolation. |
| v_ldexp_f16 | v_ldexp_f16 | VOP2 | Multiply the first input, a floating point value, by an integral power of 2 specified in the second input, a signed integer value, and store the… |
| v_ldexp_f16_fake16 | v_ldexp_f16_fake16 | VOP2 | AMDGPU VOP2 vector instruction operating on f16 data. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_ldexp_f16_t16 | v_ldexp_f16_t16 | VOP2 | AMDGPU VOP2 vector instruction operating on f16 data. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_ldexp_f32 | v_ldexp_f32 | VOP2 | Multiply the first input, a floating point value, by an integral power of 2 specified in the second input, a signed integer value, and store the… |
| v_ldexp_f64 | v_ldexp_f64 | VOP3 | Multiply the first input, a floating point value, by an integral power of 2 specified in the second input, a signed integer value, and store the… |
| v_lerp_u8 | v_lerp_u8 | VOP3 | Average two 4-D vectors stored as packed bytes in the first two inputs with rounding control provided by the third input, then store the result into… |
| v_log_bf16 | v_log_bf16 | VOP1 | AMDGPU VOP1 vector instruction. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_log_f16 | v_log_f16 | VOP1 | Calculate the base 2 logarithm of the half-precision float input and store the result into a vector register. |
| v_log_f32 | v_log_f32 | VOP1 | Calculate the base 2 logarithm of the single-precision float input and store the result into a vector register. |
| v_log_legacy_f32 | v_log_legacy_f32 | VOP1 | AMDGPU VOP1 vector instruction operating on f32 data. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_lshl_add_u32 | v_lshl_add_u32 | VOP3 | Given a shift count in the second input, calculate the logical shift left of the first input, then add the third input to the intermediate result… |
| v_lshl_add_u64 | v_lshl_add_u64 | VOP3 | Given a shift count in the second input, calculate the logical shift left of the first input, then add the third input to the intermediate result… |
| v_lshl_b32 | v_lshl_b32 | VOP2 | AMDGPU VOP2 vector instruction operating on b32 data. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_lshl_b64 | v_lshl_b64 | VOP3 | AMDGPU VOP3 vector instruction operating on b64 data. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_lshl_or_b32 | v_lshl_or_b32 | VOP3 | Given a shift count in the second input, calculate the logical shift left of the first input, then calculate the bitwise OR of the intermediate… |
| v_lshlrev_b16 | v_lshlrev_b16 | VOP2 | Given a shift count in the first vector input, calculate the logical shift left of the second vector input and store the result into a vector… |
| v_lshlrev_b32 | v_lshlrev_b32 | VOP2 | Given a shift count in the first vector input, calculate the logical shift left of the second vector input and store the result into a vector… |
| v_lshlrev_b64 | v_lshlrev_b64 | VOP2 | Given a shift count in the first vector input, calculate the logical shift left of the second vector input and store the result into a vector… |
| v_lshlrev_b64_pseudo | v_lshlrev_b64_pseudo | VOP2 | AMDGPU VOP2 vector instruction operating on b64 data. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_lshr_b32 | v_lshr_b32 | VOP2 | AMDGPU VOP2 vector instruction operating on b32 data. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_lshr_b64 | v_lshr_b64 | VOP3 | AMDGPU VOP3 vector instruction operating on b64 data. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_lshrrev_b16 | v_lshrrev_b16 | VOP2 | Given a shift count in the first vector input, calculate the logical shift right of the second vector input and store the result into a vector… |
| v_lshrrev_b32 | v_lshrrev_b32 | VOP2 | Given a shift count in the first vector input, calculate the logical shift right of the second vector input and store the result into a vector… |
| v_lshrrev_b64 | v_lshrrev_b64 | VOP3 | Given a shift count in the first vector input, calculate the logical shift right of the second vector input and store the result into a vector… |
| v_mac_f16 | v_mac_f16 | VOP2 | Multiply two floating point inputs and accumulate the result into the destination register. Implements IEEE rules and non-standard rule for OPSEL. |
| v_mac_f32 | v_mac_f32 | VOP2 | Multiply two floating point inputs and accumulate the result into the destination register. |
| v_mac_legacy_f32 | v_mac_legacy_f32 | VOP2 | Multiply and add single-precision values, accumulate with destination. Follows DX9 rules where 0.0 times anything produces 0.0. |
| v_mad_co_i64_i32 | v_mad_co_i64_i32 | VOP3 | Multiply two signed integer inputs, add a third signed integer input, store the result into a 64-bit vector register and store the overflow/carryout… |
| v_mad_co_u64_u32 | v_mad_co_u64_u32 | VOP3 | Multiply two unsigned integer inputs, add a third unsigned integer input, store the result into a 64-bit vector register and store the… |
| v_mad_f16 | v_mad_f16 | VOP3 | Multiply two half-precision float inputs and add a third input, and store the result into a vector register. |
| v_mad_f16_gfx9 | v_mad_f16_gfx9 | VOP3 | AMDGPU VOP3 vector instruction operating on f16 data. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_mad_f32 | v_mad_f32 | VOP3 | Multiply two single-precision float inputs and add a third input, and store the result into a vector register. |
| v_mad_i16 | v_mad_i16 | VOP3 | Multiply two signed 16-bit integer inputs, add a signed 16-bit integer value from a third input, and store the result into a vector register. |
| v_mad_i16_gfx9 | v_mad_i16_gfx9 | VOP3 | AMDGPU VOP3 vector instruction operating on i16 data. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_mad_i32_i16 | v_mad_i32_i16 | VOP3 | Multiply two signed 16-bit integer inputs in the signed 32-bit integer domain, add a signed 32-bit integer value from a third input, and store the… |
| v_mad_i32_i24 | v_mad_i32_i24 | VOP3 | Multiply two signed 24-bit integer inputs in the signed 32-bit integer domain, add a signed 32-bit integer value from a third input, and store the… |
| v_mad_i64_i32 | v_mad_i64_i32 | VOP3 | Multiply two signed integer inputs, add a third signed integer input, store the result into a 64-bit vector register and store the overflow/carryout… |
| v_mad_legacy_f16 | v_mad_legacy_f16 | VOP3 | Multiply add of FP16 values. Implements IEEE rules and non-standard rule for OPSEL. |
| v_mad_legacy_f32 | v_mad_legacy_f32 | VOP3 | Multiply and add single-precision values. Follows DX9 rules where 0.0 times anything produces 0.0. |
| v_mad_legacy_i16 | v_mad_legacy_i16 | VOP3 | Multiply add of signed short values. Has non-standard rule for OPSEL. |
| v_mad_legacy_u16 | v_mad_legacy_u16 | VOP3 | Multiply add of unsigned short values. Has non-standard rule for OPSEL. |
| v_mad_nc_i64_i32 | v_mad_nc_i64_i32 | VOP3 | AMDGPU VOP3 vector instruction operating on i32/i64 data. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_mad_nc_u64_u32 | v_mad_nc_u64_u32 | VOP3 | AMDGPU VOP3 vector instruction operating on u32/u64 data. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_mad_u16 | v_mad_u16 | VOP3 | Multiply two unsigned 16-bit integer inputs, add an unsigned 16-bit integer value from a third input, and store the result into a vector register. |
| v_mad_u16_gfx9 | v_mad_u16_gfx9 | VOP3 | AMDGPU VOP3 vector instruction operating on u16 data. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_mad_u32 | v_mad_u32 | VOP3 | AMDGPU VOP3 vector instruction operating on u32 data. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_mad_u32_u16 | v_mad_u32_u16 | VOP3 | Multiply two unsigned 16-bit integer inputs in the unsigned 32-bit integer domain, add an unsigned 32-bit integer value from a third input, and store… |
| v_mad_u32_u24 | v_mad_u32_u24 | VOP3 | Multiply two unsigned 24-bit integer inputs in the unsigned 32-bit integer domain, add a unsigned 32-bit integer value from a third input, and store… |
| v_mad_u64_u32 | v_mad_u64_u32 | VOP3 | Multiply two unsigned integer inputs, add a third unsigned integer input, store the result into a 64-bit vector register and store the… |
| v_madak_f16 | v_madak_f16 | VOP2 | Multiply two floating point inputs and add a literal constant, and store the result into a vector register. Implements IEEE rules. |
| v_madak_f32 | v_madak_f32 | VOP2 | Multiply two floating point inputs and add a literal constant, and store the result into a vector register. |
| v_madmk_f16 | v_madmk_f16 | VOP2 | Multiply a floating point input with a literal constant and add a second floating point input, and store the result into a vector register. |
| v_madmk_f32 | v_madmk_f32 | VOP2 | Multiply a floating point input with a literal constant and add a second floating point input, and store the result into a vector register. |
| v_max3_f16 | v_max3_f16 | VOP3 | Select the maximum of three half-precision float inputs and store the selected value into a vector register. |
| v_max3_f32 | v_max3_f32 | VOP3 | Select the maximum of three single-precision float inputs and store the selected value into a vector register. |
| v_max3_i16 | v_max3_i16 | VOP3 | Select the maximum of three signed 16-bit integer inputs and store the selected value into a vector register. |
| v_max3_i32 | v_max3_i32 | VOP3 | Select the maximum of three signed 32-bit integer inputs and store the selected value into a vector register. |
| v_max3_num_f16 | v_max3_num_f16 | VOP3 | Select the IEEE maximumNumber() of three half-precision float inputs and store the selected value into a vector register. |
| v_max3_num_f32 | v_max3_num_f32 | VOP3 | Select the IEEE maximumNumber() of three single-precision float inputs and store the selected value into a vector register. |
| v_max3_u16 | v_max3_u16 | VOP3 | Select the maximum of three unsigned 16-bit integer inputs and store the selected value into a vector register. |
| v_max3_u32 | v_max3_u32 | VOP3 | Select the maximum of three unsigned 32-bit integer inputs and store the selected value into a vector register. |
| v_max_bf16 | v_max_bf16 | VOP3 | AMDGPU VOP3 vector instruction. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_max_f16 | v_max_f16 | VOP2 | Select the maximum of two half-precision float inputs and store the result into a vector register. |
| v_max_f32 | v_max_f32 | VOP2 | Select the maximum of two single-precision float inputs and store the result into a vector register. |
| v_max_f64 | v_max_f64 | VOP2 | Select the maximum of two double-precision float inputs and store the selected value into a vector register. |
| v_max_i16 | v_max_i16 | VOP2 | Select the maximum of two signed 16-bit integer inputs and store the selected value into a vector register. |
| v_max_i32 | v_max_i32 | VOP2 | Select the maximum of two signed 32-bit integer inputs and store the selected value into a vector register. |
| v_max_i64 | v_max_i64 | VOP3 | AMDGPU VOP3 vector instruction operating on i64 data. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_max_legacy_f32 | v_max_legacy_f32 | VOP2 | AMDGPU VOP2 vector instruction operating on f32 data. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_max_num_f16 | v_max_num_f16 | VOP2 | Select the IEEE maximumNumber() of two half-precision float inputs and store the selected value into a vector register. |
| v_max_num_f32 | v_max_num_f32 | VOP2 | Select the IEEE maximumNumber() of two single-precision float inputs and store the selected value into a vector register. |
| v_max_num_f64 | v_max_num_f64 | VOP2 | Select the IEEE maximumNumber() of two double-precision float inputs and store the selected value into a vector register. |
| v_max_u16 | v_max_u16 | VOP2 | Select the maximum of two unsigned 16-bit integer inputs and store the selected value into a vector register. |
| v_max_u32 | v_max_u32 | VOP2 | Select the maximum of two unsigned 32-bit integer inputs and store the selected value into a vector register. |
| v_max_u64 | v_max_u64 | VOP3 | AMDGPU VOP3 vector instruction operating on u64 data. (Format and name extracted from LLVM's AMDGPU backend source - semantics not yet curated.) |
| v_maximum3_f16 | v_maximum3_f16 | VOP3 | Select the IEEE maximum() of three half-precision float inputs and store the selected value into a vector register. |
| v_maximum3_f32 | v_maximum3_f32 | VOP3 | Select the IEEE maximum() of three single-precision float inputs and store the result into a vector register. |
| v_maximum_f16 | v_maximum_f16 | VOP3 | Select the IEEE maximum() of two half-precision float inputs and store the selected value into a vector register. |
| v_maximum_f32 | v_maximum_f32 | VOP3 | Select the IEEE maximum() of two single-precision float inputs and store the selected value into a vector register. |
| v_maximum_f64 | v_maximum_f64 | VOP3 | Select the IEEE maximum() of two double-precision float inputs and store the selected value into a vector register. |
| v_maximumminimum_f16 | v_maximumminimum_f16 | VOP3 | Select the IEEE maximum() of the first two half-precision float inputs and then select the IEEE minimum() of that result and third half-precision… |
| v_maximumminimum_f32 | v_maximumminimum_f32 | VOP3 | Select the IEEE maximum() of the first two single-precision float inputs and then select the IEEE minimum() of that result and third single-precision… |
| v_maxmin_f16 | v_maxmin_f16 | VOP3 | Select the maximum of the first two half-precision float inputs and then select the minimum of that result and third half-precision float input. |
| v_maxmin_f32 | v_maxmin_f32 | VOP3 | Select the maximum of the first two single-precision float inputs and then select the minimum of that result and third single-precision float input. |
| v_maxmin_i32 | v_maxmin_i32 | VOP3 | Select the maximum of the first two signed 32-bit integer inputs and then select the minimum of that result and third signed 32-bit integer input. |
| v_maxmin_num_f16 | v_maxmin_num_f16 | VOP3 | Select the IEEE maximumNumber() of the first two half-precision float inputs and then select the IEEE minimumNumber() of that result and third… |
| v_maxmin_num_f32 | v_maxmin_num_f32 | VOP3 | Select the IEEE maximumNumber() of the first two single-precision float inputs and then select the IEEE minimumNumber() of that result and third… |
| v_maxmin_u32 | v_maxmin_u32 | VOP3 | Select the maximum of the first two unsigned 32-bit integer inputs and then select the minimum of that result and third unsigned 32-bit integer input. |
| v_mbcnt_hi_u32_b32 | v_mbcnt_hi_u32_b32 | VOP2 | For each lane 32 <= N < 64, examine the N least significant bits of the first input and count how many of those bits are "1". |
| v_mbcnt_lo_u32_b32 | v_mbcnt_lo_u32_b32 | VOP2 | For each lane 0 <= N < 32, examine the N least significant bits of the first input and count how many of those bits are "1". |
| v_med3_f16 | v_med3_f16 | VOP3 | Select the median of three half-precision float values and store the selected value into a vector register. |
| v_med3_f32 | v_med3_f32 | VOP3 | Select the median of three single-precision float values and store the selected value into a vector register. |
| v_med3_i16 | v_med3_i16 | VOP3 | Select the median of three signed 16-bit integer values and store the selected value into a vector register. |
| v_med3_i32 | v_med3_i32 | VOP3 | Select the median of three signed 32-bit integer values and store the selected value into a vector register. |
| v_med3_num_f16 | v_med3_num_f16 | VOP3 | Select the median of three half-precision float inputs and store the selected value into a vector register. |