Stream: compiler development

Topic: bit shifts for `Dec` perf


view this post on Zulip Richard Feldman (Sep 16 2023 at 00:54):

looking at the benchmarks in https://github.com/roc-lang/roc/pull/5810, I wonder if bit shifts could be used on Dec for faster division if you happen to want to divide by a power of 2?

view this post on Zulip Richard Feldman (Sep 16 2023 at 00:55):

like assume someday we had a compiler optimization for that...would it work? I don't even know!

view this post on Zulip Brendan Hansknecht (Sep 16 2023 at 01:34):

Yeah, it would work


Last updated: Jul 06 2025 at 12:14 UTC