*: use TeeReader to reduce I/O in CAS

I think it's worth creating a PR for diskv to add Rename(). Then it would be possible to tee off first 512 bytes to detect compression type and decompress, store and calc hash in one pass (via another tee).