Skip to content

Commit

Permalink
Remove source files copied from TensorFlow
Browse files Browse the repository at this point in the history
The missing symbols are resolved by linking against _pywrap_tensorflow_internal.so,
which was introduced to Horovod with PR horovod#3053.

Signed-off-by: Max H. Gerlach <git@maxgerlach.de>
  • Loading branch information
maxhgerlach committed Aug 27, 2021
1 parent 7970416 commit 212b930
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 258 deletions.
22 changes: 0 additions & 22 deletions horovod/tensorflow/CMakeLists.txt
Expand Up @@ -61,28 +61,6 @@ set(Tensorflow_CXX11 ${Tensorflow_CXX11} PARENT_SCOPE)
list(APPEND TF_SOURCES "${PROJECT_SOURCE_DIR}/horovod/tensorflow/mpi_ops.cc")
list(APPEND TF_SOURCES "${PROJECT_SOURCE_DIR}/horovod/tensorflow/xla_mpi_ops.cc")

if(VERSION_DEC GREATER 2006000000 OR VERSION_DEC EQUAL 2006000000)
# dependencies for inplace broadcast with resource variables
list(APPEND TF_SOURCES "${PROJECT_SOURCE_DIR}/horovod/tensorflow/dense_update_functor.cc"
"${PROJECT_SOURCE_DIR}/horovod/tensorflow/training_op_helpers.cc")

if(HAVE_CUDA OR HAVE_SUB_PROJECT_CUDA)
list(APPEND TF_CUDA_SOURCES "${PROJECT_SOURCE_DIR}/horovod/tensorflow/dense_update_functor_gpu.cc.cu")
# dense_update_functor_gpu.cu.cc from TensorFlow source had to be renamed because it was not compiled via nvcc otherwise

set(CUDA_HOST_COMPILER ${CMAKE_CXX_COMPILER})

set(ENV{PYTHONPATH} "${PROJECT_SOURCE_DIR}/cmake:$ENV{PYTHONPATH}")
execute_process(COMMAND ${PY_EXE} -c "import build_utils; print(' '.join(build_utils.get_nvcc_flags()))"
OUTPUT_VARIABLE HVD_NVCC_COMPILE_FLAGS OUTPUT_STRIP_TRAILING_WHITESPACE)

list(APPEND CUDA_NVCC_FLAGS "${HVD_NVCC_COMPILE_FLAGS}")

cuda_add_library(tensorflow_cuda_kernels ${TF_CUDA_SOURCES} STATIC OPTIONS -DGOOGLE_CUDA=1)
list(APPEND TF_LINKER_LIBS tensorflow_cuda_kernels)
endif()
endif()

# Create library
set_output_dir()
add_library(${TF_TARGET_LIB} SHARED ${SOURCES} ${TF_SOURCES})
Expand Down
128 changes: 0 additions & 128 deletions horovod/tensorflow/dense_update_functor.cc

This file was deleted.

78 changes: 0 additions & 78 deletions horovod/tensorflow/dense_update_functor_gpu.cc.cu

This file was deleted.

30 changes: 0 additions & 30 deletions horovod/tensorflow/training_op_helpers.cc

This file was deleted.

0 comments on commit 212b930

Please sign in to comment.