Advertisement
ananthm3

CMake Patch 1

Mar 16th, 2023
776
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
CMake 1.32 KB | None | 0 0
  1. set(HPVM_TEST_UTILS opt hpvm-rt-bc FileCheck count not)
  2.  
  3. configure_lit_site_cfg(
  4.   ../lit.site.cfg.py.in
  5.   ${CMAKE_CURRENT_BINARY_DIR}/hpvm_core_pass/lit.site.cfg.py
  6.   MAIN_CONFIG
  7.   ${CMAKE_CURRENT_SOURCE_DIR}/hpvm_core_pass/lit.cfg.py
  8. )
  9.  
  10. set(TEST_DEPS )
  11. list(APPEND TEST_DEPS ${HPVM_TEST_UTILS} HPVMGenHPVM HPVMBuildDFG HPVMLocalMem HPVMClearDFG
  12. HPVMDFG2LLVM_CPU HPVMDFGTransformPasses HPVMUnrollAndJam HPVMArgPriv
  13. HPVMBufferIn)
  14. if(${HPVM_USE_OPENCL} EQUAL 1)
  15.   list(APPEND TEST_DEPS  HPVMDFG2LLVM_GPU_OCL HPVMDFG2LLVM_FPG)
  16. endif()
  17.  
  18. add_lit_testsuite(check-hpvm-core-pass "Running test cases for the HPVM core passes"
  19.   ${CMAKE_CURRENT_BINARY_DIR}/hpvm_core_pass
  20.   DEPENDS ${TEST_DEPS}
  21. )
  22. add_custom_target(check-hpvm-pass DEPENDS check-hpvm-core-pass)
  23.  
  24. if(HPVM_USE_CUDA)
  25.   configure_lit_site_cfg(
  26.     ../lit.site.cfg.py.in
  27.     ${CMAKE_CURRENT_BINARY_DIR}/hpvm_tensor_pass/lit.site.cfg.py
  28.     MAIN_CONFIG
  29.     ${CMAKE_CURRENT_SOURCE_DIR}/hpvm_tensor_pass/lit.cfg.py
  30.   )
  31.   add_lit_testsuite(check-hpvm-tensor-pass "Running test cases for the HPVM tensor passes"
  32.     ${CMAKE_CURRENT_BINARY_DIR}/hpvm_tensor_pass
  33.     DEPENDS ${HPVM_TEST_UTILS}
  34.     HPVMDFG2LLVM_CUDNN HPVMDFG2LLVM_WrapperAPI
  35.     HPVMFuseHPVMTensorNodes HPVMInPlaceDFGAnalysis
  36.   )
  37.   add_dependencies(check-hpvm-pass check-hpvm-tensor-pass)
  38. endif()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement