initial huffman tree contruction support