Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 31 Oct 2006 11:03:03 +0200
From:      Kostik Belousov <kostikbel@gmail.com>
To:        Michael Bushkov <bushman@freebsd.org>
Cc:        freebsd-hackers@freebsd.org
Subject:   Re: PIC questions
Message-ID:  <20061031090303.GH1627@deviant.kiev.zoral.com.ua>
In-Reply-To: <200610311126.32121.bushman@freebsd.org>
References:  <200610311126.32121.bushman@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help

--bpVaumkpfGNUagdU
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Tue, Oct 31, 2006 at 12:26:31PM +0400, Michael Bushkov wrote:
> Hi,
> I've got 2 questions about PIC.
>=20
> 2. And theoretical question. Does every object that will be linked into t=
he=20
> shared library should be built with PIC enabled?
This is not so theoretical. This is required, for instance, for amd64. Beca=
use
compiler by default generates so called small code model where text and data
of object shall live in lower 2 Gb of address space. Solaris linker will gi=
ve
warnings when relocations are to big to fit into signed 32-bit location. Our
linker will silently ignore overflow. This will result in either core dump
(if you lucky), or data corruption.

--bpVaumkpfGNUagdU
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (FreeBSD)

iD8DBQFFRxFGC3+MBN1Mb4gRAiV6AKDGNMRdEvo1c3HQmlrT/sY2phoxbwCg2vw6
DA1NCmRg4stNpXwYoUdduTM=
=ZRcM
-----END PGP SIGNATURE-----

--bpVaumkpfGNUagdU--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20061031090303.GH1627>