[PATCH] D27042: lld: Default image base address to 0x400000

Meador Inge via llvm-commits llvm-commits at lists.llvm.org
Wed Nov 23 08:26:24 PST 2016


On Wed, Nov 23, 2016 at 08:15:22AM -0800, Meador Inge via llvm-commits wrote:

> > I would have a small preference for 2MB on X86_64 and 4MB on x86 (if
> > anyone cares about x86).
> 
> Out curiosity, why?
> 
> On Linux, I see GNU LD uses `0x400000` for x86_64 and AArch64.
> It uses `0x08048000` for i386.  It would be nice to understand
> why GNU LD uses those particular values.

FWIW, here is the upstream Binutils discussion for how the base text
address for x86_64 was arrived at:

https://sourceware.org/ml/binutils/2001-04/msg00391.html

-- 
Meador Inge
meadori at codesourcery.com
CodeSourcery / Mentor Embedded


More information about the llvm-commits mailing list