Ben Joffe35 min read
A faster way to compute signed 64-bit floor division by constants
What is signed integer floor division?Signed integer floor division is where you do a/b and get a result that rounds towards −∞,whereas standard (“truncated”) signed division rounds towards 0.As stated in Hacker's Delight: “[I suspect that] floor division more often gives the result you want”.
By benjoffe.com by benjoffeLobsters

Read the full story
Originally published by Lobsters on Oct 26, 2026.
Comments
Sign in to join the discussion.