Crc.s32.bits: def of bend-osdev-crc@0.1.0.0 Import: import bend-osdev-crc@0.1.0.0/crc.bend as Crc Lines 107-113 of bend-osdev-crc@0.1.0.0/crc.bend: https://jend.leeeet.dev/read.txt?path=bend-osdev-crc@0.1.0.0/crc.bend&start_line=107&end_line=113 import Base # the bits p - 1 down to 0 of h, into register c def s32.bits(+n: Nat, +poly: U32, +topsh: Nat, +mask: U32, +h: U32, +c: U32) -> U32: match n: case 0n: c case 1n+p: s32.bits(p, poly, topsh, mask, h, s32.pick(U32.is_eq(U32.and(U32.xor(U32.shrn(c, topsh), U32.shrn(h, p)), 1), 1), poly, mask, c)) Uses (7): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.and https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.is_eq https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.shrn https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.xor https://jend.leeeet.dev/definition.txt?path=bend-osdev-crc@0.1.0.0/crc.bend&name=s32.pick