Skip to content

Queue has enable profiling - #531

Merged
oleksandr-pavlyk merged 3 commits into
masterfrom
queue-has-enable-profiling
Aug 18, 2021
Merged

oleksandr-pavlyk merged 3 commits into
masterfrom
queue-has-enable-profiling

Conversation

@oleksandr-pavlyk

@oleksandr-pavlyk oleksandr-pavlyk commented Aug 17, 2021 •

Copy link
Copy Markdown
Contributor

C-API function DPCTLQueue_HasEnableProfiling(QRef) that returns true if QRef references a sycl::queue that was created to have property sycl::property::queue::enable_profiling.

dpctl.SyclQueue acquired property dpctl.SyclQueue.has_enable_profiling.

This was used in dpctl.SyclQueue.__repr__ to echo properties of the queue instance.

This calls sycl::queue::has_property<sycl::property::queue::enable_profiling>()
Queries whether queue was constructed with said property.
If so, events from tasks submitted to this queue will have profiling info
@coveralls

coveralls commented Aug 17, 2021 •

Copy link
Copy Markdown
Collaborator

Coverage Status

Coverage increased (+0.02%) to 64.914% when pulling ad31122 on queue-has-enable-profiling into 8a55469 on master.

```
In [1]: import dpctl

In [2]: dpctl.SyclQueue()
Out[2]: <dpctl.SyclQueue at 0x7f8752c07b90>

In [3]: dpctl.SyclQueue(property='in_order')
Out[3]: <dpctl.SyclQueue at 0x7f87494f4870, property=['in_order']>

In [4]: dpctl.SyclQueue(property=['in_order'])
Out[4]: <dpctl.SyclQueue at 0x7f8753587f00, property=['in_order']>

In [5]: dpctl.SyclQueue(property=['in_order', 'enable_profiling'])
Out[5]: <dpctl.SyclQueue at 0x7f8734016eb0, property=['in_order', 'enable_profling']>
```
@oleksandr-pavlyk
oleksandr-pavlyk merged commit 82ac451 into master Aug 18, 2021
@oleksandr-pavlyk
oleksandr-pavlyk deleted the queue-has-enable-profiling branch August 18, 2021 00:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants