Skip to content

Commit adaf194

Browse files
committed
Address extension spec comments
Signed-off-by: Larsen, Steffen <[email protected]>
1 parent e07ba71 commit adaf194

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

sycl/doc/extensions/supported/sycl_ext_oneapi_weak_object.asciidoc

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ https://github.com/intel/llvm/issues
3636

3737
== Dependencies
3838

39-
This extension is written against the SYCL 2020 revision 5 specification. All
39+
This extension is written against the SYCL 2020 revision 6 specification. All
4040
references below to the "core SYCL specification" or to section numbers in the
4141
SYCL specification refer to that revision.
4242

@@ -58,9 +58,9 @@ object alive.
5858
This extension adds the notion of a "weak" SYCL object, represented by the
5959
`weak_object` class. A weak object holds a reference to a SYCL object with
6060
common reference semantics of the specified type but will not keep the
61-
underlying object alive. As such, a weak object can be queries about having
62-
expired and exposes interfaces for locking the underlying object, creating a
63-
copy of it if it is still alive.
61+
underlying object alive. A weak object is considered expired if the underlying
62+
object is no longer alive. If a weak object has not expired, a copy of the
63+
underlying object can be created by calling either `lock` or `try_lock`.
6464

6565
Additionally this extension adds the notion of owner-based ordering to allow for
6666
use of SYCL object and their weak variants in order-oriented data structures and
@@ -141,7 +141,7 @@ a|
141141
constexpr weak_object() noexcept;
142142
----
143143

144-
| Constructor for creating an empty `weak_object`. These are
144+
| Constructor for creating an empty `weak_object`.
145145

146146
a|
147147
[source,c++]
@@ -193,7 +193,7 @@ a|
193193
void swap(weak_object &Other) noexcept;
194194
----
195195

196-
| Exhanges the reference to the underlying SYCL object with the one held by
196+
| Exchanges the reference to the underlying SYCL object with the one held by
197197
`Other`.
198198

199199
a|
@@ -217,13 +217,13 @@ std::optional<SyclObject> try_lock() const noexcept;
217217
a|
218218
[source,c++]
219219
----
220-
SyclObject lock() const noexcept;
220+
SyclObject lock() const;
221221
----
222222

223223
| Returns the underlying SYCL object.
224224

225-
Throws an exception with the `errc::invalid` error code if `std::nullopt` if the
226-
`weak_object` is empty or if `expired()` returns `true`.
225+
Throws an exception with the `errc::invalid` error code if the `weak_object` is
226+
empty or if `expired()` returns `true`.
227227

228228
a|
229229
[source,c++]

0 commit comments

Comments
 (0)