Skip to content

Commit

Permalink
cmake: increase the MAX_{LINK,COMPILE}_MEM
Browse files Browse the repository at this point in the history
based on recent observation, quite a few C++ source file take
around more than 3.0GiB to compile. for instance,
test_mock_HttpClient.cc could take up to 6270MiB memory to compile.

so increase MAX_{LINK,COMPILE}_MEM accordingly.

Signed-off-by: Kefu Chai <kchai@redhat.com>
  • Loading branch information
tchaikov committed Jun 3, 2021
1 parent 38be14b commit 7577fec
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cmake/modules/LimitJobs.cmake
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
set(MAX_COMPILE_MEM 2500 CACHE INTERNAL "maximum memory used by each compiling job (in MiB)")
set(MAX_LINK_MEM 3300 CACHE INTERNAL "maximum memory used by each linking job (in MiB)")
set(MAX_COMPILE_MEM 3500 CACHE INTERNAL "maximum memory used by each compiling job (in MiB)")
set(MAX_LINK_MEM 4500 CACHE INTERNAL "maximum memory used by each linking job (in MiB)")

cmake_host_system_information(RESULT _num_cores QUERY NUMBER_OF_LOGICAL_CORES)
cmake_host_system_information(RESULT _total_mem QUERY TOTAL_PHYSICAL_MEMORY)
Expand Down

0 comments on commit 7577fec

Please sign in to comment.