summaryrefslogtreecommitdiffstats
path: root/src/build/tools/hb
diff options
context:
space:
mode:
authorPatrick Williams <iawillia@us.ibm.com>2013-06-19 14:30:55 -0500
committerA. Patrick Williams III <iawillia@us.ibm.com>2013-07-12 09:28:26 -0500
commit3699cdda9adeabf550b3e875b35218620e93f186 (patch)
tree75870ea4a2c604ec6a352e1069ad3710f922e93c /src/build/tools/hb
parentcc3da0a999d8d37cfbb53d8386a6c0b9e3fa3992 (diff)
downloadtalos-hostboot-3699cdda9adeabf550b3e875b35218620e93f186.tar.gz
talos-hostboot-3699cdda9adeabf550b3e875b35218620e93f186.zip
Make libs smaller by overlapping text and rodata sections.
Change-Id: I0f3b9a941c19040635752b2648ef51c50dba849b Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/5135 Tested-by: Jenkins Server Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
Diffstat (limited to 'src/build/tools/hb')
-rwxr-xr-xsrc/build/tools/hb11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/build/tools/hb b/src/build/tools/hb
index d1b86e705..f5690f990 100755
--- a/src/build/tools/hb
+++ b/src/build/tools/hb
@@ -402,16 +402,17 @@ hb_objsizes()
{
[ -z "${HOSTBOOTROOT}" ] && echo "Missing HOSTBOOTROOT." && exit -1
- echo "Object,Text Size,Data Size"
+ echo "Object,Text Size,RO Data Size,Data Size"
objdump -h ${HOSTBOOTROOT}/img/*.elf ${HOSTBOOTROOT}/img/*.so | \
- grep -e ".elf" -e ".so:" -e ".text " -e ".data " | \
+ grep -e ".elf" -e ".so:" -e ".text " -e ".rodata" -e ".data " | \
sed "s/.so:.*/.so/" | \
sed "s/.elf:.*/.elf/" | \
sed 's/.*\.text *\([0-9a-f]*\).*/,0x\1/' | \
- sed "s/.*\.data *\([0-9a-f]*\).*/,0x\1/" | \
- sed "N ; N ; s/\n//g" | \
- xargs -n1 perl -e 'printf "%s,%d,%d\n", map { 0 == hex $_ ? $_ : hex $_ } split /\,/,shift;' | \
+ sed 's/.*\.rodata *\([0-9a-f]*\).*/,0x\1/' | \
+ sed 's/.*\.data *\([0-9a-f]*\).*/,0x\1/' | \
+ sed "N ; N ; N ; s/\n//g" | \
+ xargs -n1 perl -e 'printf "%s,%d,%d,%d\n", map { 0 == hex $_ ? $_ : hex $_ } split /\,/,shift;' | \
sed "s/.*\///"
}
OpenPOWER on IntegriCloud