Skip to content

Commit 5cf8088

Browse files
authored
Added the SYCL_INTEL_mem_channel_property extension specification (#2688)
* First public version of SYCL_INTEL_mem_channel_property This extension adds a new buffer property that will be useful for some FPGA targets. * Fixed date
1 parent 68ab67a commit 5cf8088

File tree

1 file changed

+110
-0
lines changed

1 file changed

+110
-0
lines changed
Lines changed: 110 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,110 @@
1+
= SYCL_INTEL_mem_channel_property
2+
3+
== Introduction
4+
NOTE: Khronos(R) is a registered trademark and SYCL(TM) and SPIR(TM) are trademarks of The Khronos Group Inc. OpenCL(TM) is a trademark of Apple Inc. used by permission by Khronos.
5+
6+
This document describes an extension that adds a property to SYCL to indicate in what region of memory a buffer should be allocated.
7+
8+
== Contributors
9+
Joe Garvey, Intel
10+
11+
== Notice
12+
13+
Copyright (c) 2020 Intel Corporation. All rights reserved.
14+
15+
== Status
16+
17+
Working Draft
18+
19+
This is a preview extension specification, intended to provide early access to a feature for review and community feedback. When the feature matures, this specification may be released as a formal extension.
20+
21+
Because the interfaces defined by this specification are not final and are subject to change they are not intended to be used by shipping software products.
22+
23+
== Version
24+
25+
Built On: {docdate} +
26+
Revision: 1
27+
28+
== Dependencies
29+
30+
This extension is written against the SYCL 2020 provisional specification, Revision 1.
31+
32+
The use of this extension requires a target that supports cl_intel_mem_channel_property or equivalent if OpenCL is used as the underlying device runtime.
33+
34+
== Overview
35+
36+
On some targets manual assignment of buffers to memory regions can improve memory bandwidth. This extension adds a buffer property to indicate in which memory channel a particular buffer should be allocated. This information is an optimization hint to the runtime and thus it is legal to ignore.
37+
38+
== Modifications to the SYCL Specification, Version 2020 provisional revision 1
39+
40+
=== Section 4.7.2.2 Buffer properties
41+
42+
Add a new property to Table 4.33: Properties supported by the SYCL buffer class as follows:
43+
44+
--
45+
[options="header"]
46+
|===
47+
| Property | Description
48+
| property::buffer::mem_channel | The `mem_channel` property is a hint to the SYCL runtime that the buffer should be stored in a particular memory channel provided to the property.
49+
|===
50+
--
51+
52+
Add a new constructor to Table 4.34: Constructors of the buffer property classes as follows:
53+
54+
--
55+
[options="header"]
56+
|===
57+
| Constructor | Description
58+
| property::buffer::mem_channel::mem_channel(cl_uint channel) | Constructs a SYCL `mem_channel` property instance with the specified channel ID. The range of valid values depends on the target and is implementation defined. Invalid values do not need to result in an error as the property is only a hint.
59+
|===
60+
--
61+
62+
Add a new member function to Table 4.35: Member functions of the buffer property classes as follows:
63+
64+
--
65+
[options="header"]
66+
|===
67+
| Member function | Description
68+
| cl_uint property::buffer::mem_channel::get_channel() const | Returns the cl_uint which was specified when constructing this SYCL `mem_channel` property.
69+
|===
70+
--
71+
72+
=== Section 4.6.4.3 Device aspects
73+
74+
Add a new ext_intel_mem_channel aspect to the aspect enum:
75+
76+
```c++
77+
namespace sycl {
78+
79+
enum class aspect {
80+
host,
81+
cpu,
82+
...
83+
usm_system_allocator,
84+
ext_intel_mem_channel
85+
};
86+
87+
} // namespace sycl
88+
```
89+
90+
Add an entry for the new aspect to Table 4.20: Device aspects defined by the core SYCL specification:
91+
92+
--
93+
[options="header"]
94+
|===
95+
| Aspect | Description
96+
| aspect::ext_intel_mem_channel | Indicates that the device supports the mem_channel buffer property
97+
|===
98+
--
99+
100+
== Issues
101+
102+
== Revision History
103+
104+
[cols="5,15,15,70"]
105+
[grid="rows"]
106+
[options="header"]
107+
|========================================
108+
|Rev|Date|Author|Changes
109+
|1|2020-10-26|Joe Garvey|*Initial public draft*
110+
|========================================

0 commit comments

Comments
 (0)