code: def test_call_packed_without_string_arg():
      """The first argument to tvm_call_packed must be a string
  
      Even if the invalid TIR is constructed, this should throw an
      exception to exit cleanly.  Previously, use of
      `args[0].as<StringImmNode>()` without a null check resulted in
      a segfault during codegen.
      """
  
      @T.prim_func
      def func(A: T.Buffer(1, "float32")):
          T.func_attr({"global_symbol": "func"})
          T.Call(
              "int32", tvm.ir.Op.get("tir.tvm_call_packed"), [A.data]
          )
  
      with pytest.raises(tvm.TVMError):
          built = tvm.build(func, target="llvm")
  
imports: import collections
  import ctypes
  import json
  import math
  import numpy
  import pytest
  import re
  import sys
  import tvm
  import tvm.testing
  from tvm import te
  from tvm.contrib import clang, utils
  from tvm.relay.backend import Runtime
  from tvm.script import tir, ir
  from tvm.target.codegen import llvm_get_intrinsic_name, llvm_lookup_intrinsic_id
label_desc: Use image node_id 40 for calling a global function with example usage: test_call_packed_without_string_arg() without return types