Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 9 Jul 2013 21:07:24 -0600
From:      Warner Losh <imp@bsdimp.com>
To:        Peter Wemm <peter@wemm.org>
Cc:        Adrian Chadd <adrian@freebsd.org>, freebsd-arch@freebsd.org, Baptiste Daroussin <bapt@freebsd.org>, Andrew Turner <andrew@fubar.geek.nz>
Subject:   Re: Adding a MACHINE_ARCH note
Message-ID:  <4B3C4D68-EF16-4B49-B8E7-FFDEAA751005@bsdimp.com>
In-Reply-To: <CAGE5yCq9gQERDkbi4wu=6tNUap24ZR7sL7aF%2BzmEO0eT6nxPsA@mail.gmail.com>
References:  <20130709090744.0e497e7e@bender.Home> <32F979BD-FB5C-4111-9586-4C5E7C6DFA71@bsdimp.com> <20130709234837.559e3769@bender.Home> <CAJ-Vmo=iV8BsGriFRgNuP-ZJdQhpmBLhjAkz-nSVRS0HPKSyOQ@mail.gmail.com> <CAGE5yCpJmRDvnaYtozj4bCqNoQXH=1e96HPJAqwJuRdn4H9BZA@mail.gmail.com> <CAJ-Vmo=tmGDW3Ubw9nr5rb30bXr1dcJUkKLOU7L=_bx29zvEhw@mail.gmail.com> <CAGE5yCq9gQERDkbi4wu=6tNUap24ZR7sL7aF%2BzmEO0eT6nxPsA@mail.gmail.com>

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

On Jul 9, 2013, at 7:08 PM, Peter Wemm wrote:

> On Tue, Jul 9, 2013 at 5:56 PM, Adrian Chadd <adrian@freebsd.org> =
wrote:
>> ... boy I'd like to see this particular x86 hiccup fixed before this
>> stuff is mainstream.
>=20
> I'm not entirely sure how much support there is behind "x32".  I don't
> know if its much more than an academic curiosity or if there's real
> demand for it.  gcc-4.8 and clang have it, or have patches for it.
>=20
> https://sites.google.com/site/x32abi/
>=20
> http://www.phoronix.com/scan.php?page=3Dnews_item&px=3DMTExNDE

If FreeBSD ever does support x32, we'd do what we do on MIPS for the =
odd-ball n32 where we have mipsn32 as the uname -p.

Warner

>=20
>> adrian
>>=20
>> On 9 July 2013 17:54, Peter Wemm <peter@wemm.org> wrote:
>>> On Tue, Jul 9, 2013 at 5:40 PM, Adrian Chadd <adrian@freebsd.org> =
wrote:
>>>> Someone pointed out there's dirty people running 32-bit binaries =
using
>>>> the 64-bit intel/amd instruction set.
>>>>=20
>>>> Is this also able to represent that?
>>>=20
>>> That would be "X32", so there's 3 x86 ABI variants:
>>> i386 - 32 bit
>>> amd64 - 32 bit
>>> amd64 - 64 bit
>>>=20
>>> Incidentally, pkgng has a issues with this.  For some reason it =
lumps
>>> both i386 and amd64 into a single pseudo-arch called "x86" with a 32
>>> and 64 bit variant.  It doesn't leave room for distinguishing the =
two
>>> incompatible 32 bit architectures.
>>>=20
>>> "x32" is where the compiler generates code where "long" and =
"pointer"
>>> are 32 bit, but the instruction set is otherwise amd64 and has all =
16
>>> general purpose registers available.   "long long" is a 64 bit
>>> register instead of a pair of 32 bit registers like on i386.
>>>=20
>>>> -adrian
>>>>=20
>>>> On 9 July 2013 15:48, Andrew Turner <andrew@fubar.geek.nz> wrote:
>>>>> On Tue, 9 Jul 2013 08:19:46 -0600
>>>>> Warner Losh <imp@bsdimp.com> wrote:
>>>>>> I thought that the ELF headers gave us all the data we needed to =
know
>>>>>> how things were built...
>>>>>=20
>>>>> It will tell us if it was for e.g. an ARM or MIPS ELF file, but =
I'm not
>>>>> sure how we can tell the difference between an arm and an armv6 =
ELF.
>>>>>=20
>>>>> With armv6 there are a few changes in the userland/kernel
>>>>> interface, e.g. reading the thread local storage pointer is =
different
>>>>> such that an armv6 static binary would not run on an ARMv5 core as =
it
>>>>> uses newer instructions.
>>>>>=20
>>>>> Andrew
>>>>> _______________________________________________
>>>>> freebsd-arch@freebsd.org mailing list
>>>>> http://lists.freebsd.org/mailman/listinfo/freebsd-arch
>>>>> To unsubscribe, send any mail to =
"freebsd-arch-unsubscribe@freebsd.org"
>>>> _______________________________________________
>>>> freebsd-arch@freebsd.org mailing list
>>>> http://lists.freebsd.org/mailman/listinfo/freebsd-arch
>>>> To unsubscribe, send any mail to =
"freebsd-arch-unsubscribe@freebsd.org"
>>>=20
>>>=20
>>>=20
>>> --
>>> Peter Wemm - peter@wemm.org; peter@FreeBSD.org; peter@yahoo-inc.com; =
KI6FJV
>>> UTF-8: So you can \342\200\231 .. for when a ' just won't do
>>> <brueffer> ZFS must be the bacon of file systems. "everything's =
better with ZFS"
>=20
>=20
>=20
> --=20
> Peter Wemm - peter@wemm.org; peter@FreeBSD.org; peter@yahoo-inc.com; =
KI6FJV
> UTF-8: So you can \342\200\231 .. for when a ' just won't do
> <brueffer> ZFS must be the bacon of file systems. "everything's better =
with ZFS"
> _______________________________________________
> freebsd-arch@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-arch
> To unsubscribe, send any mail to =
"freebsd-arch-unsubscribe@freebsd.org"




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4B3C4D68-EF16-4B49-B8E7-FFDEAA751005>