From owner-freebsd-arch Tue May 7 11:58:58 2002 Delivered-To: freebsd-arch@freebsd.org Received: from trantor.utsl.org (cvg-65-27-234-192.cinci.rr.com [65.27.234.192]) by hub.freebsd.org (Postfix) with ESMTP id 5555437B403 for ; Tue, 7 May 2002 11:58:50 -0700 (PDT) Received: from hotrod.utsl.org ([10.10.57.3] helo=quic.net) by trantor.utsl.org with esmtp (Exim 3.35 #1 (Debian)) id 175AAj-00011J-00 for ; Tue, 07 May 2002 14:58:49 -0400 Message-ID: <3CD823E8.2010809@quic.net> Date: Tue, 07 May 2002 14:58:48 -0400 From: Nathan Hawkins User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.0rc1) Gecko/20020502 Debian/1.0rc1-3 MIME-Version: 1.0 To: arch@FreeBSD.ORG Subject: Re: syscall changes to deal with 32->64 changes. References: <3CD7FE57.1000508@quic.net> <20020507110901.F23330@dragon.nuxi.com> X-Enigmail-Version: 0.49.5.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG David O'Brien wrote: >On Tue, May 07, 2002 at 12:18:31PM -0400, Nathan Hawkins wrote: > > >>I'd like to see FreeBSD start using ELF .note.ABI-tag sections to handle >>the binary OS type/versioning. I know that at least NetBSD, Linux and >>Hurd do it this way, and I think most others do too. >> >> > >Why? Just to follow the NIH herd? The EI_OSABI and EI_ABIVERSION fields >were in the gABI spec before anyone started using .note sections for >this. > > Because AFAICS, it's a defacto, unwritten standard. Even if it violates spec. NIH is a matter of perspective. FreeBSD could be considered to be in NIH mode, because the other ELF based systems use a different method. >If .note.ABI-tag is the end all and be all, then why did the ELF spec >authors even create EI_OSABI and EI_ABIVERSION?? And why did they put >things in the ELF header such that things are very easy to parse just by >reading a small amount of a binary? A LOT of the things in an ELF header >could have been put in .note sections. But they weren't because it is so >much easier to read fixed structures. > I have no axe to grind here. I don't consider the .note.ABI-tag to be a beautiful way to do things. You're right, it should be faster to get this from a field in the ELF header. But you also use the .interp section in the emulation selector code. I think that the .note.ABI-tag would be a better choice. >That said, run readelf on any FreeBSD binary, you will find a >.note.ABI-tag section. I just never got around to adding support for it >to imgact_elf. > Yes, I can see that. I've looked at adding support to imgact_elf. I haven't had time to try yet. ---Nathan To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message