-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Run test_omp_target_offload with environment var set
Pull Req. #262 * sys/scripts/run_test.sh: Add --env argument. * Makefile (%.c.run, %.c.runonly): Automatically set environment variable based on the test-case name (test_<envname>_env_<val>.c). * tests/5.0/program_control/test_omp_target_offload.c: Renamed ... tests/5.0/program_control/test_omp_target_offload_env_DEFAULT.c: to this; add 'EXPECTED_POLICY' #define and check that the env var matches. * tests/5.0/program_control/test_omp_target_offload_env_DISABLED.c: New; #define EXPECTED_POLICY and include the _DEFAULT file. * tests/5.0/program_control/test_omp_target_offload_env_MANDATORY.c: Likewise.
- Loading branch information
Showing
5 changed files
with
81 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 13 additions & 0 deletions
13
tests/5.0/program_control/test_omp_target_offload_env_DISABLED.c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
//===--- test_omp_target_offload_env_DISABLED.c ----------------------------------------------------===// | ||
// | ||
// OpenMP API Version 5.0 Nov 2018 | ||
// | ||
// This test checks for offloading behavior when OMP_TARGET_OFFLOAD is set to DISABLED. | ||
// | ||
// See test_omp_target_offload_env_DEFAULT.c for details. | ||
// | ||
////===--------------------------------------------------------------------------------------------===// | ||
|
||
#define EXPECTED_POLICY DISABLED | ||
|
||
#include "./test_omp_target_offload_env_DEFAULT.c" |
13 changes: 13 additions & 0 deletions
13
tests/5.0/program_control/test_omp_target_offload_env_MANDATORY.c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
//===--- test_omp_target_offload_env_MANDATORY.c --------------------------------------------------===// | ||
// | ||
// OpenMP API Version 5.0 Nov 2018 | ||
// | ||
// This test checks for offloading behavior when OMP_TARGET_OFFLOAD is set to MANDATORY. | ||
// | ||
// See test_omp_target_offload_env_DEFAULT.c for details. | ||
// | ||
////===--------------------------------------------------------------------------------------------===// | ||
|
||
#define EXPECTED_POLICY MANDATORY | ||
|
||
#include "test_omp_target_offload_env_DEFAULT.c" |