Updates for F23 and Perlmutter

This commit is contained in:
Wes Bethel 2023-08-01 13:59:54 -07:00
parent ddcd8bc075
commit f29cb7fe58

View File

@ -4,9 +4,9 @@
This directory contains a benchmark harness for testing different implementations of
summing numbers.
A single high-level main() is present in the benchmark.cpp file, which has definitions of proble3m sizes and so forth.
A single high-level main() is present in the benchmark.cpp file, which has definitions of problem sizes and so forth.
This main() will make calls to two routines that must be provided by your code:
main() will make calls to two routines that must be provided by your code:
* setup(N, A) // where you initialize N values in A
* result = sum(N, A) // where you compute the sum of N values in A and return the answer
@ -15,10 +15,20 @@ This harness will generate three different executables using the one benchmark.c
Your job is to:
* Add code for setup() and sum() in each of sum_direct.cpp, sum_indirect.cpp, and sum_vector.cpp
* Add instrumention code in benchmark.cpp to measure elapsed time for the call to the sum() routine
* Add instrumention code in benchmark.cpp to measure elapsed time for the call to the sum() routine.
Have a look at the [chrono_timer](https://github.com/SFSU-Bethel-Instructional/chrono_timer) code repo for an example of instrumentation code that measures
elapsed time.
You should not need to modify anything inside CMakeLists.txt.
# Build environment prerequisites
To build and run this code, you need to have the following software tools installed on your platform:
* C++ compiler
* cmake
* make
# Default build instructions:
@ -65,7 +75,7 @@ After modifying CMakeLists.txt, clean your build directory, and rerun cmake and
You will need to add code in three places:
* Inside benchmark.cpp: please add instrumentation code that will measure and report elapsed time consumed by the call to the sum() routine. Please refer to the [chrono_timer code](https://github.com/SFSU-CSC746/chrono_timer) for an example of how to do this kind of time measurement.
* Inside benchmark.cpp: please add instrumentation code that will measure and report elapsed time consumed by the call to the sum() routine. Please refer to the [chrono_timer code](https://github.com/SFSU-Bethel-Instructional/chrono_timer) for an example of how to do this kind of time measurement.
* The setup() routine inside each of sum_direct.cpp, sum_indirect.cpp, and sum_vector.cpp. See the homework writeup for details on how to perform initialization for each of these different codes.
@ -87,6 +97,8 @@ or
When you run each code, it will iterate through the set of problem sizes predefined inside benchmark.cpp
The instrumentation code you added to benchmark.cpp should report the elapsed time for your sum() method's execution for each problem size.
# Building and running the codes on Perlmutter@NERSC
After [logging in to perlmutter at NERSC,](https://docs.nersc.gov/systems/perlmutter/), either pull the code directly from git or [transfer a copy from your local machine to NERSC](https://docs.nersc.gov/services/scp/).
@ -110,7 +122,7 @@ Once you are on an interactive CPU node, run each of the codes using these comma
# Building and running the codes on Cori@NERSC (deprecated as of March 2023)
Please refer to lecture slides for additional information about accessing Cori, building your code there, and running your code there.
Please refer to lecture slides for additional information about accessing Perlmutter@NERSC, building your code there, and running your code there.
# EOF