Skip to content

Commit

Permalink
backed out external ops changes
Browse files Browse the repository at this point in the history
  • Loading branch information
Ubuntu committed Aug 26, 2020
1 parent df85c38 commit bc80960
Show file tree
Hide file tree
Showing 8 changed files with 4 additions and 286 deletions.
13 changes: 4 additions & 9 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -483,9 +483,9 @@ FILE(GLOB_RECURSE NNVMSOURCE
3rdparty/tvm/nnvm/src/core/*.h
3rdparty/tvm/nnvm/src/pass/*.h
3rdparty/tvm/nnvm/include/*.h)
add_library(nnvm SHARED ${NNVMSOURCE})
add_library(nnvm OBJECT ${NNVMSOURCE})
set_target_properties(nnvm PROPERTIES CXX_CLANG_TIDY "") # don't lint 3rdparty dependency
#list(APPEND SOURCE $<TARGET_OBJECTS:nnvm>)
list(APPEND SOURCE $<TARGET_OBJECTS:nnvm>)

# add source group
FILE(GLOB_RECURSE GROUP_SOURCE "src/*.cc" "3rdparty/tvm/nnvm/*.cc" "plugin/*.cc")
Expand Down Expand Up @@ -696,8 +696,6 @@ elseif(MSVC)
add_library(mxnet SHARED ${SOURCE})
target_link_libraries(mxnet PUBLIC mshadow)
endif()
# export all symbols for external ops
set_target_properties(mxnet PROPERTIES WINDOWS_EXPORT_ALL_SYMBOLS TRUE)
endif()
target_compile_definitions(mxnet PUBLIC DMLC_LOG_FATAL_THROW=$<BOOL:${LOG_FATAL_THROW}>)

Expand All @@ -708,8 +706,6 @@ add_library(transposerowsp_lib SHARED ${CMAKE_CURRENT_SOURCE_DIR}/example/extens
add_library(subgraph_lib SHARED ${CMAKE_CURRENT_SOURCE_DIR}/example/extensions/lib_subgraph/subgraph_lib.cc ${CMAKE_CURRENT_SOURCE_DIR}/src/lib_api.cc)
add_library(pass_lib SHARED ${CMAKE_CURRENT_SOURCE_DIR}/example/extensions/lib_pass/pass_lib.cc ${CMAKE_CURRENT_SOURCE_DIR}/src/lib_api.cc)

add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/example/extensions/lib_external_ops ${CMAKE_CURRENT_SOURCE_DIR}/example/extensions/lib_external_ops/build)

target_include_directories(customop_lib PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/include/mxnet)
target_include_directories(transposecsr_lib PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/include/mxnet)
target_include_directories(transposerowsp_lib PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/include/mxnet)
Expand Down Expand Up @@ -791,13 +787,13 @@ if(MSVC)
if(USE_SPLIT_ARCH_DLL AND USE_CUDA)
foreach(arch ${arch_code_list})
target_link_libraries(mxnet_${arch} PUBLIC ${mxnet_LINKER_LIBS})
target_link_libraries(mxnet_${arch} PUBLIC dmlc nnvm)
target_link_libraries(mxnet_${arch} PUBLIC dmlc)
endforeach()
endif()
endif()

target_link_libraries(mxnet PUBLIC ${mxnet_LINKER_LIBS})
target_link_libraries(mxnet PUBLIC dmlc nnvm)
target_link_libraries(mxnet PUBLIC dmlc)

if(USE_OPENCV AND OpenCV_VERSION_MAJOR GREATER 2)
add_executable(im2rec "tools/im2rec.cc")
Expand All @@ -806,7 +802,6 @@ if(USE_OPENCV AND OpenCV_VERSION_MAJOR GREATER 2)
${OpenCV_LIBS}
mxnet
dmlc
nnvm
)
else()
message(WARNING "OpenCV_VERSION_MAJOR: ${OpenCV_VERSION_MAJOR}, version 3 with imgcodecs \
Expand Down
36 changes: 0 additions & 36 deletions example/extensions/lib_external_ops/CMakeLists.txt

This file was deleted.

38 changes: 0 additions & 38 deletions example/extensions/lib_external_ops/README.md

This file was deleted.

39 changes: 0 additions & 39 deletions example/extensions/lib_external_ops/init_lib.cc

This file was deleted.

60 changes: 0 additions & 60 deletions example/extensions/lib_external_ops/min_ex-inl.h

This file was deleted.

34 changes: 0 additions & 34 deletions example/extensions/lib_external_ops/min_ex.cc

This file was deleted.

29 changes: 0 additions & 29 deletions example/extensions/lib_external_ops/min_ex.cu

This file was deleted.

41 changes: 0 additions & 41 deletions example/extensions/lib_external_ops/test_loading.py

This file was deleted.

0 comments on commit bc80960

Please sign in to comment.