private static ByteSlice doDecompressIndexedStr(ByteSlice cmpData, int itemSize) {
        if (itemSize == 0) {
            return ByteSlice.empty();
        }
        long native_p = BhcompressLibrary.INSTANCE.JavaDecompress_IndexedString_NP(cmpData.address(), itemSize);
        if (native_p == 0) {
            throw new RuntimeException("decompress string err, check the std output for error code");
        }
        int str_total_len = MemoryUtil.getInt(native_p);
        return ByteSlice.fromAddress(native_p, 4 + (itemSize << 3) + str_total_len, true);
    }
Wrapper of brighthouse compression.
This class is closely linked to cpp code and native data structure, don't touch it unless you know what you are doing.

Note that all values here are in unsigned form, including max_val.
indexr-segment/src/main/java/io/indexr/compress/bh/BHCompressor.java