NVIDIA/nvcomp

[QST] Running a benchmark on multiple GPUs

AndreiArdei opened this issue · 6 comments

My intention is to run a benchmark using multiple GPUs. In my case, I have 4xA4000 cards. If I run any of the benchmarks, they will use only one video card at a time instead of splitting the load over multiple cards. the -g setting of the benchmarks only allows me to select which GPU to be run on. So the question is :

Is it possible to split the load of a benchmark over multiple GPUs at the same time? If yes, how?

This issue has been labeled inactive-30d due to no recent activity in the past 30 days. Please close this issue if no further response or action is needed. Otherwise, please respond with a comment indicating any updates or changes to the original issue and/or confirm this issue still needs to be addressed. This issue will be labeled inactive-90d if there is no activity in the next 60 days.

This issue has been labeled inactive-90d due to no recent activity in the past 90 days. Please close this issue if no further response or action is needed. Otherwise, please respond with a comment indicating any updates or changes to the original issue and/or confirm this issue still needs to be addressed.

The current benchmark programs are single-GPU, though as you mention, you can specify which GPU. The call that sets the GPU that's used by the low-level benchmarks is cudaSetDevice here: https://github.com/NVIDIA/nvcomp/blob/main/benchmarks/benchmark_template_chunked.cuh#L811 A good way to run nvcomp on multiple GPUs is to create a host thread corresponding with each GPU, and inside each of those host threads, call cudaSetDevice(device_number); so that when each thread launches nvcomp kernels, they will run on the specified device.

I might look into adding multi-GPU support to some benchmarks or a separate example, since although it's independent of nvcomp itself, it could still be useful for benchmarking nvcomp and for a multi-GPU example for people using nvcomp.

This issue has been labeled inactive-30d due to no recent activity in the past 30 days. Please close this issue if no further response or action is needed. Otherwise, please respond with a comment indicating any updates or changes to the original issue and/or confirm this issue still needs to be addressed. This issue will be labeled inactive-90d if there is no activity in the next 60 days.

This issue has been labeled inactive-90d due to no recent activity in the past 90 days. Please close this issue if no further response or action is needed. Otherwise, please respond with a comment indicating any updates or changes to the original issue and/or confirm this issue still needs to be addressed.