Age | Commit message (Collapse) | Author |
|
$ ./scripts/bloat-o-meter _bb_un.oorig busybox_unstripped
function old new delta
fbsplash_main 595 985 +390
fb_drawimage 493 - -493
------------------------------------------------------------------------------
(add/remove: 0/1 grow/shrink: 1/0 up/down: 390/-493) Total: -103 bytes
$ size miscutils/fbsplash.o*
text data bss dec hex filename
2019 0 0 2019 7e3 miscutils/fbsplash.o.oorig
1857 0 0 1857 741 miscutils/fbsplash.o.new
|
|
|
|
a bug where it underflows the string
a bug where it never frees parser_t struct
make read_config() return 0 if parser is NULL,
make config_close() accept and ignore NULL parser -
eliminates many if() blocks
reverse the sense of parser bit flags - negative flags
are harder to grok.
hexdump: revert the change to use config parser, it is BIGGER
and also requires additional quirks in parser
*: explicitly use PARSER_NORMAL instead of 0
function old new delta
login_main 1575 1596 +21
config_close 18 29 +11
bbunpack 383 391 +8
qgravechar 106 109 +3
rtnl_tab_initialize 121 117 -4
expand 1697 1693 -4
man_main 717 712 -5
nameif_main 674 668 -6
hexdump_main 597 591 -6
read_config 217 209 -8
dnsd_main 1478 1470 -8
sysctl_main 203 189 -14
config_open2 44 25 -19
make_device 1177 1141 -36
config_read 597 549 -48
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 4/11 up/down: 43/-158) Total: -115 bytes
|
|
function old new delta
config_read 540 597 +57
config_open2 41 44 +3
rtnl_rtprot_initialize 70 66 -4
rtnl_rttable_initialize 78 73 -5
rtnl_rtscope_initialize 88 83 -5
rtnl_rtrealm_initialize 48 43 -5
rtnl_rtdsfield_initialize 48 43 -5
process_module 566 560 -6
bbunpack 391 383 -8
rtnl_tab_initialize 279 121 -158
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 2/8 up/down: 60/-196) Total: -136 bytes
|
|
(by Valdimir)
function old new delta
config_open2 - 41 +41
config_read 507 542 +35
find_pair 169 187 +18
fopen_for_write - 14 +14
fopen_for_read - 14 +14
find_main 406 418 +12
xfopen_for_write - 10 +10
xfopen_for_read - 10 +10
popstring 134 140 +6
parse_inittab 396 401 +5
next_token 923 928 +5
pack_gzip 1659 1661 +2
bb__parsespent 117 119 +2
fallbackSort 1719 1717 -2
evalvar 1376 1374 -2
qrealloc 36 33 -3
...
...
...
...
singlemount 4579 4569 -10
process_stdin 443 433 -10
patch_main 1111 1101 -10
ifupdown_main 2175 2165 -10
file_action_grep 90 80 -10
uuidcache_init 649 637 -12
hush_main 797 785 -12
read_config 230 217 -13
dpkg_main 3835 3820 -15
read_line_input 3134 3110 -24
sysctl_main 232 203 -29
config_open 40 10 -30
WARN_BAD_LINE 44 - -44
login_main 1714 1575 -139
------------------------------------------------------------------------------
(add/remove: 5/1 grow/shrink: 8/74 up/down: 174/-737) Total: -563 bytes
|
|
|
|
|
|
|
|
function old new delta
fbsplash_main 1121 1043 -78
|
|
function old new delta
fb_drawprogressbar 413 423 +10
fbsplash_main 1146 1121 -25
|
|
mkfifo cmd_pipe
fbsplash -f cmd_pipe .... &
...
echo 33 >cmd_pipe
...
echo 66 >cmd_pipe
Code size: fbsplash_main +116 bytes :(
|
|
"{echo 45; echo 33; } | { sleep 1; fbsplash -f - ...; }"
function old new delta
fb_drawprogressbar - 413 +413
xmalloc_fgetline - 46 +46
xmalloc_reads 184 183 -1
xmalloc_getline 46 - -46
fbsplash_main 1472 1030 -442
------------------------------------------------------------------------------
(add/remove: 2/1 grow/shrink: 0/2 up/down: 459/-489) Total: -30 bytes
text data bss dec hex filename
801181 641 7380 809202 c58f2 busybox_old
801151 641 7380 809172 c58d4 busybox_unstripped
|
|
|
|
image can come from stdin
function old new delta
packed_usage 23872 23932 +60
static.param_names - 57 +57
fbsplash_main 1525 1472 -53
static.param_value 100 - -100
------------------------------------------------------------------------------
(add/remove: 1/1 grow/shrink: 1/1 up/down: 117/-153) Total: -36 bytes
text data bss dec hex filename
801202 641 7380 809223 c5907 busybox_old
801181 641 7380 809202 c58f2 busybox_unstripped
|