Skip to main content
Log in

Mojo function

tc_reduce_gevm_4x

tc_reduce_gevm_4x[out_type: DType, in_type: DType, simd_width: Int](val1: SIMD[in_type, simd_width]) -> SIMD[out_type, simd_width]

Performs a 4x GEVM reduction using tensor cores.

Note: Currently only supports bfloat16 input to float32 output conversion. Uses tensor core matrix multiply-accumulate (MMA) operations for reduction.

Parameters:

  • out_type (DType): The output data type for the reduction result (must be float32).
  • in_type (DType): The input data type of the vector to reduce (must be bfloat16).
  • simd_width (Int): The width of the SIMD vector.

Args:

  • val1 (SIMD[in_type, simd_width]): Input SIMD vector to reduce.

Returns:

SIMD vector containing the reduced result.