CMakeLists.txt 1.4 KB
Newer Older
1 2 3 4
if(NOT WIN32)
  cc_test(
    standalone_executor_new_ir_test
    SRCS standalone_executor_new_ir_test.cc
5
    DEPS phi_kernel_adaptor pd_dialect ir)
6 7
endif()

8
# skip win32 since wget is not installed by default on windows machine.
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32

set(OPS
    fill_constant_op
    uniform_random_op
    lookup_table_op
    transpose_op
    reshape_op
    split_op
    slice_op
    concat_op
    matmul_op
    elementwise_add_op
    elementwise_mul_op
    softmax_with_cross_entropy_op
    reduce_mean_op
    activation_op
    sum_op
    elementwise_div_op
    generated_op
    generated_static_op
    squared_l2_norm_op
    memcpy_h2d_op
    memcpy_d2h_op
    fetch_v2_op)
33 34 35 36 37 38 39 40 41 42 43 44 45 46
if(WITH_GPU
   AND WITH_TESTING
   AND NOT WIN32)
  add_custom_target(
    download_program
    COMMAND wget -nc --no-check-certificate
            https://paddle-ci.gz.bcebos.com/new_exec/lm_main_program
    COMMAND wget -nc --no-check-certificate
            https://paddle-ci.gz.bcebos.com/new_exec/lm_startup_program
    WORKING_DIRECTORY "${CC_TESTS_DIR}")

  # all operators used in the program

  # All deps of the operators above, part of GLOB_OPERATOR_DEPS.
47
  set(OP_DEPS phi concat_and_split cross_entropy)
48 49 50 51 52 53 54 55
  cc_test(standalone_executor_test SRCS standalone_executor_test.cc)

  # add_dependencies(standalone_executor_test download_program)
  # if(WITH_PROFILER)
  #   target_link_libraries(standalone_executor_test profiler)
  #   add_dependencies(standalone_executor_test profiler)
  # endif()
endif()