The algorithm is proving to be a little slow when used several times in a row to compress many small files. Not to mention that in debug, since it uses iterators, its slow thanks to iterator debugging.
If possibly make it as close to the original algorithm as possible!