diff options
author | Robert Maynard <robert.maynard@kitware.com> | 2020-08-28 19:03:39 (GMT) |
---|---|---|
committer | Zack Galbreath <zack.galbreath@kitware.com> | 2021-06-07 19:25:33 (GMT) |
commit | b50bfc89131e55685aa41146254b37d26049b4d5 (patch) | |
tree | e6ed45ba63b75decf4c9436fac6139174850370b /Tests/HIP/EnableStandard/main.hip | |
parent | ff0d2858e1e47af8e849318b411b1fbd8579a053 (diff) | |
download | CMake-b50bfc89131e55685aa41146254b37d26049b4d5.zip CMake-b50bfc89131e55685aa41146254b37d26049b4d5.tar.gz CMake-b50bfc89131e55685aa41146254b37d26049b4d5.tar.bz2 |
HIP: Add language to CMake
Diffstat (limited to 'Tests/HIP/EnableStandard/main.hip')
-rw-r--r-- | Tests/HIP/EnableStandard/main.hip | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/Tests/HIP/EnableStandard/main.hip b/Tests/HIP/EnableStandard/main.hip new file mode 100644 index 0000000..7dc32e8 --- /dev/null +++ b/Tests/HIP/EnableStandard/main.hip @@ -0,0 +1,23 @@ + +#include <iostream> + +#ifdef _WIN32 +# define IMPORT __declspec(dllimport) +#else +# define IMPORT +#endif + +int static_hip11_func(int); +IMPORT int shared_hip11_func(int); + +void test_functions() +{ + static_hip11_func(int(42)); + shared_hip11_func(int(42)); +} + +int main(int argc, char** argv) +{ + test_functions(); + return 0; +} |