diff options
| author | bors <bors@rust-lang.org> | 2014-09-08 11:56:12 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2014-09-08 11:56:12 +0000 |
| commit | 5c3987985e919a47826dd5d68a7cf1b50c8837cf (patch) | |
| tree | ef86a5d9a8902598ed6318be102e67ed59c9e943 | |
| parent | ab7b1c896d5d929f3e150bf62c69b1459427a538 (diff) | |
| parent | c6633fde5302be357014c9aa14461857d99d0075 (diff) | |
| download | rust-5c3987985e919a47826dd5d68a7cf1b50c8837cf.tar.gz rust-5c3987985e919a47826dd5d68a7cf1b50c8837cf.zip | |
auto merge of #17053 : thestinger/rust/large_address_aware, r=sfackler,cmr
By default, 32-bit Windows executables are restricted to 2GiB of address space even when running on 64-bit Windows when 4GiB is available. Closes #17043
| -rw-r--r-- | src/librustc/back/link.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/librustc/back/link.rs b/src/librustc/back/link.rs index 25bffe4289b..bf026560c6a 100644 --- a/src/librustc/back/link.rs +++ b/src/librustc/back/link.rs @@ -1015,6 +1015,12 @@ fn link_args(cmd: &mut Command, // Mark all dynamic libraries and executables as compatible with ASLR cmd.arg("-Wl,--dynamicbase"); + + // Mark all dynamic libraries and executables as compatible with the larger 4GiB address + // space available to x86 Windows binaries on x86_64. + if sess.targ_cfg.arch == abi::X86 { + cmd.arg("-Wl,--large-address-aware"); + } } if sess.targ_cfg.os == abi::OsAndroid { |
