Skip to content

Conversation

@manupak
Copy link
Contributor

@manupak manupak commented Dec 1, 2021

If the build does not use USE_ETHOSU ON,
it will report that Object definitions are missing.
This change will keep the file that has the Object
definitions.

If the build does not use USE_ETHOSU ON,
it will report that Object definitions are missing.
This change will keep the file that has the Object
definitions.

Change-Id: I64776f941bf0475e10397ff2cdbfd73a909611a0
@manupak
Copy link
Contributor Author

manupak commented Dec 1, 2021

cc : @gromero @leandron

@gromero
Copy link
Contributor

gromero commented Dec 2, 2021

@manupa-arm Thanks for fixing it. LGTM. I have no idea why CI didn't catch it. afaics it should ...

For the records, the trace for the issue fixed here is:

gromero@amd:~/git/tvm$ tvmc 
Traceback (most recent call last):
  File "/usr/lib/python3.9/runpy.py", line 188, in _run_module_as_main
    mod_name, mod_spec, code = _get_module_details(mod_name, _Error)
  File "/usr/lib/python3.9/runpy.py", line 147, in _get_module_details
    return _get_module_details(pkg_main_name, error)
  File "/usr/lib/python3.9/runpy.py", line 111, in _get_module_details
    __import__(pkg_name)
  File "/home/gromero/git/tvm/python/tvm/driver/tvmc/__init__.py", line 24, in <module>
    from . import autotuner
  File "/home/gromero/git/tvm/python/tvm/driver/tvmc/autotuner.py", line 37, in <module>
    from . import common, composite_target, frontends
  File "/home/gromero/git/tvm/python/tvm/driver/tvmc/composite_target.py", line 29, in <module>
    from tvm.relay.op.contrib.ethosu import partition_for_ethosu
  File "/home/gromero/git/tvm/python/tvm/relay/op/contrib/ethosu.py", line 39, in <module>
    from tvm.relay.backend.contrib.ethosu import preprocess
  File "/home/gromero/git/tvm/python/tvm/relay/backend/contrib/ethosu/__init__.py", line 18, in <module>
    from . import util
  File "/home/gromero/git/tvm/python/tvm/relay/backend/contrib/ethosu/util.py", line 218, in <module>
    class CompilationArtifact(Object):
  File "/home/gromero/git/tvm/python/tvm/_ffi/registry.py", line 69, in register
    check_call(_LIB.TVMObjectTypeKey2Index(c_str(object_name), ctypes.byref(tidx)))
  File "/home/gromero/git/tvm/python/tvm/_ffi/base.py", line 348, in check_call
    raise get_last_ffi_error()
