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

Can't compile cpptest #7555

Closed
avt77 opened this issue Mar 1, 2021 · 2 comments
Closed

Can't compile cpptest #7555

avt77 opened this issue Mar 1, 2021 · 2 comments

Comments

@avt77
Copy link

avt77 commented Mar 1, 2021

When I try to "make cpptest" I see the error message:

[ 93%] Linking CXX executable container_test
CMakeFiles/container_test.dir/tests/cpp/container_test.cc.o: In function InplaceArrayBase_BadExceptionSafety_Test::TestBody()': /hdd/_tvm/tvm/tests/cpp/container_test.cc:123: undefined reference to testing::internal::DeathTest::Create(char const*, testing::Matcher<std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&>, char const*, int, testing::internal::DeathTest**)'
CMakeFiles/container_test.dir/tests/cpp/container_test.cc.o: In function InplaceArrayBase_ExceptionSafety_Test::TestBody()': /hdd/_tvm/tvm/tests/cpp/container_test.cc:143: undefined reference to testing::internal::DeathTest::Create(char const*, testing::Matcher<std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&>, char const*, int, testing::internal::DeathTest**)'
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[3]: *** [CMakeFiles/container_test.dir/build.make:86: container_test] Error 1
make[2]: *** [CMakeFiles/Makefile2:631: CMakeFiles/container_test.dir/all] Error 2
make[1]: *** [CMakeFiles/Makefile2:933: CMakeFiles/cpptest.dir/rule] Error 2
make: *** [Makefile:541: cpptest] Error 2

How to fix this issue? All other tests are being compiled without any problems.
And there are other problems: I'm getting several compiled tests but when I try to run them I see "Program received signal SIGSEGV, Segmentation fault." like here:

(gdb) r
The program being debugged has been started already.
Start it from the beginning? (y or n) y
Starting program: /hdd/_tvm/tvm/build/tir_analysis_side_effect
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[==========] Running 1 test from 1 test case.
[----------] Global test environment set-up.
[----------] 1 test from SimplePasses

Program received signal SIGSEGV, Segmentation fault.
0x0000000000000000 in ?? ()
(gdb) bt
#0 0x0000000000000000 in ?? ()
#1 0x00007ffff409a5c3 in testing::TestCase::RunSetUpTestCase() () from /usr/local/lib/libgtest.so
#2 0x00007ffff40b1c3e in void testing::internal::HandleSehExceptionsInMethodIfSupported<testing::TestCase, void>(testing::TestCase*, void (testing::TestCase::)(), char const) ()
from /usr/local/lib/libgtest.so
#3 0x00007ffff409a38b in void testing::internal::HandleExceptionsInMethodIfSupported<testing::TestCase, void>(testing::TestCase*, void (testing::TestCase::)(), char const) ()
from /usr/local/lib/libgtest.so
#4 0x00007ffff408141e in testing::TestCase::Run() () from /usr/local/lib/libgtest.so
#5 0x00007ffff4088c41 in testing::internal::UnitTestImpl::RunAllTests() () from /usr/local/lib/libgtest.so
#6 0x00007ffff40b390e in bool testing::internal::HandleSehExceptionsInMethodIfSupported<testing::internal::UnitTestImpl, bool>(testing::internal::UnitTestImpl*, bool (testing::internal::UnitTestImpl::)(), char const) () from /usr/local/lib/libgtest.so
#7 0x00007ffff409b9ab in bool testing::internal::HandleExceptionsInMethodIfSupported<testing::internal::UnitTestImpl, bool>(testing::internal::UnitTestImpl*, bool (testing::internal::UnitTestImpl::)(), char const) () from /usr/local/lib/libgtest.so
#8 0x00007ffff4088913 in testing::UnitTest::Run() () from /usr/local/lib/libgtest.so
#9 0x0000000000409861 in RUN_ALL_TESTS () at /usr/local/include/gtest/gtest.h:2471
#10 0x0000000000408a62 in main (argc=1, argv=0x7fffffffe028) at /hdd/_tvm/tvm/tests/cpp/tir_analysis_side_effect.cc:40

Obviously there are some problems with google tests env but what are the problems?

@hogepodge
Copy link
Contributor

Thanks for reaching out about this issue. The TVM community is happy to help out with questions like this, but they are typically handled through the Discuss community. Can you repost the issue there? It will get more visibility and discussion there. https://discuss.tvm.apache.org

@tqchen
Copy link
Member

tqchen commented Mar 3, 2021

Thanks for asking, #5185 might be related, please move to the forum for further conversations

@tqchen tqchen closed this as completed Mar 3, 2021
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