small optimizations to lz77 decompression