adam-maj / tiny-gpu

A minimal GPU design in Verilog to learn how GPUs work from the ground up
6.6k stars 491 forks source link

why total_blocks = (thread_count + THREADS_PER_BLOCK - 1) / THREADS_PER_BLOCK #29

Closed dimory closed 1 month ago

dimory commented 1 month ago

hello, thank you for sharing your excellent project. but i have a question why use (thread_count + THREADS_PER_BLOCK - 1) / THREADS_PER_BLOCK to caculate total_blocks. Best Regards.