mirror of
https://github.com/boostorg/compute.git
synced 2026-01-28 19:12:15 +00:00
This cleans up the constructor methods for the OpenCL wrapper classes and unifies the API used for creating a wrapper class object from the underlying OpenCL objects. Now, every wrapper class has a constructor taking the OpenCL object and an optional boolean retain parameter which indicates whether the constructor should increment the reference count.
134 lines
3.7 KiB
XML
134 lines
3.7 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<header name="boost/compute/event.hpp">
|
|
<namespace name="boost">
|
|
<namespace name="compute">
|
|
|
|
<!-- boost::compute::event -->
|
|
<class name="event">
|
|
<purpose>An event</purpose>
|
|
|
|
<description>
|
|
<para>
|
|
The <code>event</code> class represents an OpenCL event.
|
|
</para>
|
|
</description>
|
|
|
|
<!-- event::event(cl_event) -->
|
|
<constructor specifiers="explicit">
|
|
<parameter name="event">
|
|
<paramtype>cl_event</paramtype>
|
|
</parameter>
|
|
|
|
<description>
|
|
<para>
|
|
Creates a new compute event for <code>event</code>.
|
|
</para>
|
|
</description>
|
|
</constructor>
|
|
|
|
<!-- event::event(other) -->
|
|
<constructor>
|
|
<parameter name="other">
|
|
<paramtype>const <classname>event</classname> &</paramtype>
|
|
</parameter>
|
|
|
|
<description>
|
|
<para>
|
|
Creates a new event object as a copy of <code>other</code>.
|
|
</para>
|
|
</description>
|
|
</constructor>
|
|
|
|
<!-- event::event(cl_event, bool) -->
|
|
<constructor specifiers="explicit">
|
|
<parameter name="event">
|
|
<paramtype>cl_event</paramtype>
|
|
</parameter>
|
|
<parameter name="retain">
|
|
<paramtype>bool</paramtype>
|
|
<default>true</default>
|
|
</parameter>
|
|
|
|
<description>
|
|
<para>
|
|
Creates a new event object for <code>event</code>. If
|
|
<code>retain</code> is <code>true</code> (the default) the
|
|
reference count for <code>event</code> will be incremented.
|
|
</para>
|
|
</description>
|
|
</constructor>
|
|
|
|
<!-- operator=(other) -->
|
|
<copy-assignment>
|
|
<parameter name="other">
|
|
<paramtype>const <classname>event</classname> &</paramtype>
|
|
</parameter>
|
|
|
|
<description>
|
|
<para>
|
|
Copies the event from <code>other</code>.
|
|
</para>
|
|
</description>
|
|
</copy-assignment>
|
|
|
|
<!-- event::~event() -->
|
|
<destructor>
|
|
<description>
|
|
<para>
|
|
Destroys the event object.
|
|
</para>
|
|
</description>
|
|
</destructor>
|
|
|
|
<method-group name="public member functions">
|
|
|
|
<!-- event::get_info<T>(info) -->
|
|
<method name="get_info" cv="const">
|
|
<template>
|
|
<template-type-parameter name="T"/>
|
|
</template>
|
|
|
|
<type>T</type>
|
|
|
|
<parameter name="info">
|
|
<paramtype>cl_event_info</paramtype>
|
|
</parameter>
|
|
|
|
<description>
|
|
<para>
|
|
Returns information about the event.
|
|
</para>
|
|
</description>
|
|
</method>
|
|
|
|
<!-- event::get_profiling_info<T>(info) -->
|
|
<method name="get_profiling_info" cv="const">
|
|
<template>
|
|
<template-type-parameter name="T"/>
|
|
</template>
|
|
|
|
<type>T</type>
|
|
|
|
<parameter name="info">
|
|
<paramtype>cl_profiling_info</paramtype>
|
|
</parameter>
|
|
|
|
<description>
|
|
<para>
|
|
Returns profiling information for the event.
|
|
</para>
|
|
<para>
|
|
For example, to get the time when the command referred to by
|
|
the event was completed:
|
|
<programlisting>
|
|
cl_ulong end_time = e.get_profiling_info<cl_ulong>(event::profiling_command_end);
|
|
</programlisting>
|
|
</para>
|
|
</description>
|
|
</method>
|
|
</method-group>
|
|
</class>
|
|
</namespace>
|
|
</namespace>
|
|
</header>
|