- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
is there a way in Intel FPGA OpenCL to get the wall clock time (in clock cycles) directly on the device?
This could be useful, for example, to profile the occurrence of certain events.
Thanks
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi ,
You can use the OpenCL profiling to get the delay information.
Please see the below link for the reference.
Thanks and Regards
Anil
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Anil,
thanks for your reply.
As far as I know, OpenCL profiling events can be used to get timings at the "kernel level" (e.g. the entire kernel execution time).
Instead, I was wondering if there is a way directly on device to get timing information (e.g. the number of clock cycles that passes between two events).
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi ,
It turns out that Intel® VTune™ Profiler can be used to measure the wall time for events as you have mentioned.
Please see the link below for more information about VTune profiler.
https://software.intel.com/content/www/us/en/develop/tools/vtune-profiler.html
Thanks and Regards
Anil
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Dear Anil,
thanks for your reply, but it doesn't seem that Vtune can do what I was asking for.
It seems that with vtune I can profile CPU/FPGA interaction (preview feature), similar to what I can do with OpenCL events.
I was asking if there is the possibility to count clock cycles (or any other time units) directly on the device, pretty much like one takes the clock cycles (or the wall clock time) on the CPU.
If this can be done with Vtune as well, can you please point me to the exact documentation?
Thanks for your help,
Tiziano
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi ,
You have two other options also to measure the time.
Method1:
cl_int status;
cl_ulong start, end, elapsed_time;
cl::Event myevent();
cl::CommandQueue myqueue(context, device, CL_QUEUE_PROFILING_ENABLE, &status);
myqueue.enqueue…(…, &myevent);
status = myevent.getProfilingInfo(CL_PROFILING_COMMAND_START, &start);
status = myevent.getProfilingInfo(CL_PROFILING_COMMAND_END, &end, NULL);
elapsed_time = end - start;//Time it took for the task to run in nanoseconds
Method2:
You can also use the dynamic profiler described here on this YouTube video. https://youtu.be/nyivIknJaV8?t=2437
Thanks and Regards
Anil
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Anil,
yes, I was aware of these solutions.
But none of them allow me what I wanted (measure time directly on device).
Should I assume that there is no way of obtaining the wall clock time / a clock cycle counter directly on the device?
Thanks
- Tags:
- yes
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Tiziano,
There is no support to have a clock counter on device which will read the real time information ,other than the methods suggested so far. If any such support comes in future , I will keep you updated.
Thanks and Regards
Anil
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page