How do I know if the kernels are executing concurrently?

前端 未结 3 395
栀梦
栀梦 2020-12-15 14:23

I have a GPU with CC 3.0, so it should support 16 concurrent kernels. I am starting 10 kernels by looping through clEnqueueNDRangeKernel for 10 times. How do I get to know t

3条回答
  •  忘掉有多难
    2020-12-15 15:02

    You can avoid all the boilerplate code suggested in the other answers (which are correct by the way) by using C Framework for OpenCL, which simplifies this task a lot, and gives you detailed information about OpenCL events (kernel execution, data transfers, etc), including a table and a plot dedicated to overlapped execution of said events.

    I developed this library in order to, among other things, simplify the process described in the other answers. You can see a basic usage example here.

提交回复
热议问题