@@ -58,7 +58,10 @@ def evaluate_bool_env(env):
58
58
config .name = 'libomptarget :: ' + config .libomptarget_current_target
59
59
60
60
# suffixes: A list of file extensions to treat as test files.
61
- config .suffixes = ['.c' , '.cpp' , '.cc' ]
61
+ config .suffixes = ['.c' , '.cpp' , '.cc' , '.f90' ]
62
+
63
+ # excludes: A list of directories to exclude from the testuites.
64
+ config .excludes = ['Inputs' ]
62
65
63
66
# test_source_root: The root path where tests are located.
64
67
config .test_source_root = os .path .dirname (__file__ )
@@ -162,6 +165,8 @@ for libomptarget_target in config.libomptarget_all_targets:
162
165
"%libomptarget-compilexx-run-and-check-" + libomptarget_target ))
163
166
config .substitutions .append (("%libomptarget-compile-run-and-check-generic" ,
164
167
"%libomptarget-compile-run-and-check-" + libomptarget_target ))
168
+ config .substitutions .append (("%libomptarget-compile-fortran-run-and-check-generic" ,
169
+ "%libomptarget-compile-fortran-run-and-check-" + libomptarget_target ))
165
170
config .substitutions .append (("%libomptarget-compilexx-and-run-generic" ,
166
171
"%libomptarget-compilexx-and-run-" + libomptarget_target ))
167
172
config .substitutions .append (("%libomptarget-compile-and-run-generic" ,
@@ -170,6 +175,8 @@ for libomptarget_target in config.libomptarget_all_targets:
170
175
"%libomptarget-compilexx-" + libomptarget_target ))
171
176
config .substitutions .append (("%libomptarget-compile-generic" ,
172
177
"%libomptarget-compile-" + libomptarget_target ))
178
+ config .substitutions .append (("%libomptarget-compile-fortran-generic" ,
179
+ "%libomptarget-compile-fortran-" + libomptarget_target ))
173
180
config .substitutions .append (("%libomptarget-compileoptxx-run-and-check-generic" ,
174
181
"%libomptarget-compileoptxx-run-and-check-" + libomptarget_target ))
175
182
config .substitutions .append (("%libomptarget-compileopt-run-and-check-generic" ,
@@ -204,6 +211,10 @@ for libomptarget_target in config.libomptarget_all_targets:
204
211
libomptarget_target , \
205
212
"%libomptarget-compile-and-run-" + libomptarget_target + \
206
213
" | " + config .libomptarget_filecheck + " %s" ))
214
+ config .substitutions .append (("%libomptarget-compile-fortran-run-and-check-" + \
215
+ libomptarget_target , \
216
+ "%libomptarget-compile-fortran-and-run-" + libomptarget_target + \
217
+ " | " + config .libomptarget_filecheck + " %s" ))
207
218
config .substitutions .append (("%libomptarget-compilexx-and-run-" + \
208
219
libomptarget_target , \
209
220
"%libomptarget-compilexx-" + libomptarget_target + " && " + \
@@ -212,6 +223,10 @@ for libomptarget_target in config.libomptarget_all_targets:
212
223
libomptarget_target , \
213
224
"%libomptarget-compile-" + libomptarget_target + " && " + \
214
225
"%libomptarget-run-" + libomptarget_target ))
226
+ config .substitutions .append (("%libomptarget-compile-fortran-and-run-" + \
227
+ libomptarget_target , \
228
+ "%libomptarget-compile-fortran-" + libomptarget_target + " && " + \
229
+ "%libomptarget-run-" + libomptarget_target ))
215
230
config .substitutions .append (("%libomptarget-compilexx-" + \
216
231
libomptarget_target , \
217
232
"%clangxx-" + libomptarget_target + " %s -o %t" + \
@@ -220,6 +235,9 @@ for libomptarget_target in config.libomptarget_all_targets:
220
235
libomptarget_target , \
221
236
"%clang-" + libomptarget_target + " %s -o %t" +
222
237
(" -lcgpu" if config .libomptarget_has_libc else "" )))
238
+ config .substitutions .append (("%libomptarget-compile-fortran-" + \
239
+ libomptarget_target , \
240
+ "%flang-" + libomptarget_target + " %s -o %t" ))
223
241
config .substitutions .append (("%libomptarget-compileoptxx-run-and-check-" + \
224
242
libomptarget_target , \
225
243
"%libomptarget-compileoptxx-and-run-" + libomptarget_target + \
@@ -256,18 +274,27 @@ for libomptarget_target in config.libomptarget_all_targets:
256
274
config .substitutions .append (("%clang-" + libomptarget_target , \
257
275
"%clang %openmp_flags %cuda_flags %flags -fopenmp-targets=" + \
258
276
remove_suffix_if_present (libomptarget_target )))
277
+ config .substitutions .append (("%flang-" + libomptarget_target , \
278
+ "%flang %openmp_flags %flags -fopenmp-targets=" + \
279
+ remove_suffix_if_present (libomptarget_target )))
259
280
config .substitutions .append (("%fcheck-" + libomptarget_target , \
260
281
config .libomptarget_filecheck + " %s" ))
261
282
else :
262
283
config .substitutions .append (("%libomptarget-compile-run-and-check-" + \
263
284
libomptarget_target , \
264
285
"echo ignored-command" ))
286
+ config .substitutions .append (("%libomptarget-compile-fortran-run-and-check-" + \
287
+ libomptarget_target , \
288
+ "echo ignored-command" ))
265
289
config .substitutions .append (("%libomptarget-compilexx-run-and-check-" + \
266
290
libomptarget_target , \
267
291
"echo ignored-command" ))
268
292
config .substitutions .append (("%libomptarget-compile-and-run-" + \
269
293
libomptarget_target , \
270
294
"echo ignored-command" ))
295
+ config .substitutions .append (("%libomptarget-compile-fortran-and-run-" + \
296
+ libomptarget_target , \
297
+ "echo ignored-command" ))
271
298
config .substitutions .append (("%libomptarget-compilexx-and-run-" + \
272
299
libomptarget_target , \
273
300
"echo ignored-command" ))
@@ -277,6 +304,9 @@ for libomptarget_target in config.libomptarget_all_targets:
277
304
config .substitutions .append (("%libomptarget-compile-" + \
278
305
libomptarget_target , \
279
306
"echo ignored-command" ))
307
+ config .substitutions .append (("%libomptarget-compile-fortran-" + \
308
+ libomptarget_target , \
309
+ "echo ignored-command" ))
280
310
config .substitutions .append (("%libomptarget-compileopt-run-and-check-" + \
281
311
libomptarget_target , \
282
312
"echo ignored-command" ))
@@ -307,6 +337,8 @@ for libomptarget_target in config.libomptarget_all_targets:
307
337
"echo ignored-command" ))
308
338
config .substitutions .append (("%fcheck-" + libomptarget_target , \
309
339
"echo ignored-command" ))
340
+ config .substitutions .append (("%flang-" + libomptarget_target , \
341
+ "echo ignored-command" ))
310
342
311
343
config .substitutions .append (("%clangxx" , config .test_cxx_compiler ))
312
344
config .substitutions .append (("%clang" , config .test_c_compiler ))
0 commit comments