Intel® Quartus® Prime Software
Intel® Quartus® Prime Design Software, Design Entry, Synthesis, Simulation, Verification, Timing Analysis, System Design (Platform Designer, formerly Qsys)

Optimized MOD function?

Altera_Forum
Honored Contributor II
1,288 Views

Hi - I know I can use a divider to do a MOD function, but the latency of the dividers I'm familiar with is 1b/tick, and I'd like something faster. Has anyone written any optimized RTL for doing a MOD function? Thanks /j (Verilog or VHDL is fine).

0 Kudos
2 Replies
Altera_Forum
Honored Contributor II
365 Views

The divider core is probably as optimised as you'll get. 

Why do you need "faster"? Just set the divider core pipeline to less clocks.
0 Kudos
Altera_Forum
Honored Contributor II
365 Views

I'm interested in latency, not throughput. As it turns out, you can do a parallel Mod function (order log(n) rather than order n) with some clever comparison logic. 

best 

/j
0 Kudos
Reply