presto-orc/src/main/java/io/prestosql/orc/stream/LongOutputStreamV2.java/SerializationUtils/encodeBitWidth
class SerializationUtils:        static int encodeBitWidth(int n)
        {
            n = getClosestFixedBits(n);

            if (n >= 1 && n <= 24) {
                return n - 1;
            }
            else if (n > 24 && n <= 26) {
                return FixedBitSizes.TWENTY_SIX.ordinal();
            }
            else if (n > 26 && n <= 28) {
                return FixedBitSizes.TWENTY_EIGHT.ordinal();
            }
            else if (n > 28 && n <= 30) {
                return FixedBitSizes.THIRTY.ordinal();
            }
            else if (n > 30 && n <= 32) {
                return FixedBitSizes.THIRTY_TWO.ordinal();
            }
            else if (n > 32 && n <= 40) {
                return FixedBitSizes.FORTY.ordinal();
            }
            else if (n > 40 && n <= 48) {
                return FixedBitSizes.FORTY_EIGHT.ordinal();
            }
            else if (n > 48 && n <= 56) {
                return FixedBitSizes.FIFTY_SIX.ordinal();
            }
            else {
                return FixedBitSizes.SIXTY_FOUR.ordinal();
            }
        }