package bfloat16 file_number 0 "/inputs/subtree/xls/dslx/stdlib/std.x" file_number 1 "/inputs/subtree/xls/dslx/stdlib/apfloat.x" file_number 2 "/inputs/subtree/xls/dslx/stdlib/bfloat16.x" top fn __bfloat16__from_uint8(x: bits[8] id=16) -> (bits[1], bits[8], bits[7]) { reverse.20: bits[8] = reverse(x, id=20, pos=[(2,383,16)]) one_hot.21: bits[9] = one_hot(reverse.20, lsb_prio=true, id=21, pos=[(2,383,16)]) lz: bits[4] = encode(one_hot.21, id=22, pos=[(2,383,16)]) bit_slice.87: bits[3] = bit_slice(lz, start=0, width=3, id=87, pos=[(2,387,14)]) literal.25: bits[4] = literal(value=1, id=25, pos=[(2,385,31)]) literal.53: bits[4] = literal(value=0, id=53) bit_slice.85: bits[1] = bit_slice(lz, start=3, width=1, id=85, pos=[(2,387,14)]) not.88: bits[3] = not(bit_slice.87, id=88, pos=[(2,387,14)]) literal.35: bits[8] = literal(value=0, id=35, pos=[(2,394,12)]) add.26: bits[4] = add(lz, literal.25, id=26, pos=[(2,385,26)]) concat.92: bits[8] = concat(literal.53, bit_slice.85, not.88, id=92) BIAS: bits[8] = literal(value=127, id=49) ne.90: bits[1] = ne(x, literal.35, id=90, pos=[(2,394,4)]) shll.27: bits[8] = shll(x, add.26, id=27, pos=[(2,385,20)]) bexp: bits[8] = add(concat.92, BIAS, id=32, pos=[(2,388,15)]) sign_ext.79: bits[8] = sign_ext(ne.90, new_bit_count=8, id=79, pos=[(2,394,4)]) fraction: bits[7] = bit_slice(shll.27, start=1, width=7, id=68, pos=[(2,385,37)]) sign_ext.82: bits[7] = sign_ext(ne.90, new_bit_count=7, id=82, pos=[(2,394,4)]) sign: bits[1] = literal(value=0, id=33, pos=[(2,390,15)]) and.80: bits[8] = and(bexp, sign_ext.79, id=80, pos=[(2,394,4)]) and.83: bits[7] = and(fraction, sign_ext.82, id=83, pos=[(2,394,4)]) ret tuple.64: (bits[1], bits[8], bits[7]) = tuple(sign, and.80, and.83, id=64, pos=[(2,394,4)]) }