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

Remove Incorrect Extension Registration of tvm::Target #1272

Merged
merged 1 commit into from
Jun 14, 2018

Conversation

kazum
Copy link
Contributor

@kazum kazum commented Jun 13, 2018

This PR fixes #1244 for CMake.

Here is an example configuration to produce the problem:

CMAKE_BUILD_TYPE=Debug
CMAKE_CXX_FLAGS_DEBUG="-g -O0"

@nishi-t
Copy link
Contributor

nishi-t commented Jun 13, 2018

@kazum this change causes a following error in osx:

ld: unknown option: -Bsymbolic-functions
clang: error: linker command failed with exit code 1 (use -v to see invocation)

@kazum
Copy link
Contributor Author

kazum commented Jun 13, 2018

@nishi-t Thanks for your comment. It looks like clang doesn't support -Bsymbolic-functions option.
I think the true fix is to use different symbols between libtvm.so and libtvm_topi.so, but it's need a quite lot of code change. For now, I'll add -Bsymbolic-functions only to GCC for a quick fix.

@kazum kazum force-pushed the bsymbolic-functions-for-cmake branch from 0419532 to 4c3e4a8 Compare June 13, 2018 06:03
@tqchen
Copy link
Member

tqchen commented Jun 13, 2018

Sorry I didn't take a closer look. This actually reveals a BUG that needs to be fixed. Specifically, tvm::Target is no longer an extension type, but a node type now, and we should remove the extension registeration here https://github.com/dmlc/tvm/blob/master/topi/src/topi.cc#L50

@tqchen tqchen changed the title Add -Bsymbolic-functions to linker option for cmake Remove Incorrect Extension Registration of tvm::Target Jun 13, 2018
@tqchen tqchen added the status: need update need update based on feedbacks label Jun 13, 2018
@kazum
Copy link
Contributor Author

kazum commented Jun 13, 2018

@tqchen Okay, I'll fix the problem based on your comment, thanks.

@kazum kazum force-pushed the bsymbolic-functions-for-cmake branch from 4c3e4a8 to 6d11057 Compare June 14, 2018 05:11
@tqchen tqchen merged commit 2f2f60f into apache:master Jun 14, 2018
@tqchen tqchen added status: accepted and removed status: need update need update based on feedbacks labels Jun 14, 2018
@tqchen
Copy link
Member

tqchen commented Jun 14, 2018

Thanks! this is merged

tqchen pushed a commit to tqchen/tvm that referenced this pull request Jul 6, 2018
mnuyens pushed a commit to mnuyens/tvm that referenced this pull request Jul 10, 2018
sergei-mironov pushed a commit to sergei-mironov/tvm that referenced this pull request Aug 8, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants