From owner-freebsd-arch@FreeBSD.ORG Wed Jul 10 03:07:32 2013 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 8BEB464E for ; Wed, 10 Jul 2013 03:07:32 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from mail-ie0-f181.google.com (mail-ie0-f181.google.com [209.85.223.181]) by mx1.freebsd.org (Postfix) with ESMTP id 5AA151F4C for ; Wed, 10 Jul 2013 03:07:32 +0000 (UTC) Received: by mail-ie0-f181.google.com with SMTP id x12so13563714ief.26 for ; Tue, 09 Jul 2013 20:07:26 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=sender:subject:mime-version:content-type:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to:x-mailer :x-gm-message-state; bh=OQ9IKJ291o5pzQRoh/NmOeIfQ2uus92flWd/vnwXpkg=; b=Xm+LtF6K6PNC8dc6sy1peqYHdww5fLJRe+wfPab7Kbw32JUgQ4wRnz6fRRFZA+YSrK JVwYh5ODCMuyXxMCk9LKjiY+vCWuGXQ0MNVjek9L61HeUxq9PsqRPB57qwXMjn1ziR15 Z6erhb+jEYxY1Dz0g9GZilTH+MlVaKLFKyq20tTzT1GkHeb1OYnfmFCLP3Jhm+UJwPI0 pVkQ4EZ5VaR5O5wUXK9NQT/EpFHPPVMHQr9oULUfLZs+peMbM6IEGJl+fgGq8hKO/1pB aEdfrHmzBeHSa7d5lFSAlvbVOyYb/9mUIAph/2OC0fUkhz3NjvKIhONHsPWgto5ykrLt E5Uw== X-Received: by 10.43.14.74 with SMTP id pp10mr503229icb.87.1373425646747; Tue, 09 Jul 2013 20:07:26 -0700 (PDT) Received: from 53.imp.bsdimp.com (50-78-194-198-static.hfc.comcastbusiness.net. [50.78.194.198]) by mx.google.com with ESMTPSA id y9sm34618273iga.9.2013.07.09.20.07.25 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 09 Jul 2013 20:07:25 -0700 (PDT) Sender: Warner Losh Subject: Re: Adding a MACHINE_ARCH note Mime-Version: 1.0 (Apple Message framework v1085) Content-Type: text/plain; charset=us-ascii From: Warner Losh In-Reply-To: Date: Tue, 9 Jul 2013 21:07:24 -0600 Content-Transfer-Encoding: quoted-printable Message-Id: <4B3C4D68-EF16-4B49-B8E7-FFDEAA751005@bsdimp.com> References: <20130709090744.0e497e7e@bender.Home> <32F979BD-FB5C-4111-9586-4C5E7C6DFA71@bsdimp.com> <20130709234837.559e3769@bender.Home> To: Peter Wemm X-Mailer: Apple Mail (2.1085) X-Gm-Message-State: ALoCoQn32KOEHV4oOV64Ec+LZo0d3ZmxaBzvOROTU2cSHqUbLZ17OPJzuj4FtIkbQoN2E42gyPMf Cc: Adrian Chadd , freebsd-arch@freebsd.org, Baptiste Daroussin , Andrew Turner X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Jul 2013 03:07:32 -0000 On Jul 9, 2013, at 7:08 PM, Peter Wemm wrote: > On Tue, Jul 9, 2013 at 5:56 PM, Adrian Chadd = 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 wrote: >>> On Tue, Jul 9, 2013 at 5:40 PM, Adrian Chadd = 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 wrote: >>>>> On Tue, 9 Jul 2013 08:19:46 -0600 >>>>> Warner Losh 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 >>> 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 > 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"