Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 11 additions & 2 deletions cpp/tensorrt_llm/kernels/trtllmGenKernels/fmha/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,15 @@ configure_file(
file(GLOB_RECURSE SRC_CPP *.cpp)
file(GLOB_RECURSE SRC_CU *.cu)

filter_source_cuda_architectures(SOURCE_LIST SRC_CPP ARCHS 100 103 107 100f)
# Archs listed here are pruned when the build does not enable them. Sm100f has
# no context FMHA kernel, so Rubin needs the prebuilt Sm107a cubins kept
# unconditionally: 107 is omitted below, and the globally-set EXCLUDE_SM_107
# that would drop their metadata rows is cleared for this directory.
set(FMHA_PRUNABLE_ARCHS 100 103 100f)
remove_definitions(-DEXCLUDE_SM_107)

filter_source_cuda_architectures(SOURCE_LIST SRC_CPP
ARCHS ${FMHA_PRUNABLE_ARCHS})

add_library(trtllm_gen_fmha_interface INTERFACE)
target_include_directories(
Expand All @@ -65,7 +73,8 @@ target_include_directories(

include(tllm_cubin_archive)
tllm_add_cubin_archive_sources(
trtllm_gen_fmha "${CMAKE_CURRENT_SOURCE_DIR}/cubin" ARCHS 100 103 107 100f)
trtllm_gen_fmha "${CMAKE_CURRENT_SOURCE_DIR}/cubin"
ARCHS ${FMHA_PRUNABLE_ARCHS})
set(TRTLLM_FMHA_BUILD_DIR "${CMAKE_CURRENT_BINARY_DIR}")
target_compile_definitions(
trtllm_gen_fmha
Expand Down
Loading