class_docstr: Base module test class.
class_docstr_tok: ["Base","module","test","class","."]
code: def main(
      p0_buffer: T.Buffer((1, 1, 230, 230, 4), "uint8"),
      p1_buffer: T.Buffer((2, 1, 7, 7, 1, 32, 4), "int8"),
      t_cast: T.Buffer((1, 2, 112, 112, 32), "int32"),
  ) -> None:
      # pylint: disable=missing-function-docstring
      # function attr dict
      T.func_attr({"tir.noalias": True, "global_symbol": "main"})
      # buffer definition
      # body
      # with T.block("root")
      conv2d_nchwc_int8 = T.alloc_buffer(
          [1, 2, 112, 112, 32], dtype="int32"
      )
      for i0_0_i1_0_i2_0_i3_0_fused in T.parallel(
          112,
          annotations={
              "pragma_auto_unroll_max_step": 64,
              "pragma_unroll_explicit": 1,
          },
      ):
          for i4_0_0 in T.serial(1):  # pylint: disable=unused-variable
              for (
                  i1_1_init,
                  i2_1_init,
                  i3_1_init,
                  i1_2_init,
                  i2_2_init,
                  i3_2_init,
              ) in T.grid(2, 1, 1, 1, 14, 8):
                  with T.block("conv2d_NCHWc_int8_o_init"):
                      n = T.axis.spatial(1, 0)
                      oc_chunk = T.axis.spatial(
                          2, i1_1_init + i1_2_init
                      )
                      o_height = T.axis.spatial(
                          112,
                          i0_0_i1_0_i2_0_i3_0_fused // 14 * 14
                          + i2_1_init * 14
                          + i2_2_init,
                      )
                      o_width = T.axis.spatial(
                          112,
                          i0_0_i1_0_i2_0_i3_0_fused % 14 * 8
                          + i3_1_init * 8
                          + i3_2_init,
                      )
                      oc_block_o = T.axis.spatial(
                          1, 0
                      )  # pylint: disable=unused-variable
                      T.reads()
                      T.writes(
                          conv2d_nchwc_int8[
                              n, oc_chunk, o_height, o_width, 0:32
                          ]
                      )
                      for i4_1 in T.vectorized(32):
                          with T.block("conv2d_NCHWc_int8_init"):
                              oc_block_i_init = T.axis.spatial(32, i4_1)
                              T.reads()
                              T.writes(
                                  conv2d_nchwc_int8[
                                      n,
                                      oc_chunk,
                                      o_height,
                                      o_width,
                                      oc_block_i_init,
                                  ]
                              )
                              conv2d_nchwc_int8[
                                  n,
                                  oc_chunk,
                                  o_height,
                                  o_width,
                                  oc_block_i_init,
                              ] = 0
              for (
                  i5_0,
                  i6_0,
                  i7_0,
                  i8_0,
                  i9_0_0,
              ) in T.grid(  # pylint: disable=unused-variable
                  1, 1, 1, 1, 1
              ):  # pylint: disable=unused-variable
                  for (
                      i0_1,  # pylint: disable=unused-variable
                      i1_1,
                      i2_1,
                      i3_1,
                      i4_0_1,  # pylint: disable=unused-variable
                      i5_1,
                      i6_1,
                      i7_1,  # pylint: disable=unused-variable
                      i8_1,  # pylint: disable=unused-variable
                      i9_0_1,  # pylint: disable=unused-variable
                      i0_2,  # pylint: disable=unused-variable
                      i1_2,
                      i2_2,
                      i3_2,
                      i4_0_2,  # pylint: disable=unused-variable
                  ) in T.grid(
                      1, 2, 1, 1, 1, 7, 7, 1, 1, 1, 1, 1, 14, 8, 1
                  ):
                      with T.block("conv2d_NCHWc_int8_o_update"):
                          n = T.axis.spatial(1, 0)
                          oc_chunk = T.axis.spatial(2, i1_1 + i1_2)
                          o_height = T.axis.spatial(
                              112,
                              i0_0_i1_0_i2_0_i3_0_fused // 14 * 14
                              + i2_1 * 14
                              + i2_2,
                          )
                          o_width = T.axis.spatial(
                              112,
                              i0_0_i1_0_i2_0_i3_0_fused % 14 * 8
                              + i3_1 * 8
                              + i3_2,
                          )
                          oc_block_o = T.axis.spatial(
                              1, 0
                          )  # pylint: disable=unused-variable
                          k_height = T.axis.reduce(7, i5_0 * 7 + i5_1)
                          k_width = T.axis.reduce(7, i6_0 * 7 + i6_1)
                          ic_outer = T.axis.reduce(1, 0)
                          ic_f_inner = T.axis.reduce(1, 0)
                          ic_s_inner_o = T.axis.reduce(
                              1, 0
                          )  # pylint: disable=unused-variable
                          T.reads(
                              conv2d_nchwc_int8[
                                  n, oc_chunk, o_height, o_width, 0:32
                              ],
                              p0_buffer[
                                  n,
                                  ic_outer,
                                  o_height * 2 + k_height,
                                  o_width * 2 + k_width,
                                  ic_f_inner * 4 : ic_f_inner * 4 + 4,
                              ],
                              p1_buffer[
                                  oc_chunk,
                                  ic_outer,
                                  k_height,
                                  k_width,
                                  ic_f_inner,
                                  0:32,
                                  0:4,
                              ],
                          )
                          T.writes(
                              conv2d_nchwc_int8[
                                  n, oc_chunk, o_height, o_width, 0:32
                              ]
                          )
                          a_buffer = T.match_buffer(
                              p0_buffer[
                                  n,
                                  ic_outer,
                                  o_height * 2 + k_height,
                                  o_width * 2 + k_width,
                                  ic_f_inner * 4 : ic_f_inner * 4 + 4,
                              ],
                              [4],
                              dtype="uint8",
                              offset_factor=1,
                          )
                          b_buffer = T.match_buffer(
                              p1_buffer[
                                  oc_chunk,
                                  ic_outer,
                                  k_height,
                                  k_width,
                                  ic_f_inner,
                                  0:32,
                                  0:4,
                              ],
                              [32, 4],
                              dtype="int8",
                              offset_factor=1,
                          )
                          c_buffer = T.match_buffer(
                              conv2d_nchwc_int8[
                                  n, oc_chunk, o_height, o_width, 0:32
                              ],
                              [32],
                              dtype="int32",
                              offset_factor=1,
                          )
                          a_u8x4: T.uint8x4 = a_buffer[0:4]
                          a_i32: T.int32 = T.reinterpret(
                              a_u8x4, dtype="int32"
                          )
                          b_i8x128 = b_buffer[0, 0:128]
                          b_i32x32: T.int32x32 = T.reinterpret(
                              b_i8x128, dtype="int32x32"
                          )
                          c_buffer[0:32] = T.call_llvm_pure_intrin(
                              T.llvm_lookup_intrinsic_id(
                                  "llvm.hexagon.V6.vrmpyubv.acc.128B"
                              ),
                              T.uint32(3),
                              c_buffer[0:32],
                              T.broadcast(a_i32, 32),
                              b_i32x32,
                              dtype="int32x32",
                          )
                  for ax0, ax1, ax2, ax3 in T.grid(1, 2, 14, 8):
                      for ax4_fused in T.vectorized(32):
                          with T.block("T_cast_2"):
                              ax0_1, ax1_1 = T.axis.remap(
                                  "SS", [ax0, ax1]
                              )
                              ax2_1 = T.axis.spatial(
                                  112,
                                  i0_0_i1_0_i2_0_i3_0_fused // 14 * 14
                                  + ax2,
                              )
                              ax3_1 = T.axis.spatial(
                                  112,
                                  i0_0_i1_0_i2_0_i3_0_fused % 14 * 8
                                  + ax3,
                              )
                              ax4 = T.axis.spatial(32, ax4_fused)
                              T.reads(
                                  conv2d_nchwc_int8[
                                      ax0_1, ax1_1, ax2_1, ax3_1, ax4
                                  ]
                              )
                              T.writes(
                                  t_cast[
                                      ax0_1, ax1_1, ax2_1, ax3_1, ax4
                                  ]
                              )
                              t_cast[
                                  ax0_1, ax1_1, ax2_1, ax3_1, ax4
                              ] = conv2d_nchwc_int8[
                                  ax0_1, ax1_1, ax2_1, ax3_1, ax4
                              ]
  
file_path: tvm/tests/python/contrib/test_hexagon/test_async_dma_pipeline.py
imports: import numpy
  import pytest
  import tvm
  from tvm.script import tir
label_desc: Use image node_id 1 for calling the ModuleBase obj's underlying member method code with example usage: obj.main(p0_buffer, p1_buffer, t_cast) without return types