[Users] Q. re: tags (tagging locally-saved messages for use outside Claws)
Ralf Mardorf
silver.bullet at zoho.com
Fri Mar 24 20:06:03 CET 2017
Ok, printf is faster with or without bash:
[rocketmouse at archlinux Desktop]$ cat dash.sh
#!/bin/dash
for i in `seq 1 1000`
do
basename "$PWD" >/dev/null
done
exit
[rocketmouse at archlinux Desktop]$ cat bash.sh
#!/bin/bash
for i in `seq 1 1000`
do
printf "${PWD##*/}\n" >/dev/null
done
exit
[rocketmouse at archlinux Desktop]$ time ./dash.sh
real 0m0.468s
user 0m0.010s
sys 0m0.053s
[rocketmouse at archlinux Desktop]$ time ./bash.sh
real 0m0.042s
user 0m0.033s
sys 0m0.007s
[rocketmouse at archlinux Desktop]$ cat dash.sh
#!/bin/dash
for i in `seq 1 1000`
do
printf "${PWD##*/}\n" >/dev/null
done
exit
[rocketmouse at archlinux Desktop]$ cat bash.sh
#!/bin/bash
for i in `seq 1 1000`
do
basename "$PWD" >/dev/null
done
exit
[rocketmouse at archlinux Desktop]$ time ./dash.sh
real 0m0.017s
user 0m0.007s
sys 0m0.007s
[rocketmouse at archlinux Desktop]$ time ./bash.sh
real 0m0.531s
user 0m0.030s
sys 0m0.063s
More information about the Users
mailing list