Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tvm/apps/bundle_deploy/build --> make failed #5709

Closed
aGiant opened this issue Jun 1, 2020 · 4 comments
Closed

tvm/apps/bundle_deploy/build --> make failed #5709

aGiant opened this issue Jun 1, 2020 · 4 comments
Assignees

Comments

@aGiant
Copy link

aGiant commented Jun 1, 2020

  • Ubuntu 18.04 LTS
  • LLVM installed according to https://apt.llvm.org/
  • tvm was successfully compiled and worked well using python 3.7 with MXNet.
  • tvm 0.7 dev

But for this example under tvm/apps/bundle_deploy/build, dynamic and static libs, described in offical web site, did not work at all. Tried many times but always the same error:

In file included from runtime.c:61:0:
../../src/runtime/crt/crt_backend_api.c: In function ‘TVMBackendRegisterSystemLibSymbol’:
../../src/runtime/crt/crt_backend_api.c:49:3: error: ‘g_fexecs’ undeclared (first use in this function)
g_fexecs = vrealloc(g_fexecs, sizeof(TVMPackedFunc) * (g_fexecs_count + 1));
^~~~~~~~
../../src/runtime/crt/crt_backend_api.c:49:3: note: each undeclared identifier is reported only once for each function it appears in
../../src/runtime/crt/crt_backend_api.c:49:40: error: ‘TVMPackedFunc’ undeclared (first use in this function); did you mean ‘TVMPackedCFunc’?
g_fexecs = vrealloc(g_fexecs, sizeof(TVMPackedFunc) * (g_fexecs_count + 1));
^~~~~~~~~~~~~
TVMPackedCFunc
../../src/runtime/crt/crt_backend_api.c:49:58: error: ‘g_fexecs_count’ undeclared (first use in this function); did you mean ‘g_fexecs’?
g_fexecs = vrealloc(g_fexecs, sizeof(TVMPackedFunc) * (g_fexecs_count + 1));
^~~~~~~~~~~~~~
g_fexecs
Makefile:87: recipe for target 'build/bundle_c.so' failed
make: *** [build/bundle_c.so] Error 1

@tqchen
Copy link
Member

tqchen commented Jun 1, 2020

cc @liangfu

@tqchen
Copy link
Member

tqchen commented Jun 2, 2020

#5713

@tqchen tqchen closed this as completed Jun 2, 2020
@aGiant
Copy link
Author

aGiant commented Jun 5, 2020

@tqchen
it worked on Intel CPU Ubuntu 18.04 LTS
Now, we tried for arm cpu under armbian got error:

compiled with tvm.target.arm_cpu('pynq') in build_model.py

gcc -shared -Wall -std=c99 -O2 -fPIC -I/home/pi/incubator-tvm/include -I/home/pi/incubator-tvm/3rdparty/dmlc-core/include -I/home/pi/incubator-tvm/3rdparty/dlpack/include -fvisibility=hidden -o build/bundle_c.so bundle.c runtime.c build/model.o -pthread
TVM_NUM_THREADS=1 build/demo_dynamic build/bundle.so build/cat.bin
terminate called after throwing an instance of 'dmlc::Error'
what(): [20:29:01] ../../src/runtime/graph/graph_runtime.cc:377: Check failed: pf != nullptr: no such function in module: fused_layout_transform_22
Stack trace:
[bt] (0) build/bundle.so(+0xda16) [0xb6c19a16]
[bt] (1) build/bundle.so(tvm::runtime::GraphRuntime::CreateTVMOp(tvm::runtime::TVMOpParam const&, std::vector<DLTensor, std::allocator > const&, unsigned int)+0x42d) [0xb6c1e1d6]
[bt] (2) build/bundle.so(tvm::runtime::GraphRuntime::SetupOpExecs()+0x305) [0xb6c24a5e]
[bt] (3) build/bundle.so(tvm::runtime::GraphRuntime::Init(std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&, tvm::runtime::Module, std::vector<DLContext, std::allocator > const&)+0x13b) [0xb6c24d80]
[bt] (4) build/bundle.so(+0x18f26) [0xb6c24f26]
[bt] (5) build/bundle.so(+0x19088) [0xb6c25088]
[bt] (6) build/bundle.so(tvm_runtime_create+0x12f) [0xb6c17d4c]
[bt] (7) build/demo_dynamic(+0x994) [0x42f994]
[bt] (8) /lib/arm-linux-gnueabihf/libc.so.6(__libc_start_main+0x99) [0xb6d33fe6]

@tqchen
Copy link
Member

tqchen commented Jun 5, 2020

Please open a new thread on https://discuss.tvm.ai/ to followup

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

No branches or pull requests

3 participants