code: def test_cuda_vectorize_load_permute_pad():
      def check_cuda(dtype, n, l, padding, lanes):
          if dtype == "float16" and not have_fp16(
              tvm.cuda(0).compute_version
          ):
              print("Skip because gpu does not have fp16 support")
              return
  
          dev = tvm.cuda(0)
          A = tvm.te.placeholder((n, l), name="A", dtype=dtype)
          B = tvm.te.compute(
              (n // lanes, l + 2 * padding, lanes),
              lambda i, j, k: tvm.te.if_then_else(
                  tvm.te.any(j < padding, j >= l + padding),
                  tvm.runtime.convert(0).astype(dtype),
                  A[i * lanes + k, j - padding],
              ),
              name="B",
          )
          s = te.create_schedule(B.op)
          block, thread, vectorize = s[B].op.axis
          s[B].bind(block, bx)
          s[B].bind(thread, tx)
          s[B].vectorize(vectorize)
          fun = tvm.build(
              s, [A, B], "cuda", name="vector_load_permute_pad"
          )
          np_a = np.random.randint(
              low=-128, high=127, size=(n, l)
          ).astype(A.dtype)
          a = tvm.nd.empty((n, l), A.dtype, dev).copyfrom(np_a)
          b = tvm.nd.empty(
              (n // lanes, l + padding * 2, lanes), B.dtype, dev
          )
          fun(a, b)
          np_a_reshape = np_a.reshape(n // lanes, lanes, l).transpose(
              0, 2, 1
          )
          ref = np.pad(
              np_a_reshape,
              ((0, 0), (padding, padding), (0, 0)),
              mode="constant",
              constant_values=0,
          )
          tvm.testing.assert_allclose(b.numpy(), ref)
  
      check_cuda("int8", 64, 16, 3, 2)
      check_cuda("uint8", 64, 16, 3, 2)
      check_cuda("int8", 64, 16, 3, 4)
      check_cuda("uint8", 64, 16, 3, 4)
      check_cuda("int32", 64, 16, 3, 4)
      check_cuda("float16", 64, 16, 3, 4)
      check_cuda("float32", 64, 16, 3, 4)
  
imports: import os
  import re
  import tvm
  from tvm import te
  import numpy
  from tvm import topi
  from tvm.contrib.nvcc import have_fp16, have_int8, have_bf16
  from tvm.contrib import utils
  from tvm.script import tir
  import tvm.testing
  import pytest
label_desc: Use image node_id 23 for calling a global function with example usage: test_cuda_vectorize_load_permute_pad() without return types