Skip to content

Commit 45395cf

Browse files
committed
Update core program.yml
1 parent 532a4ec commit 45395cf

File tree

1 file changed

+17
-14
lines changed

1 file changed

+17
-14
lines changed

scripts/core/program.yml

Lines changed: 17 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ returns:
119119
- "`length == 0`"
120120
--- #--------------------------------------------------------------------------
121121
type: function
122-
desc: "Create a program object from device native binary."
122+
desc: "Create a program object from native binaries for the specified devices."
123123
class: $xProgram
124124
name: CreateWithBinary
125125
decl: static
@@ -128,22 +128,25 @@ analogue:
128128
- "**clCreateProgramWithBinary**"
129129
details:
130130
- "The application may call this function from simultaneous threads."
131-
- "Following a successful call to this entry point, `phProgram` will contain a binary of type $X_PROGRAM_BINARY_TYPE_COMPILED_OBJECT or $X_PROGRAM_BINARY_TYPE_LIBRARY for `hDevice`."
132-
- "The device specified by `hDevice` must be device associated with context."
133-
- "The adapter may (but is not required to) perform validation of the provided module during this call."
131+
- "Following a successful call to this entry point, `phProgram` will contain binaries of type $X_PROGRAM_BINARY_TYPE_COMPILED_OBJECT or $X_PROGRAM_BINARY_TYPE_LIBRARY for the specified devices in `phDevices`."
132+
- "The devices specified by `phDevices` must be associated with the context."
133+
- "The adapter may (but is not required to) perform validation of the provided modules during this call."
134134
params:
135135
- type: $x_context_handle_t
136136
name: hContext
137137
desc: "[in] handle of the context instance"
138-
- type: $x_device_handle_t
139-
name: hDevice
140-
desc: "[in] handle to device associated with binary."
141-
- type: size_t
142-
name: size
143-
desc: "[in] size in bytes."
144-
- type: const uint8_t*
145-
name: pBinary
146-
desc: "[in] pointer to binary."
138+
- type: uint32_t
139+
name: numDevices
140+
desc: "[in] number of devices"
141+
- type: $x_device_handle_t*
142+
name: phDevices
143+
desc: "[in][range(0, numDevices)] a pointer to a list of device handles. The binaries are loaded for devices specified in this list."
144+
- type: size_t*
145+
name: pLengths
146+
desc: "[in][range(0, numDevices)] array of sizes of program binaries specified by `pBinaries` (in bytes)."
147+
- type: const uint8_t**
148+
name: ppBinaries
149+
desc: "[in][range(0, numDevices)] pointer to program binaries to be loaded for devices specified by `phDevices`."
147150
- type: const $x_program_properties_t*
148151
name: pProperties
149152
desc: "[in][optional] pointer to program creation properties."
@@ -156,7 +159,7 @@ returns:
156159
- $X_RESULT_ERROR_INVALID_SIZE:
157160
- "`NULL != pProperties && NULL != pProperties->pMetadatas && pProperties->count == 0`"
158161
- $X_RESULT_ERROR_INVALID_NATIVE_BINARY:
159-
- "If `pBinary` isn't a valid binary for `hDevice.`"
162+
- "If any binary in `ppBinaries` isn't a valid binary for the corresponding device in `phDevices.`"
160163
--- #--------------------------------------------------------------------------
161164
type: function
162165
desc: "Produces an executable program from one program, negates need for the linking step."

0 commit comments

Comments
 (0)