MCPcopy Create free account
hub / github.com/LPC4/Full-Stack / remu

Function remu

crates/virtual-machine/src/cpu/alu.rs:181–183  ·  view source on GitHub ↗

Unsigned remainder. Returns the dividend unchanged on divide-by-zero.

(a: u64, b: u64)

Source from the content-addressed store, hash-verified

179
180/// Unsigned remainder. Returns the dividend unchanged on divide-by-zero.
181pub fn remu(a: u64, b: u64) -> u64 {
182 if b == 0 { a } else { a % b }
183}
184
185// 32-bit M-extension variants, results sign-extended to 64 bits.
186

Callers 1

exec_aluFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected