forked from UoB-HPC/BabelStream
-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fortran Packages Branch #1
Merged
Merged
Conversation
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
Fix missing counting iterator operators for stdpar
Reflect updated model options in README
Updating kokkos/model.cmake to allow for in-package builds (eg. Spack)
Introduced RAJA_IN_PACKAGE to allow for linking to an in-package dependency of RAJA (eg. Spack)
Facilitating Spack builds
Co-authored-by: Nick Curtis <arghdos@users.noreply.github.com>
This is a new implementation of BabelStream using Fortran. The code uses a Fortran driver that is largely equivalent to the C++ one, with a few exceptions. First, it does not use a C++ class for the stream object, since that doesn't seem like a useful way to do things in Fortran. Instead, I use a module that contains the same methods, and which has alloc and dealloc that act like CTOR and DTOR. The current implementations are: - DO CONCURRENT - Fortran array notation - Sequential DO loops - OpenACC parallel loop - OpenACC kernels on Fortran array notation - OpenMP parallel do - OpenMP taskloop - OpenMP target teams distribute parallel do simd - OpenMP target teams loop - CUDA Fortran (handwritten CUDA Fortran kernels, except DOT) - CUDA Fortran kernels (!$cuf kernel do <<<*,*>>>) I have tested with GCC, Intel (ifort and ifx), and NVHPC compilers on AArch64, x86_64 and NVIDIA GPU targets, although not exhaustively. Cray and Fujitsu have been tested as well. The only untested compiler of significance is IBM XLF. The current build system is GNU Make, and requires the user to manually specify the compiler and implementation. CSV printing is supported. Squashed commit of the following: commit 15f13ef Author: Jeff Hammond <email> Date: Tue Nov 15 06:42:46 2022 +0200 8 cores unless user changes commit 62ca680 Author: Jeff Hammond <email> Date: Tue Nov 15 06:42:09 2022 +0200 hoist and disable orin flags commit 7649550 Author: Jeff Hammond <email> Date: Tue Nov 15 06:40:13 2022 +0200 cleanup scripts commit 5b45df8 Author: Jeff Hammond <email> Date: Tue Nov 15 06:39:31 2022 +0200 add autopar flag for GCC commit 87eb07e Merge: a732e7c 270644e Author: Jeff Hammond <email> Date: Wed Nov 9 15:53:41 2022 +0200 Merge remote-tracking branch 'origin/fortran_compiler_details' into fortran-ports commit a732e7c Merge: cfafd99 5697d94 Author: Jeff Hammond <email> Date: Wed Nov 9 15:53:36 2022 +0200 Merge remote-tracking branch 'origin/fortran_int32_option' into fortran-ports commit cfafd99 Merge: de5ff67 26a9707 Author: Jeff Hammond <email> Date: Wed Nov 9 15:53:25 2022 +0200 Merge remote-tracking branch 'origin/fortran_csv' into fortran-ports commit de5ff67 Merge: 3109653 1d0755f Author: Jeff Hammond <email> Date: Wed Nov 9 15:51:40 2022 +0200 Merge branch 'UoB-HPC:main' into fortran-ports commit 3109653 Author: Jeff Hammond <jehammond@nvidia.com> Date: Mon Sep 26 03:39:01 2022 -0700 because gomp so confict commit 270644e Author: Jeff Hammond <email> Date: Fri Sep 16 11:46:49 2022 +0300 add compiler info flag commit 5697d94 Author: Jeff Hammond <email> Date: Sun Sep 4 13:59:57 2022 +0300 implement INT32 indexing commit 830ad58 Author: Jeff Hammond <email> Date: Sun Sep 4 13:49:17 2022 +0300 remove swear words from debugging commit 26a9707 Author: Jeff Hammond <email> Date: Sun Sep 4 13:47:18 2022 +0300 add an option for giga/gibi-bytes commit 4f6d693 Author: Jeff Hammond <email> Date: Sun Sep 4 13:41:32 2022 +0300 CSV output seems done Signed-off-by: Jeff Hammond <email> commit 94e62be Merge: ad52adc 772c183 Author: Jeff Hammond <email> Date: Sun Sep 4 12:59:01 2022 +0300 Merge branch 'fortran_nan_check' into fortran_csv commit 772c183 Author: Jeff Hammond <email> Date: Sun Sep 4 10:44:26 2022 +0300 fixed NaN check commit ad52adc Author: Jeff Hammond <email> Date: Sun Sep 4 10:28:00 2022 +0300 CSV WIP commit 6f7cefc Author: Jeff Hammond <email> Date: Sun Sep 4 10:08:14 2022 +0300 update help output commit 2082075 Author: Jeff Hammond <email> Date: Sun Sep 4 10:02:24 2022 +0300 add option for cpu_time intrinsic timer also adjust use statements and rename macro for OpenMP timer Signed-off-by: Jeff Hammond <email> commit 78fa2fc Author: Jeff Hammond <email> Date: Tue Aug 30 17:19:36 2022 +0300 add check for normal (not NaN, not Inf, not denormal) the previous error check failed to detect garbage results because comparisons against NaN always return true. i flipped the logical comparison and added a check for IEEE normal to prevent this. it works on the case that was missed previously. Signed-off-by: Jeff Hammond <email> commit 22fc9fe Author: Jeff Hammond <email> Date: Tue Aug 30 17:19:30 2022 +0300 move commit d2d8c85 Author: Jeff Hammond <email> Date: Tue Aug 30 16:29:15 2022 +0300 so far so good commit ffe1815 Author: Jeff Hammond <email> Date: Tue Aug 30 16:29:09 2022 +0300 so far so good commit aa72b46 Author: Jeff Hammond <email> Date: Tue Aug 30 16:28:52 2022 +0300 GPU on by default commit 0fc9e4a Author: Jeff Hammond <jehammond@nvidia.com> Date: Thu Aug 25 16:38:08 2022 +0300 better commit b1cbd6f Merge: bf14601 5fe03c6 Author: Jeff Hammond <email> Date: Thu Aug 25 16:35:22 2022 +0300 Merge branch 'fortran-ports' of https://github.com/jeffhammond/BabelStream into fortran-ports commit bf14601 Author: Jeff Hammond <email> Date: Thu Aug 25 16:35:07 2022 +0300 autodetect GPU arch in build (who needs CMake?) commit 5fe03c6 Author: Jeff Hammond <jehammond@nvidia.com> Date: Thu Aug 25 15:57:41 2022 +0300 be smarter and check for compilers in path commit a187612 Author: Jeff Hammond <email> Date: Thu Aug 25 15:35:58 2022 +0300 remove samsung paths commit 82af886 Merge: a46bf6b 0f59b50 Author: Jeff Hammond <jehammond@nvidia.com> Date: Wed Aug 24 13:22:13 2022 +0300 merge fix plus build updates commit 0f59b50 Author: Jeff Hammond <jehammond@nvidia.com> Date: Wed Aug 24 08:43:19 2022 +0000 typo in USE_OPENMP_TIMERS commit 4a9a001 Author: Jeff Hammond <jehammond@nvidia.com> Date: Wed Aug 24 08:42:59 2022 +0000 logic fix commit 74d8123 Author: Jeff Hammond <jehammond@nvidia.com> Date: Wed Aug 24 03:05:58 2022 -0500 no-gpu option commit dc1e39f Author: Jeff Hammond <jehammond@nvidia.com> Date: Wed Aug 24 03:05:17 2022 -0500 fix default case commit 0b2b0e0 Author: Jeff Hammond <jehammond@nvidia.com> Date: Wed Aug 24 02:57:02 2022 -0500 fix tp for aarch64 commit 1e213be Author: Jeff Hammond <jehammond@nvidia.com> Date: Wed Aug 24 07:46:41 2022 +0000 fix MARCH and build.sh elif commit a46bf6b Author: Jeff Hammond <jehammond@nvidia.com> Date: Tue Aug 23 16:43:22 2022 +0300 orin updates commit a9fe9c0 Merge: 2ab14de 9f4bee4 Author: Jeff Hammond <jehammond@nvidia.com> Date: Tue Aug 23 06:32:01 2022 -0700 more CPU specialization fixes commit 2ab14de Author: Jeff Hammond <jehammond@nvidia.com> Date: Tue Aug 23 06:30:37 2022 -0700 more CPU specialization fixes commit 9f4bee4 Author: Jeff Hammond <email> Date: Tue Aug 23 16:12:13 2022 +0300 build and run updates commit aeff085 Author: Jeff Hammond <email> Date: Tue Aug 23 15:56:25 2022 +0300 aesthetics commit 89b1ab0 Author: Jeff Hammond <email> Date: Tue Aug 23 15:56:08 2022 +0300 handle march flag better commit a284bfa Author: Jeff Hammond <email> Date: Tue Aug 23 15:56:04 2022 +0300 handle march flag better commit c18c394 Author: Jeff Hammond <email> Date: Tue Aug 23 15:53:11 2022 +0300 handle march flag better commit a3a8ccf Author: Jeff Hammond <jehammond@nvidia.com> Date: Tue Aug 23 05:29:41 2022 -0700 brewster updates commit 1364c41 Author: Tom Deakin <thomasdeakin@gmail.com> Date: Sun Aug 21 17:16:20 2022 +0100 Add Fujitsu compiler flags commit b82fe2c Author: Jeff Hammond <email> Date: Sun Aug 21 15:40:28 2022 +0300 FJ timer workaround commit c1b2fa8 Author: Jeff Hammond <email> Date: Sun Aug 21 15:29:13 2022 +0300 intel update/fix commit 063ef87 Author: Jeff Hammond <email> Date: Sun Aug 21 04:43:29 2022 -0700 NERSC AMD compiler commit 2c68292 Merge: 2bdbbe8 ca98948 Author: Jeff Hammond <jehammond@nvidia.com> Date: Sun Aug 21 02:12:12 2022 -0700 Merge branch 'fortran-ports' of https://github.com/jeffhammond/BabelStream into fortran-ports commit 2bdbbe8 Author: Jeff Hammond <jehammond@nvidia.com> Date: Sun Aug 21 02:11:27 2022 -0700 AMD ROCM buikd commit ca98948 Author: Jeff Hammond <jehammond@nvidia.com> Date: Sun Aug 21 09:10:16 2022 +0000 AWS stuff commit 4c539ef Author: Jeff Hammond <jehammond@nvidia.com> Date: Sun Aug 21 09:09:59 2022 +0000 merge commit c383065 Author: Jeff Hammond <email> Date: Sun Aug 21 02:08:46 2022 -0700 NERSC stuff commit 7d7f746 Merge: 1fefb8e d929852 Author: Jeff Hammond <email> Date: Sat Aug 20 20:56:09 2022 -0700 Merge branch 'fortran-ports' of https://github.com/jeffhammond/BabelStream into fortran-ports commit 1fefb8e Author: Jeff Hammond <email> Date: Sat Aug 20 20:55:16 2022 -0700 Cray temp stuff commit d929852 Author: Jeff Hammond <jehammond@nvidia.com> Date: Fri Aug 19 02:11:07 2022 -0700 Xeon stuff commit 3f19e45 Merge: 38f28e1 c8dd609 Author: Jeff Hammond <jehammond@nvidia.com> Date: Thu Aug 18 13:56:37 2022 +0000 Merge branch 'fortran-ports' of https://github.com/jeffhammond/BabelStream into fortran-ports commit 38f28e1 Author: Jeff Hammond <jehammond@nvidia.com> Date: Thu Aug 18 13:54:12 2022 +0000 TARGET for cpu too commit 6be181a Author: Jeff Hammond <jehammond@nvidia.com> Date: Thu Aug 18 13:52:58 2022 +0000 AWS flags commit e88479e Author: Jeff Hammond <jehammond@nvidia.com> Date: Thu Aug 18 13:52:42 2022 +0000 ARM stuff for AWS commit 1ee26cb Author: Jeff Hammond <jehammond@nvidia.com> Date: Thu Aug 18 13:52:24 2022 +0000 disable shared for portability commit c8dd609 Merge: 8bda56d 1b67999 Author: Jeff Hammond <email> Date: Thu Aug 18 15:23:16 2022 +0300 Merge branch 'UoB-HPC:main' into fortran-ports commit 8bda56d Author: Jeff Hammond <email> Date: Wed Aug 17 03:07:13 2022 -0700 add Cray compiler to build system - ignore temp files generated by Cray Fortran - workaround Cray not having reduce commit 3a0fec6 Author: Jeff Hammond <jehammond@nvidia.com> Date: Wed Aug 17 02:09:19 2022 -0700 remove LOCAL, which causes problems commit e5a70dd Author: Jeff Hammond <email> Date: Wed Aug 10 22:26:50 2022 +0300 add a way to use managed/device for everything DC uses managed by default. no way to not use it and be strictly standard right now. managed affects performance in some cases, so we want to compare apples-to-apples. thanks to Jeff Larkin for helping with this. Signed-off-by: Jeff Hammond <email> commit 8fe956a Author: Jeff Hammond <email> Date: Wed Aug 10 22:26:41 2022 +0300 only do GPU flag for IFX commit de49723 Author: Jeff Hammond <email> Date: Wed Aug 10 22:26:23 2022 +0300 helper scripts commit e0971aa Author: Jeff Hammond <email> Date: Wed Aug 10 22:26:21 2022 +0300 helper scripts commit a7ba50a Author: Jeff Hammond <email> Date: Wed Aug 10 12:29:28 2022 +0300 remove all the compiled intermediates with wildcard commit 31a594e Author: Jeff Hammond <jehammond@nvidia.com> Date: Fri Aug 5 03:31:32 2022 -0700 build stuff commit 2cd3acd Author: Jeff Hammond <jehammond@nvidia.com> Date: Fri Aug 5 02:09:17 2022 -0700 build all with unique names commit ac230d1 Author: Jeff Hammond <email> Date: Fri Aug 5 09:28:03 2022 +0300 fix make clean commit bd0ef77 Author: Jeff Hammond <email> Date: Fri Aug 5 09:24:12 2022 +0300 build check update commit 662520c Author: Jeff Hammond <email> Date: Fri Aug 5 09:21:48 2022 +0300 CUDA kernel version commit 25c3219 Author: Jeff Hammond <email> Date: Fri Aug 5 09:15:32 2022 +0300 fixed CUDA Fortran dot commit 64612d2 Author: Jeff Hammond <email> Date: Fri Aug 5 09:10:49 2022 +0300 CUDA Fortran working except DOT commit 4d35fe5 Author: Jeff Hammond <email> Date: Fri Aug 5 08:48:17 2022 +0300 CUDA Fortran is not compiling yet commit 0967c36 Author: Jeff Hammond <email> Date: Fri Aug 5 07:50:40 2022 +0300 workshare commit 3ed69ea Author: Jeff Hammond <email> Date: Fri Aug 5 07:42:49 2022 +0300 target loop commit 30dfb57 Author: Jeff Hammond <email> Date: Fri Aug 5 07:31:41 2022 +0300 OpenMP target commit a5306ce Author: Jeff Hammond <email> Date: Fri Aug 5 07:17:58 2022 +0300 makefile errors on non support commit 854c813 Author: Jeff Hammond <email> Date: Fri Aug 5 07:15:12 2022 +0300 fix taskloop commit f2894c5 Author: Jeff Hammond <email> Date: Fri Aug 5 07:11:26 2022 +0300 add taskloop part 1 commit b7c0a43 Author: Jeff Hammond <email> Date: Fri Aug 5 07:07:54 2022 +0300 add OpenMP traditional commit 7dafcc3 Author: Jeff Hammond <email> Date: Fri Aug 5 07:02:36 2022 +0300 add OpenACC kernels + Array implementation commit 096e7d2 Author: Jeff Hammond <email> Date: Fri Aug 5 06:53:13 2022 +0300 formatting commit 284b62b Author: Jeff Hammond <email> Date: Thu Aug 4 19:41:27 2022 +0300 add placeholder for CSV commit 516bdd5 Author: Jeff Hammond <email> Date: Thu Aug 4 19:14:00 2022 +0300 add --float commit d4e0cca Author: Jeff Hammond <email> Date: Thu Aug 4 19:13:23 2022 +0300 default message updates commit e8452f1 Author: Jeff Hammond <email> Date: Thu Aug 4 17:58:48 2022 +0300 list devices etc commit a80e82c Author: Jeff Hammond <email> Date: Thu Aug 4 14:07:02 2022 +0300 better build system commit c3b090c Author: Jeff Hammond <email> Date: Thu Aug 4 14:03:27 2022 +0300 refactor build system commit 096cd43 Author: Jeff Hammond <email> Date: Thu Aug 4 13:43:17 2022 +0300 cleanup the rest commit 1e4fb81 Author: Jeff Hammond <email> Date: Thu Aug 4 13:40:38 2022 +0300 add Intel build and fix syntax issuse commit db3a930 Author: Jeff Hammond <email> Date: Thu Aug 4 13:34:43 2022 +0300 use modern character syntax commit b66bd70 Author: Jeff Hammond <email> Date: Thu Aug 4 12:10:59 2022 +0300 printing commit ff842f6 Author: Jeff Hammond <jehammond@nvidia.com> Date: Thu Aug 4 11:06:43 2022 +0300 build stuff commit 0579108 Author: Jeff Hammond <email> Date: Wed Aug 3 20:10:33 2022 +0300 add OpenACC commit bb76b75 Author: Jeff Hammond <email> Date: Wed Aug 3 20:04:12 2022 +0300 better clean commit 2f53530 Author: Jeff Hammond <email> Date: Wed Aug 3 20:03:04 2022 +0300 Sequential loop Stream commit f5c0eae Author: Jeff Hammond <email> Date: Wed Aug 3 19:56:54 2022 +0300 add array notation commit 76f836b Author: Jeff Hammond <email> Date: Wed Aug 3 10:05:46 2022 +0300 implement BabelStream in Fortran 1. only DO CONCURRENT is supported right now. 2. the structure mostly matches C++ except we do not make a stream class. 3. there is no option for float versus double right now. it will be a compile-time choice later. Signed-off-by: Jeff Hammond <email>
Fortran ports
Added ICPX support for the OneAPI 2023 support
Updated hip kernels
This improves the performance on Ampere (A100) GPUs. Fixes #137.
Fix RAJA > v0.14.1 compatibility
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Retrieving the Develop branch in order to export the fortran version to a new branch for Spack