www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/1999/07/20/20:27:18

Message-Id: <199907210026.AAA10018@out5.ibm.net>
From: "Mark E." <snowball3 AT bigfoot DOT com>
To: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>, djgpp-workers AT delorie DOT com
Date: Tue, 20 Jul 1999 20:27:08 -0400
MIME-Version: 1.0
Subject: Re: .align directives in libc.a
References: <199907182125 DOT VAA68238 AT out5 DOT ibm DOT net>
In-reply-to: <Pine.SUN.3.91.990720115957.4115G-100000@is>
X-mailer: Pegasus Mail for Win32 (v3.11)
Reply-To: djgpp-workers AT delorie DOT com

> Did you see anything in your testing that would contradict the
> conclusion, namely, that configuring Binutils with a 16-byte default
> alignment of sections would not cause too much waste?

Here's one file I've been experimenting with.
test4.s:
.data
.globl _d1
_d1:
  ret
.globl _d2
_d2:
  ret

.text
.globl _t1
_t1:
  ret
.globl _t2
_t2:
  ret

.data
.globl _d3
_d3:
  ret
.globl _d4
_d4:
  ret

.text
.globl _t3
_t3:
  ret
.globl _t4
_t4:
  ret

When compiled with 2^2 alignment, the stripped object file size is 148 
bytes. When compiled with 2^4 alignment, the stripped object file size 
is 172. Taking out the duplicate .data and .text sections makes no 
difference, like I thought might hold down the bloat. So it appears 
estimated libc bloat is correct. The tests were done with BFD 
assembler updated from CVS late yesterday.

Note that debugging sections have a max section alignment of 2^2, so 
debugging builds won't suffer more than non-debugging builds.

Mark



--- 
Mark Elbrecht, snowball3 AT bigfoot DOT com
http://snowball.frogspace.net/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019