tvm._ffi.base.TVMError: Traceback (most recent call last):
  183: 0xffffffffffffffff
  182: _start
  181: __libc_start_main
  180: Py_BytesMain
  179: Py_RunMain
  178: 0x00000000006142ef
  177: _PyFunction_Vectorcall
  176: 0x0000000000514a74
  175: _PyEval_EvalFrameDefault
  174: _PyFunction_Vectorcall
  173: 0x0000000000514a74
  172: _PyEval_EvalFrameDefault
  171: _PyFunction_Vectorcall
  170: 0x0000000000514a74
  169: _PyEval_EvalFrameDefault
  168: _PyObject_MakeTpCall
  167: 0x000000000054350b
  166: 0x0000000000555be7
  165: PyImport_ImportModuleLevelObject
  164: _PyObject_CallMethodIdObjArgs
  163: 0x000000000052ca22
  162: _PyFunction_Vectorcall
  161: _PyEval_EvalFrameDefault
  160: _PyFunction_Vectorcall
  159: _PyEval_EvalFrameDefault
  158: _PyFunction_Vectorcall
  157: _PyEval_EvalFrameDefault
  156: _PyFunction_Vectorcall
  155: _PyEval_EvalFrameDefault
  154: _PyFunction_Vectorcall
  153: 0x0000000000514a74
  152: _PyEval_EvalFrameDefault
  151: 0x000000000052de87
  150: 0x00000000005ffe83
  149: PyEval_EvalCode
  148: _PyEval_EvalCodeWithName
  147: 0x0000000000514a74
  146: _PyEval_EvalFrameDefault
  145: PyImport_ImportModuleLevelObject
  144: _PyObject_CallMethodIdObjArgs
  143: 0x000000000052ca22
  142: _PyFunction_Vectorcall
  141: 0x0000000000515376
  140: _PyEval_EvalFrameDefault
  139: _PyFunction_Vectorcall
  138: 0x0000000000514a74
  137: _PyEval_EvalFrameDefault
  136: PyObject_Call
  135: 0x000000000054350b
  134: 0x0000000000555be7
  133: PyImport_ImportModuleLevelObject
  132: _PyObject_CallMethodIdObjArgs
  131: 0x000000000052ca22
  130: _PyFunction_Vectorcall
  129: _PyEval_EvalFrameDefault
  128: _PyFunction_Vectorcall
  127: _PyEval_EvalFrameDefault
  126: _PyFunction_Vectorcall
  125: _PyEval_EvalFrameDefault
  124: _PyFunction_Vectorcall
  123: _PyEval_EvalFrameDefault
  122: _PyFunction_Vectorcall
  121: 0x0000000000514a74
  120: _PyEval_EvalFrameDefault
  119: 0x000000000052de87
  118: 0x00000000005ffe83
  117: PyEval_EvalCode
  116: _PyEval_EvalCodeWithName
  115: 0x0000000000514a74
  114: _PyEval_EvalFrameDefault
  113: PyImport_ImportModuleLevelObject
  112: _PyObject_CallMethodIdObjArgs
  111: 0x000000000052ca22
  110: _PyFunction_Vectorcall
  109: 0x0000000000515376
  108: _PyEval_EvalFrameDefault
  107: _PyFunction_Vectorcall
  106: 0x0000000000514a74
  105: _PyEval_EvalFrameDefault
  104: PyObject_Call
  103: 0x000000000054350b
  102: 0x0000000000555be7
  101: PyImport_ImportModuleLevelObject
  100: _PyObject_CallMethodIdObjArgs
  99: 0x000000000052ca22
  98: _PyFunction_Vectorcall
  97: _PyEval_EvalFrameDefault
  96: _PyFunction_Vectorcall
  95: _PyEval_EvalFrameDefault
  94: _PyFunction_Vectorcall
  93: _PyEval_EvalFrameDefault
  92: _PyFunction_Vectorcall
  91: _PyEval_EvalFrameDefault
  90: _PyFunction_Vectorcall
  89: 0x0000000000514a74
  88: _PyEval_EvalFrameDefault
  87: 0x000000000052de87
  86: 0x00000000005ffe83
  85: PyEval_EvalCode
  84: _PyEval_EvalCodeWithName
  83: 0x0000000000514a74
  82: _PyEval_EvalFrameDefault
  81: PyImport_ImportModuleLevelObject
  80: _PyObject_CallMethodIdObjArgs
  79: 0x000000000052ca22
  78: _PyFunction_Vectorcall
  77: _PyEval_EvalFrameDefault
  76: _PyFunction_Vectorcall
  75: _PyEval_EvalFrameDefault
  74: _PyFunction_Vectorcall
  73: _PyEval_EvalFrameDefault
  72: _PyFunction_Vectorcall
  71: _PyEval_EvalFrameDefault
  70: _PyFunction_Vectorcall
  69: 0x0000000000514a74
  68: _PyEval_EvalFrameDefault
  67: 0x000000000052de87
  66: 0x00000000005ffe83
  65: PyEval_EvalCode
  64: _PyEval_EvalCodeWithName
  63: 0x0000000000514a74
  62: _PyEval_EvalFrameDefault
  61: PyImport_ImportModuleLevelObject
  60: _PyObject_CallMethodIdObjArgs
  59: 0x000000000052ca22
  58: _PyFunction_Vectorcall
  57: _PyEval_EvalFrameDefault
  56: _PyFunction_Vectorcall
  55: _PyEval_EvalFrameDefault
  54: _PyFunction_Vectorcall
  53: _PyEval_EvalFrameDefault
  52: _PyFunction_Vectorcall
  51: _PyEval_EvalFrameDefault
  50: _PyFunction_Vectorcall
  49: 0x0000000000514a74
  48: _PyEval_EvalFrameDefault
  47: 0x000000000052de87
  46: 0x00000000005ffe83
  45: PyEval_EvalCode
  44: _PyEval_EvalCodeWithName
  43: 0x0000000000514a74
  42: _PyEval_EvalFrameDefault
  41: PyImport_ImportModuleLevelObject
  40: _PyObject_CallMethodIdObjArgs
  39: 0x000000000052ca22
  38: _PyFunction_Vectorcall
  37: 0x0000000000515376
  36: _PyEval_EvalFrameDefault
  35: _PyFunction_Vectorcall
  34: 0x0000000000514a74
  33: _PyEval_EvalFrameDefault
  32: PyObject_Call
  31: 0x000000000054350b
  30: 0x0000000000555be7
  29: PyImport_ImportModuleLevelObject
  28: _PyObject_CallMethodIdObjArgs
  27: 0x000000000052ca22
  26: _PyFunction_Vectorcall
  25: _PyEval_EvalFrameDefault
  24: _PyFunction_Vectorcall
  23: _PyEval_EvalFrameDefault
  22: _PyFunction_Vectorcall
  21: _PyEval_EvalFrameDefault
  20: _PyFunction_Vectorcall
  19: _PyEval_EvalFrameDefault
  18: _PyFunction_Vectorcall
  17: 0x0000000000514a74
  16: _PyEval_EvalFrameDefault
  15: 0x000000000052de87
  14: 0x00000000005ffe83
  13: PyEval_EvalCode
  12: _PyEval_EvalCodeWithName
  11: 0x0000000000514a74
  10: _PyEval_EvalFrameDefault
  9: _PyFunction_Vectorcall
  8: 0x0000000000514a74
  7: _PyEval_EvalFrameDefault
  6: _PyObject_MakeTpCall
  5: 0x00007faf615bc30c
  4: 0x00007faf615c6368
  3: 0x00007faf61314638
  2: 0x00007faf61315248
  1: TVMObjectTypeKey2Index
  0: tvm::runtime::Object::TypeKey2Index(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)
  File "/home/gromero/git/tvm/src/runtime/object.cc", line 159
