CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
101 lines
4.1 KiB
CMake
101 lines
4.1 KiB
CMake
# Copyright © Advanced Micro Devices, Inc., or its affiliates.
|
|
# SPDX-License-Identifier: MIT
|
|
|
|
include(GoogleTest)
|
|
find_package(hip REQUIRED)
|
|
find_package(Threads REQUIRED)
|
|
|
|
# Main integration test executable WITH HipErrorHandler
|
|
add_executable(
|
|
hipdnn_public_backend_tests
|
|
main.cpp
|
|
IntegrationBackendDescriptor.cpp
|
|
IntegrationBackendExecuteApi.cpp
|
|
IntegrationConvOperationDescriptorApi.cpp
|
|
IntegrationGraphDescriptorApi.cpp
|
|
IntegrationEngineApi.cpp
|
|
IntegrationEngineConfigApi.cpp
|
|
IntegrationEngineHeuristicApi.cpp
|
|
IntegrationExecutionPlanApi.cpp
|
|
IntegrationGetLastErrorString.cpp
|
|
IntegrationHandleApi.cpp
|
|
IntegrationKnobsApi.cpp
|
|
IntegrationLoggingPipeline.cpp
|
|
IntegrationPluginLoading.cpp
|
|
IntegrationPluginLogLevel.cpp
|
|
IntegrationSetPluginPathsExt.cpp
|
|
IntegrationSetPluginUnloadingModeExt.cpp
|
|
IntegrationTensorDescriptorApi.cpp
|
|
IntegrationVariantPackApi.cpp
|
|
TestUtil.cpp
|
|
)
|
|
|
|
target_compile_options(hipdnn_public_backend_tests PRIVATE ${HIPDNN_WARNING_COMPILE_OPTIONS})
|
|
target_link_libraries(
|
|
hipdnn_public_backend_tests
|
|
PRIVATE
|
|
GTest::gtest
|
|
GTest::gtest_main
|
|
Threads::Threads
|
|
hipdnn_test_sdk
|
|
hipdnn_flatbuffers_sdk
|
|
hipdnn_plugin_sdk
|
|
hipdnn_backend
|
|
hip::host
|
|
)
|
|
|
|
# Enable spdlog support (tests include backend internal headers that use spdlog/fmt)
|
|
hipdnn_enable_spdlog(hipdnn_public_backend_tests)
|
|
|
|
target_include_directories(hipdnn_public_backend_tests PRIVATE ${HIPDNN_TEST_INCLUDE_DIRS})
|
|
|
|
target_compile_definitions(
|
|
hipdnn_public_backend_tests
|
|
PRIVATE TEST_GOOD_PLUGIN_NAME="${TEST_GOOD_PLUGIN_NAME}"
|
|
TEST_EXECUTE_FAILS_PLUGIN_NAME="${TEST_EXECUTE_FAILS_PLUGIN_NAME}"
|
|
TEST_NO_APPLICABLE_ENGINES_A_PLUGIN_NAME="${TEST_NO_APPLICABLE_ENGINES_A_PLUGIN_NAME}"
|
|
TEST_NO_APPLICABLE_ENGINES_B_PLUGIN_NAME="${TEST_NO_APPLICABLE_ENGINES_B_PLUGIN_NAME}"
|
|
TEST_DUPLICATE_ID_A_PLUGIN_NAME="${TEST_DUPLICATE_ID_A_PLUGIN_NAME}"
|
|
TEST_DUPLICATE_ID_B_PLUGIN_NAME="${TEST_DUPLICATE_ID_B_PLUGIN_NAME}"
|
|
TEST_INCOMPLETE_API_PLUGIN_NAME="${TEST_INCOMPLETE_API_PLUGIN_NAME}"
|
|
TEST_GOOD_DEFAULT_PLUGIN_NAME="${TEST_GOOD_DEFAULT_PLUGIN_NAME}"
|
|
TEST_KNOBS_PLUGIN_NAME="${TEST_KNOBS_PLUGIN_NAME}"
|
|
TEST_KNOB_CONSTRAINT_VALIDATION_PLUGIN_NAME="${TEST_KNOB_CONSTRAINT_VALIDATION_PLUGIN_NAME}"
|
|
TEST_INCOMPATIBLE_VERSION_PLUGIN_NAME="${TEST_INCOMPATIBLE_VERSION_PLUGIN_NAME}"
|
|
TEST_OVERRIDE_IMPLEMENTING_PLUGIN_NAME="${HIPDNN_TEST_OVERRIDE_IMPLEMENTING_PLUGIN_TARGET}"
|
|
TEST_OVERRIDE_OMITTING_PLUGIN_NAME="${HIPDNN_TEST_OVERRIDE_OMITTING_PLUGIN_TARGET}"
|
|
TEST_VERSION_LIAR_PLUGIN_NAME="${HIPDNN_TEST_VERSION_LIAR_PLUGIN_TARGET}"
|
|
TEST_SECOND_OVERRIDE_PLUGIN_NAME="${HIPDNN_TEST_SECOND_OVERRIDE_PLUGIN_TARGET}"
|
|
TEST_MALFORMED_VERSION_PLUGIN_NAME="${HIPDNN_TEST_MALFORMED_VERSION_PLUGIN_TARGET}"
|
|
TEST_VERSION_ZERO_PLUGIN_NAME="${HIPDNN_TEST_VERSION_ZERO_PLUGIN_TARGET}"
|
|
TEST_PASS_BY_VALUE_PLUGIN_NAME="${HIPDNN_TEST_PASS_BY_VALUE_PLUGIN_TARGET}"
|
|
TEST_GOOD_HEURISTIC_PLUGIN_NAME="${TEST_GOOD_HEURISTIC_PLUGIN_NAME}"
|
|
)
|
|
|
|
# Ensure test plugins are built before tests
|
|
add_dependencies(
|
|
hipdnn_public_backend_tests
|
|
test_good_plugin
|
|
test_execute_fails_plugin
|
|
test_no_applicable_engines_a_plugin
|
|
test_no_applicable_engines_b_plugin
|
|
test_good_default_plugin
|
|
test_duplicate_id_a_plugin
|
|
test_duplicate_id_b_plugin
|
|
test_incomplete_api_plugin
|
|
test_knobs_plugin
|
|
test_knob_constraint_validation_plugin
|
|
test_incompatible_version_plugin
|
|
${HIPDNN_TEST_OVERRIDE_IMPLEMENTING_PLUGIN_TARGET}
|
|
${HIPDNN_TEST_OVERRIDE_OMITTING_PLUGIN_TARGET}
|
|
${HIPDNN_TEST_VERSION_LIAR_PLUGIN_TARGET}
|
|
${HIPDNN_TEST_SECOND_OVERRIDE_PLUGIN_TARGET}
|
|
${HIPDNN_TEST_MALFORMED_VERSION_PLUGIN_TARGET}
|
|
${HIPDNN_TEST_VERSION_ZERO_PLUGIN_TARGET}
|
|
${HIPDNN_TEST_PASS_BY_VALUE_PLUGIN_TARGET}
|
|
test_good_heuristic_plugin
|
|
)
|
|
|
|
clang_tidy_check(hipdnn_public_backend_tests)
|
|
add_hipdnn_test(hipdnn_public_backend_tests ${CMAKE_CURRENT_BINARY_DIR})
|