config: prefer core.compression=5
commita21e6adf900332ff6a98f4f9293901cfb6185df5
authorKyle J. McKay <mackyle@gmail.com>
Sun, 18 Jun 2017 18:07:46 +0000 (18 11:07 -0700)
committerKyle J. McKay <mackyle@gmail.com>
Sun, 18 Jun 2017 18:07:46 +0000 (18 11:07 -0700)
treecb4bde37bfcec56dce3a2860da833229a103c67c
parenteabf8803f74f41d28281806cfd9d40fb56db2034
config: prefer core.compression=5

When initializing a new repository or updating a repository's
config, prefer to set a core.compression value of 5 (leaving an
existing valid but different value alone on config update).

There are two reasons for this:

1) If left unset the defaults for core.compression and
   core.looseCompression differ.  That implies potentially
   wasteful recompression may take place when packing loose
   objects into packs.

2) The default value (-1) which specifies the zlib default
   (which is currently 6) does not provide the best tradeoff.

Number (1) could be corrected simply by setting a core.compression
value of -1 which would provide a core.looseCompression default
and levels would then match and (1) would go away.

However, it turns out that the speed difference between levels 4
and 5 is generally somewhat less than the speed difference between
levels 5 and 6 (the zlib default) while the space savings between
levels 4 and 5 is generally double the space savings between
levels 5 and 6.

This may not be the case generally but seems to be the case when
dealing with Git objects.  In other words, level 5 is the
inflection point of the graph, not 6.  Thus level 5 provides the
better speed, space and time tradeoff than level 6 does.

Make it so.

Signed-off-by: Kyle J. McKay <mackyle@gmail.com>
Girocco/Project.pm
jailsetup.sh
toolbox/update-all-config.sh