File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -1687,6 +1687,12 @@ function Build-Compilers() {
1687
1687
$SwiftFlags += @ (" -Xcc" , " -D_ALLOW_COMPILER_AND_STL_VERSION_MISMATCH" );
1688
1688
}
1689
1689
1690
+ # Limit the number of parallel links to avoid OOM when debug info is enabled
1691
+ $DebugOptions = @ {}
1692
+ if ($DebugInfo ) {
1693
+ $DebugOptions = @ { SWIFT_PARALLEL_LINK_JOBS = " 4" ; }
1694
+ }
1695
+
1690
1696
New-Item - ItemType SymbolicLink - Path " $BinaryCache \$ ( $HostArch.LLVMTarget ) \compilers" - Target " $BinaryCache \5" - ErrorAction Ignore
1691
1697
Build-CMakeProject `
1692
1698
- Src $SourceCache \llvm- project\llvm `
@@ -1737,7 +1743,7 @@ function Build-Compilers() {
1737
1743
SWIFT_STDLIB_ASSERTIONS = " NO" ;
1738
1744
SWIFTSYNTAX_ENABLE_ASSERTIONS = " NO" ;
1739
1745
" cmark-gfm_DIR" = " $ ( $Arch.ToolchainInstallRoot ) \usr\lib\cmake" ;
1740
- })
1746
+ } + $DebugOptions )
1741
1747
}
1742
1748
1743
1749
$Settings = @ {
You can’t perform that action at this time.
0 commit comments