add enumeration encoder, optimize LZ4 encoder