CMakeLists.txt 794 字节
Newer Older
J
jianghaicheng 已提交
1
IF(WITH_IPU)
2
  FILE(GLOB POPART_CANONICALIZATION_SRC ${PADDLE_SOURCE_DIR}/paddle/fluid/platform/device/ipu/popart_canonicalization/*.cc)
A
Allen Guo 已提交
3 4 5 6 7 8 9 10 11 12 13 14 15
  list(APPEND PADDLE_IPU_SRC ${POPART_CANONICALIZATION_SRC})
  set(PADDLE_IPU_LIB "${CMAKE_CURRENT_BINARY_DIR}/libpaddle_ipu.so" CACHE STRING "")
  set(PADDLE_IPU_LIB_DIR "${CMAKE_CURRENT_BINARY_DIR}" CACHE STRING "")
  set(IPU_BACKEND_SRC
    "ipu_device.cc"
    "ipu_strategy.cc"
    "ipu_executor.cc"
    "ipu_compiler.cc"
    "ipu_backend.cc"
    "ipu_utils.cc"
  )

  cc_library(ipu_backend SRCS ${IPU_BACKEND_SRC} DEPS popart graph framework_proto enforce graph_helper timer)
J
jianghaicheng 已提交
16
  cc_library(ipu_info SRCS ipu_info.cc DEPS ipu_backend)
A
Allen Guo 已提交
17 18
  cc_library(paddle_ipu SHARED SRCS ${PADDLE_IPU_SRC} DEPS popart)
  add_dependencies(paddle_ipu ipu_backend)
J
jianghaicheng 已提交
19
ENDIF()