TVMError: 
---------------------------------------------------------------
An error occurred during the execution of TVM.
For more information, please see: https://tvm.apache.org/docs/errors.html
---------------------------------------------------------------
  Check failed: (it != type_key2index_.end()) is false: Cannot find type relay.ext.ethos-u.CompilationArtifact. Did you forget to register the node by TVM_REGISTER_NODE_TYPE ?

@jroesch jroesch merged commit 5014b74 into apache:main Dec 2, 2021
ylc pushed a commit to ylc/tvm that referenced this pull request Jan 7, 2022
If the build does not use USE_ETHOSU ON,
it will report that Object definitions are missing.
This change will keep the file that has the Object
definitions.

Change-Id: I64776f941bf0475e10397ff2cdbfd73a909611a0
yangulei pushed a commit to yangulei/tvm that referenced this pull request Jan 11, 2022
If the build does not use USE_ETHOSU ON,
it will report that Object definitions are missing.
This change will keep the file that has the Object
definitions.

Change-Id: I64776f941bf0475e10397ff2cdbfd73a909611a0
yangulei pushed a commit to yangulei/tvm that referenced this pull request Jan 12, 2022
If the build does not use USE_ETHOSU ON,
it will report that Object definitions are missing.
This change will keep the file that has the Object
definitions.

Change-Id: I64776f941bf0475e10397ff2cdbfd73a909611a0
ylc pushed a commit to ylc/tvm that referenced this pull request Jan 13, 2022
If the build does not use USE_ETHOSU ON,
it will report that Object definitions are missing.
This change will keep the file that has the Object
definitions.

Change-Id: I64776f941bf0475e10397ff2cdbfd73a909611a0
qsqqsqqsq-intellif pushed a commit to qsqqsqqsq-intellif/tvm that referenced this pull request Apr 29, 2022
If the build does not use USE_ETHOSU ON,
it will report that Object definitions are missing.
This change will keep the file that has the Object
definitions.

Change-Id: I64776f941bf0475e10397ff2cdbfd73a909611a0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants