Lines Matching full:bit_offset
797 unsigned i, byte, bit_offset, align, shl, shr; in compile_bkey_field() local
844 bit_offset = format->key_u64s * 64; in compile_bkey_field()
846 bit_offset -= format->bits_per_field[i]; in compile_bkey_field()
848 byte = bit_offset / 8; in compile_bkey_field()
849 bit_offset -= byte * 8; in compile_bkey_field()
853 if (bit_offset == 0 && bits == 8) { in compile_bkey_field()
856 } else if (bit_offset == 0 && bits == 16) { in compile_bkey_field()
859 } else if (bit_offset + bits <= 32) { in compile_bkey_field()
860 align = min(4 - DIV_ROUND_UP(bit_offset + bits, 8), byte & 3); in compile_bkey_field()
862 bit_offset += align * 8; in compile_bkey_field()
864 BUG_ON(bit_offset + bits > 32); in compile_bkey_field()
869 if (bit_offset) { in compile_bkey_field()
871 I3(0xc1, 0xe8, bit_offset); in compile_bkey_field()
874 if (bit_offset + bits < 32) { in compile_bkey_field()
882 } else if (bit_offset + bits <= 64) { in compile_bkey_field()
883 align = min(8 - DIV_ROUND_UP(bit_offset + bits, 8), byte & 7); in compile_bkey_field()
885 bit_offset += align * 8; in compile_bkey_field()
887 BUG_ON(bit_offset + bits > 64); in compile_bkey_field()
892 shl = 64 - bit_offset - bits; in compile_bkey_field()
893 shr = bit_offset + shl; in compile_bkey_field()
905 align = min(4 - DIV_ROUND_UP(bit_offset + bits, 8), byte & 3); in compile_bkey_field()
907 bit_offset += align * 8; in compile_bkey_field()
909 BUG_ON(bit_offset + bits > 96); in compile_bkey_field()
918 shr = bit_offset + bits - 64; in compile_bkey_field()
919 BUG_ON(shr > bit_offset); in compile_bkey_field()
921 /* shr rax, bit_offset */ in compile_bkey_field()
930 shr = bit_offset - shr; in compile_bkey_field()