Windows OSError: "exception: access violation reading 0x0000000000000000"

We are trying to convert a mxnet model into tvm (v7) in windows using the following part of code: loading model (works fine):

mx_sym, args, auxs = mx.model.load_checkpoint(root + ap.mdlrt, 0) mod, params = relay.frontend.from_mxnet(mx_sym, shape_dict, dtype, arg_params=args, aux_params=auxs)

build tvm model (fails):

with relay.build_config(opt_level=3): graph, mod, params = relay.build(mod, target, params=params)

in this relay.build we faced with the following error (full log):

[08:31:15] C:\Jenkins\workspace\mxnet-tag\mxnet\src\nnvm\legacy_json_util.cc:209: Loading symbol saved by previous version v1.2.0. Attempting to upgrade... [08:31:15] C:\Jenkins\workspace\mxnet-tag\mxnet\src\nnvm\legacy_json_util.cc:217: Symbol successfully upgraded! Traceback (most recent call last): File "E:/TVM/faceTransfer/mxnet2Tvm.py", line 96, in save_tvm_model graph, mod, params = relay.build(mod, target, params=params) File "C:\Python\Python37\site-packages\tvm-0.7.dev1-py3.7-win-amd64.egg\tvm\relay\build_module.py", line 251, in build graph_json, mod, params = bld_mod.build(mod, target, target_host, params) File "C:\Python\Python37\site-packages\tvm-0.7.dev1-py3.7-win-amd64.egg\tvm\relay\build_module.py", line 120, in build self._build(mod, target, target_host) File "C:\Python\Python37\site-packages\tvm-0.7.dev1-py3.7-win-amd64.egg\tvm\_ffi\_ctypes\packed_func.py", line 215, in __call__ ctypes.byref(ret_val), ctypes.byref(ret_tcode)) != 0: OSError: exception: access violation reading 0x0000000000000000

system details: Windows 10, Visual Studio-2015, c++14, cuda 10.1, llvm 6.0.1, tvm v7. Please let me know if any further info is required. -Thank you.

I have not personally seen this. I use Windows 10, VS 2019, CUDA 10.1 and LLVM10.0.

I would be curious if this happens with any mxnet model, or if successful with other models. Also if there is any difference between a “cuda” target vs “llvm” target.

I have checked the model, it works in linux. The same problem with target “llvm”. I know this error is ambiguous, the problem happens inside this function (in C):

int TVMFuncCall(TVMFunctionHandle func, TVMValue* args, int* arg_type_codes, int num_args, TVMValue* ret_val, int* ret_type_code)

I use new TVM repo from git and VS 2019, problem is solved!!