Lines Matching refs:v
90 for v in variants:
92 print_header(v, f'Slice-by-{n} CRC table')
98 poly = (bitreflect(i % 256, 8) if v.lsb else i % 256) << (v.bits + 8*(i//256))
99 next_entry = fmt_poly(v, reduce(poly, v.G), v.bits) + ','
108 def print_riscv_const(v, bits_per_long, name, val, desc): argument
111 def do_gen_riscv_clmul_consts(v, bits_per_long): argument
112 (G, n, lsb) = (v.G, v.bits, v.lsb)
115 print_riscv_const(v, bits_per_long, 'fold_across_2_longs_const_hi',
118 print_riscv_const(v, bits_per_long, 'fold_across_2_longs_const_lo',
122 print_riscv_const(v, bits_per_long, 'barrett_reduction_const_1',
130 print_riscv_const(v, bits_per_long, 'barrett_reduction_const_2', val, desc)
140 for v in variants:
142 if v.bits > 32:
143 print_header(v, 'Constants')
146 do_gen_riscv_clmul_consts(v, 64)
150 print_header(v, 'Constants')
153 do_gen_riscv_clmul_consts(v, 64)
155 do_gen_riscv_clmul_consts(v, 32)
164 for v in variants:
165 (G, n, lsb) = (v.G, v.bits, v.lsb)
167 print_header(v, 'CRC folding constants')
214 print_mult_pair(v, mults)
247 print_mult_pair(v, mults)