gzip is faster with -O3

Matthias Andree matthias.andree at gmx.de
Wed Aug 9 14:17:32 UTC 2006


"Nikolas Britton" <nikolas.britton at gmail.com> writes:

> dd if=/dev/random of=testfile bs=1m count=5000

1. gzip isn't usually used to compress incompressible data.

2. use "time" to figure out how much CPU time it actually burns.
   5 GB are somewhat I/O bound, but gcc options don't help with that, so
   CPU time is better than wallclock time.

> gzip compiled with -O3:
> # date ; nice -10 ./gzip -c9 testfile > testfile.gz ; date
> Wed Aug  9 08:01:21 CDT 2006

-- 
Matthias Andree


More information about the freebsd-stable mailing list