Skip to content

Commit c83e363

Browse files
Weiming Zhaoweimingzha0
Weiming Zhao
authored andcommitted
ODLA: update odla_LoadExecutable interface
1 parent d32cacc commit c83e363

File tree

5 files changed

+248
-216
lines changed

5 files changed

+248
-216
lines changed

ODLA/include/ODLA/odla_compute.h

+6-23
Original file line numberDiff line numberDiff line change
@@ -123,8 +123,9 @@ odla_CreateComputation(odla_computation* computation);
123123
124124
\return odla_status
125125
*/
126-
extern ODLA_API_EXPORT odla_status ODLA_API_CALL odla_CompileComputation(
127-
const odla_computation computation, odla_executable* executable);
126+
extern ODLA_API_EXPORT odla_status ODLA_API_CALL
127+
odla_CompileComputation(const odla_computation computation,
128+
const odla_device device, odla_executable* executable);
128129

129130
//! \brief Load a computation from the file system
130131
/*!
@@ -135,7 +136,6 @@ extern ODLA_API_EXPORT odla_status ODLA_API_CALL odla_CompileComputation(
135136
*/
136137
extern ODLA_API_EXPORT odla_status ODLA_API_CALL odla_LoadComputation(
137138
odla_resource_location location, odla_computation* computation);
138-
139139
//! \brief Store a computation object into the file system
140140
/*!
141141
\param location the location of the computation file
@@ -320,17 +320,6 @@ extern ODLA_API_EXPORT odla_status ODLA_API_CALL odla_StoreConstantsArray(
320320
extern ODLA_API_EXPORT odla_status ODLA_API_CALL
321321
odla_DestroyConstantsArray(odla_constants_array constants_array);
322322

323-
//! \brief Create an executable object
324-
/*!
325-
\param executable the pointer to the created executable object
326-
\param context the pointer to the loaded context object
327-
\param computation the pointer to the loaded computation object
328-
\return odla_status
329-
*/
330-
extern ODLA_API_EXPORT odla_status ODLA_API_CALL
331-
odla_CreateExecutable(odla_executable* executable, odla_context context,
332-
odla_computation computation);
333-
334323
//! \brief Load an executable from the file system
335324
/*!
336325
\param file_name the file name
@@ -342,8 +331,7 @@ odla_CreateExecutable(odla_executable* executable, odla_context context,
342331
*/
343332
extern ODLA_API_EXPORT odla_status ODLA_API_CALL
344333
odla_LoadExecutable(odla_resource_location location, odla_device device,
345-
odla_executable* executable, odla_context* context,
346-
odla_computation* computation);
334+
odla_executable* executable);
347335

348336
//! \brief Store an executable object into the file system
349337
/*!
@@ -358,17 +346,12 @@ odla_StoreExecutable(odla_resource_location, odla_executable executable);
358346
//! \brief Launch an executable
359347
/*!
360348
\param executable the executable object
361-
\param constants_array the constants array object (can be NULL)
362349
\param context the context object
363-
\param mode the compute mode
364-
\param device the device object
365350
366351
\return odla_status
367352
*/
368-
extern ODLA_API_EXPORT odla_status ODLA_API_CALL odla_LaunchExecutable(
369-
const odla_executable executable,
370-
const odla_constants_array constants_array, const odla_context context,
371-
const odla_compute_mode mode, odla_device device);
353+
extern ODLA_API_EXPORT odla_status ODLA_API_CALL
354+
odla_LaunchExecutable(odla_executable executable, odla_context context);
372355

373356
//! \brief Asynchronously launch an executable
374357
/*!

0 commit comments

Comments
 (0)