@@ -123,7 +123,9 @@ urProgramCompile(ur_context_handle_t hContext, ur_program_handle_t hProgram,
123
123
std::ignore = hProgram;
124
124
std::ignore = pOptions;
125
125
126
- DIE_NO_IMPLEMENTATION
126
+ // Currently for Native CPU the program is offline compiled, so
127
+ // urProgramCompile is a no-op.
128
+ return UR_RESULT_SUCCESS;
127
129
}
128
130
129
131
UR_APIEXPORT ur_result_t UR_APICALL
@@ -138,21 +140,27 @@ urProgramLink(ur_context_handle_t hContext, uint32_t count,
138
140
std::ignore = phPrograms;
139
141
std::ignore = pOptions;
140
142
141
- DIE_NO_IMPLEMENTATION
143
+ // Currently for Native CPU the program is already linked and all its
144
+ // symbols are resolved, so this is a no-op.
145
+ return UR_RESULT_SUCCESS;
142
146
}
143
147
144
148
UR_APIEXPORT ur_result_t UR_APICALL urProgramCompileExp (ur_program_handle_t ,
145
149
uint32_t ,
146
150
ur_device_handle_t *,
147
151
const char *) {
148
- return UR_RESULT_ERROR_UNSUPPORTED_FEATURE;
152
+ // Currently for Native CPU the program is offline compiled, so
153
+ // urProgramCompile is a no-op.
154
+ return UR_RESULT_SUCCESS;
149
155
}
150
156
151
157
UR_APIEXPORT ur_result_t UR_APICALL urProgramBuildExp (ur_program_handle_t ,
152
158
uint32_t ,
153
159
ur_device_handle_t *,
154
160
const char *) {
155
- return UR_RESULT_ERROR_UNSUPPORTED_FEATURE;
161
+ // Currently for Native CPU the program is offline compiled and linked,
162
+ // so urProgramBuild is a no-op.
163
+ return UR_RESULT_SUCCESS;
156
164
}
157
165
158
166
UR_APIEXPORT ur_result_t UR_APICALL urProgramLinkExp (
@@ -161,7 +169,9 @@ UR_APIEXPORT ur_result_t UR_APICALL urProgramLinkExp(
161
169
if (nullptr != phProgram) {
162
170
*phProgram = nullptr ;
163
171
}
164
- return UR_RESULT_ERROR_UNSUPPORTED_FEATURE;
172
+ // Currently for Native CPU the program is already linked and all its
173
+ // symbols are resolved, so this is a no-op.
174
+ return UR_RESULT_SUCCESS;
165
175
}
166
176
167
177
UR_APIEXPORT ur_result_t UR_APICALL
0 commit comments