diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2018-08-04 11:53:41 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2018-08-04 11:53:41 +0000 |
commit | bbd7a9298f75b52cf65ffa6ea4cfe0958a3fc8cf (patch) | |
tree | 173be7fb159909fd57f4b1e6109e6d0b38fb87af /contrib/llvm/tools/lld | |
parent | a757dfacfa56d883b1bd7529be1ef60c03f27fd1 (diff) | |
parent | 37528fb4fbc5aa8de4c3d6753e6579bff7af9af7 (diff) |
Merge ^/head r336870 through r337285, and resolve conflicts.
Notes
Notes:
svn path=/projects/clang700-import/; revision=337286
Diffstat (limited to 'contrib/llvm/tools/lld')
-rw-r--r-- | contrib/llvm/tools/lld/ELF/Arch/AArch64.cpp | 4 | ||||
-rw-r--r-- | contrib/llvm/tools/lld/ELF/Arch/X86.cpp | 4 |
2 files changed, 8 insertions, 0 deletions
diff --git a/contrib/llvm/tools/lld/ELF/Arch/AArch64.cpp b/contrib/llvm/tools/lld/ELF/Arch/AArch64.cpp index c7b3c0801de2..ae072d4adaac 100644 --- a/contrib/llvm/tools/lld/ELF/Arch/AArch64.cpp +++ b/contrib/llvm/tools/lld/ELF/Arch/AArch64.cpp @@ -66,6 +66,10 @@ AArch64::AArch64() { PltHeaderSize = 32; DefaultMaxPageSize = 65536; + // Align to the 2 MiB page size (known as a superpage or huge page). + // FreeBSD automatically promotes 2 MiB-aligned allocations. + DefaultImageBase = 0x200000; + // It doesn't seem to be documented anywhere, but tls on aarch64 uses variant // 1 of the tls structures and the tcb size is 16. TcbSize = 16; diff --git a/contrib/llvm/tools/lld/ELF/Arch/X86.cpp b/contrib/llvm/tools/lld/ELF/Arch/X86.cpp index 19a0b6017f1a..0624fe78750c 100644 --- a/contrib/llvm/tools/lld/ELF/Arch/X86.cpp +++ b/contrib/llvm/tools/lld/ELF/Arch/X86.cpp @@ -60,6 +60,10 @@ X86::X86() { PltHeaderSize = 16; TlsGdRelaxSkip = 2; TrapInstr = 0xcccccccc; // 0xcc = INT3 + + // Align to the non-PAE large page size (known as a superpage or huge page). + // FreeBSD automatically promotes large, superpage-aligned allocations. + DefaultImageBase = 0x400000; } static bool hasBaseReg(uint8_t ModRM) { return (ModRM & 0xc7) != 0x5; } |