From owner-freebsd-current Wed Sep 2 18:50:03 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id SAA18822 for freebsd-current-outgoing; Wed, 2 Sep 1998 18:50:03 -0700 (PDT) (envelope-from owner-freebsd-current@FreeBSD.ORG) Received: from smtp02.primenet.com (smtp02.primenet.com [206.165.6.132]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id SAA18757 for ; Wed, 2 Sep 1998 18:49:59 -0700 (PDT) (envelope-from tlambert@usr07.primenet.com) Received: (from daemon@localhost) by smtp02.primenet.com (8.8.8/8.8.8) id SAA04475; Wed, 2 Sep 1998 18:48:57 -0700 (MST) Received: from usr07.primenet.com(206.165.6.207) via SMTP by smtp02.primenet.com, id smtpd004457; Wed Sep 2 18:48:55 1998 Received: (from tlambert@localhost) by usr07.primenet.com (8.8.5/8.8.5) id SAA04854; Wed, 2 Sep 1998 18:48:53 -0700 (MST) From: Terry Lambert Message-Id: <199809030148.SAA04854@usr07.primenet.com> Subject: Re: ELF binaries size To: eivind@yes.no (Eivind Eklund) Date: Thu, 3 Sep 1998 01:48:52 +0000 (GMT) Cc: bde@zeta.org.au, current@FreeBSD.ORG In-Reply-To: <19980902171903.50388@follo.net> from "Eivind Eklund" at Sep 2, 98 05:19:03 pm X-Mailer: ELM [version 2.4 PL25] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG > Ah, got it. Stupid me. In case there are anybody left that didn't > think hard enough: > > 00000000|11111111|22222222 (Page numbers) > | | > TTTTTTT |DDDDDDD | Under a.out non-overflow - always 2 pages > | | > V| | Under ELF - 2 pages unless marked spot is > TTTTTTTD|DDDDDD | written, then 3 pages - 1 page wasted. > | | > TTTTTTT |DDDDDDDD|D Under a.out overflow - 3 pages > | | > V| | > TTTTTTTD|DDDDDDDD| Under ELF - 2 pages unless marked spot is > | | written, then 3 pages. Actually, no. This would require buggering the fault handler to know about executables. It's actually: Case #1: 00000000|11111111|22222222 (Page numbers) | | TTTTTTDD| | ELF image TTTTTT |DD | a.out image | | TTTTTT | DD| ELF in core TTTTTT |DD | a.out in core Case #2: 00000000|11111111|22222222 (Page numbers) | | TTTTTTTD|DDDDDDDD| ELF image TTTTTTT |DDDDDDDD|D a.out image | | TTTTTTT | D|DDDDDDDD ELF in core TTTTTTT |DDDDDDDD|D a.out in core Case #3: 00000000|11111111|22222222 (Page numbers) | | TTTTTTDD|DD | ELF image TTTTTT |DDDD | a.out image | | TTTTTT | DD|DD ELF in core TTTTTT |DDDD | a.out in core ...in other words, ELF will waste an extra page in core approximately 50% of the time (excluding other section effects, which may exist). Terry Lambert terry@lambert.org --- Any opinions in this posting are my own and not those of my present or previous employers. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message