[gdb/contrib] Combine sed invocations in words.sh script
Currently running words.sh on all the c source and header files in the repo
takes ~16s in user time:
...
$ time ./gdb/contrib/words.sh \
$(find -type f -name "*.c" -o -name "*.h") \
>/dev/null
real 0m7,787s
user 0m16,349s
sys 0m0,367s
...
Rewrite the sed invocations using the -e option from this:
...
| sed <sedprog1>
| sed <sedprog2>
...
into this:
...
| sed \
-e <sedprog1>
-e <sedprog2>
...
and reduce user time to ~11s:
...
$ time ./gdb/contrib/words.sh \
$(find -type f -name "*.c" -o -name "*.h") \
>/dev/null
real 0m7,243s
user 0m11,220s
sys 0m0,205s
...
gdb/ChangeLog:
2019-11-22 Tom de Vries <tdevries@suse.de>
* contrib/words.sh: Combine sed invocations.
Change-Id: Ib08453f3712f32ed02d9f503ee960711ebb9421b