From a0676b6ead197527947724e5959ca747d8fde058 Mon Sep 17 00:00:00 2001 From: manish Date: Wed, 9 Jul 2025 16:56:40 -0700 Subject: [PATCH] [Packaging] Shrink wheel ~35 % via nvcc --compress-mode=size Signed-off-by: manish --- CMakeLists.txt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 770b4ba30..ee03aa751 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -133,6 +133,11 @@ if(BUILD_CUDA) string(APPEND CMAKE_CUDA_FLAGS " --use_fast_math") + # Compress embedded fatbins when we build with CUDA ≥ 12.4 + if (CMAKE_CUDA_COMPILER_VERSION VERSION_GREATER_EQUAL "12.4") + string(APPEND CMAKE_CUDA_FLAGS " --compress-mode=size") + endif() + if(PTXAS_VERBOSE) # Verbose? Outputs register usage information, and other things... string(APPEND CMAKE_CUDA_FLAGS " -Xptxas=-v")