grep -i and egrep seem dog slow compared to 12.3-RELEASE
also slow compared with awk, php, tcl
sed is also slow
12.3
13.0
my theory is that
should be removed
the 2 boxes have about the same raw performance
also slow compared with awk, php, tcl
sed is also slow
12.3
Code:
+ time egrep 'Zyzzogeton|york' /usr/share/dict/web2
york
yorker
Zyzzogeton
0.05 real 0.04 user 0.00 sys
+ time grep -i Zyzzogeton /usr/share/dict/web2
Zyzzogeton
0.27 real 0.27 user 0.00 sys
+ time grep Zyzzogeton /usr/share/dict/web2
Zyzzogeton
0.00 real 0.00 user 0.00 sys
Code:
+ time egrep 'Zyzzogeton|york' /usr/share/dict/web2
york
yorker
Zyzzogeton
0.66 real 0.66 user 0.00 sys
+ time grep -i Zyzzogeton /usr/share/dict/web2
Zyzzogeton
0.58 real 0.58 user 0.00 sys
+ time grep Zyzzogeton /usr/share/dict/web2
Zyzzogeton
0.01 real 0.00 user 0.00 sys
Code:
/usr/src/lib/libc/regex/regex2.h line 141
if (cs->icase) {
if (ch == towlower(cs->wides[i]) ||
ch == towupper(cs->wides[i]))
return (!cs->invert);
}
the 2 boxes have about the same raw performance