Skip to content

Commit

Permalink
Reduce the size of the cuml libraries (#3702)
Browse files Browse the repository at this point in the history
By explicitly telling nvcc's fatbin pass to always compress device code we can ensure that our binaries are the smallest possible size.

See rapidsai/cudf#7583 for additional context.

Authors:
  - Robert Maynard (https://github.com/robertmaynard)

Approvers:
  - Dante Gama Dessavre (https://github.com/dantegd)

URL: #3702
  • Loading branch information
robertmaynard authored Apr 5, 2021
1 parent 4bf0ba4 commit b45e27b
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions cpp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -325,6 +325,9 @@ set(FAISS_GPU_ARCHS "${FAISS_GPU_ARCHS} ${ptx}")
set(CMAKE_CUDA_FLAGS
"${CMAKE_CUDA_FLAGS} -Xcudafe --diag_suppress=unrecognized_gcc_pragma")

# make sure we produce smallest binary size
string(APPEND CMAKE_CUDA_FLAGS " -Xfatbin=-compress-all")

##############################################################################
# - dependencies -------------------------------------------------------------

Expand Down

0 comments on commit b45e27b

Please sign in to comment.