CMakeLists.txt 2 KB
Newer Older
1
include_directories(BEFORE
Adam Osewski's avatar
Adam Osewski committed
2
    ${PROJECT_SOURCE_DIR}/
3
    ${PROJECT_SOURCE_DIR}/profiler/include
4
5
)

JD's avatar
JD committed
6
7
include(googletest)

8
9
add_custom_target(tests)

Chao Liu's avatar
Chao Liu committed
10
11
function(add_test_executable TEST_NAME)
    message("adding test ${TEST_NAME}")
12
    add_executable(${TEST_NAME} ${ARGN})
13
    add_test(NAME ${TEST_NAME} COMMAND $<TARGET_FILE:${TEST_NAME}>)
14
15
    add_dependencies(tests ${TEST_NAME})
    add_dependencies(check ${TEST_NAME})
16
    rocm_install(TARGETS ${TEST_NAME} COMPONENT tests)
Chao Liu's avatar
Chao Liu committed
17
endfunction(add_test_executable TEST_NAME)
18

19
20
21
22
23
24
25
include(GoogleTest)

function(add_gtest_executable TEST_NAME)
    message("adding gtest ${TEST_NAME}")
    add_executable(${TEST_NAME} ${ARGN})
    add_dependencies(tests ${TEST_NAME})
    add_dependencies(check ${TEST_NAME})
26

27
    # suppress gtest warnings
Adam Osewski's avatar
Adam Osewski committed
28
    target_compile_options(${TEST_NAME} PRIVATE -Wno-global-constructors -Wno-undef)
29
    target_link_libraries(${TEST_NAME} PRIVATE gtest_main)
30
    add_test(NAME ${TEST_NAME} COMMAND $<TARGET_FILE:${TEST_NAME}>)
31
    rocm_install(TARGETS ${TEST_NAME} COMPONENT tests)
32
33
endfunction(add_gtest_executable TEST_NAME)

Chao Liu's avatar
Chao Liu committed
34
35
36
37
38
add_subdirectory(magic_number_division)
add_subdirectory(space_filling_curve)
add_subdirectory(conv_util)
add_subdirectory(reference_conv_fwd)
add_subdirectory(gemm)
39
add_subdirectory(gemm_layernorm)
Chao Liu's avatar
Chao Liu committed
40
add_subdirectory(gemm_split_k)
Chao Liu's avatar
Chao Liu committed
41
42
add_subdirectory(gemm_reduce)
add_subdirectory(batched_gemm)
43
add_subdirectory(batched_gemm_reduce)
Anthony Chang's avatar
Anthony Chang committed
44
add_subdirectory(batched_gemm_gemm)
Anthony Chang's avatar
Anthony Chang committed
45
add_subdirectory(batched_gemm_softmax_gemm)
46
add_subdirectory(batched_gemm_softmax_gemm_permute)
Chao Liu's avatar
Chao Liu committed
47
add_subdirectory(grouped_gemm)
48
add_subdirectory(reduce)
49
add_subdirectory(convnd_fwd)
JD's avatar
JD committed
50
add_subdirectory(convnd_bwd_data)
51
add_subdirectory(grouped_convnd_fwd)
52
add_subdirectory(grouped_convnd_bwd_weight)
53
add_subdirectory(block_to_ctile_map)
54
add_subdirectory(softmax)
55
add_subdirectory(normalization)
Adam Osewski's avatar
Adam Osewski committed
56
add_subdirectory(data_type)
57
add_subdirectory(elementwise_normalization)
58
add_subdirectory(batchnorm)
59
add_subdirectory(contraction)
60
61
62
if(GPU_TARGETS MATCHES "gfx1100")
    add_subdirectory(wmma_op)
endif()