On Windows build, making the /bigobj flag global , instead of passing it per file.

To avoid having this flag be passed in per/file manner, we are instead
passing it globally.

This fixes this bug: https://bugs.llvm.org/show_bug.cgi?id=46733

Reviewed-by: aaron.ballman, beanz, meinersbur

Differential Revision: https://reviews.llvm.org/D84038
This commit is contained in:
Zahira Ammarguellat 2020-07-28 17:59:33 -05:00 committed by Michael Kruse
parent fe169bb30a
commit 916f7080e7
2 changed files with 4 additions and 4 deletions

View File

@ -473,6 +473,10 @@ if( MSVC )
endif()
endif()
endif()
# By default MSVC has a 2^16 limit on the number of sections in an object file,
# but in many objects files need more than that. This flag is to increase the
# number of sections.
append("/bigobj" CMAKE_CXX_FLAGS)
endif( MSVC )
# Warnings-as-errors handling for GCC-compatible compilers:

View File

@ -1,7 +1,3 @@
if (MSVC)
set_source_files_properties(PassBuilder.cpp PROPERTIES COMPILE_FLAGS /bigobj)
endif()
add_llvm_component_library(LLVMPasses
PassBuilder.cpp
PassPlugin.cpp