aboutsummaryrefslogtreecommitdiff
path: root/util-linux/mkfs_ext2.txt
diff options
context:
space:
mode:
authorRon Yorston <rmy@pobox.com>2021-01-29 13:23:27 +0000
committerDenys Vlasenko <vda.linux@googlemail.com>2021-02-02 14:37:37 +0100
commitbcf91d276047910538c5de0a45f3a4645e3ff471 (patch)
tree87feb6eb824d4fc2ee27918a559a03df28e15a99 /util-linux/mkfs_ext2.txt
parent59120c330330467c9e6aaec6d4ca8295baa653af (diff)
downloadbusybox-bcf91d276047910538c5de0a45f3a4645e3ff471.tar.gz
libbb: code shrink and speed up index_in_strings()
Rewrite index_in_strings() to replace calls to strcmp()/strlen(). With this change searching for valid names in the applet_names array (for example) is 40% faster. The code has to assume the strings aren't sorted, so will always scan the entire array when presented with an invalid name. function old new delta index_in_strings 63 56 -7 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 0/1 up/down: 0/-7) Total: -7 bytes Signed-off-by: Ron Yorston <rmy@pobox.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'util-linux/mkfs_ext2.txt')
0 files changed, 0 insertions, 0 deletions