1
Fork 0
mirror of https://github.com/Steffo99/unimore-hpc-assignments.git synced 2024-11-23 16:44:22 +00:00
hpc-2022-g3/OpenMP/README.md

86 lines
3.1 KiB
Markdown
Raw Normal View History

2022-11-13 17:13:23 +00:00
# PolyBench/GPU-OpenMP 1.0
> Copyright (c) 2013 the University of Delaware.
> Contact: William Killian <killian@udel.edu>
> Copyright (c) 2011-2012 the Ohio State University.
> Contact: Louis-Noel Pouchet <pouchet@cse.ohio-state.edu>
## Available Benchmarks
2022-11-13 17:11:53 +00:00
2022-11-13 17:15:16 +00:00
### `datamining`
* `datamining/correlation`
* `datamining/covariance`
### `linear-algebra/kernels`
* `linear-algebra/kernels/2mm`
* `linear-algebra/kernels/3mm`
* `linear-algebra/kernels/atax`
* `linear-algebra/kernels/bicg`
* `linear-algebra/kernels/cholesky`
* `linear-algebra/kernels/doitgen`
* `linear-algebra/kernels/gemm`
* `linear-algebra/kernels/gemver`
* `linear-algebra/kernels/gesummv`
* `linear-algebra/kernels/mvt`
* `linear-algebra/kernels/symm`
* `linear-algebra/kernels/syr2k`
* `linear-algebra/kernels/syrk`
* `linear-algebra/kernels/trisolv`
* `linear-algebra/kernels/trmm`
### `linear-algebra/solvers`
* `linear-algebra/solvers/durbin`
* `linear-algebra/solvers/dynprog`
* `linear-algebra/solvers/gramschmidt`
* `linear-algebra/solvers/lu`
* `linear-algebra/solvers/ludcmp`
### `stencils`
* `stencils/adi`
* `stencils/convolution-2d`
* `stencils/convolution-3d`
* `stencils/fdtd-2d`
* `stencils/jacobi-1d-imper`
* `stencils/jacobi-2d-imper`
* `stencils/seidel-2d`
2022-11-11 12:23:45 +00:00
2022-11-13 17:11:53 +00:00
## Modifying Codes
2022-11-11 12:23:45 +00:00
Parameters such as the input sizes, data type, and threshold for GPU-CPU output comparison can be modified using constants
within the codes and .h files. After modifying, run `make clean` then `make` on relevant code for modifications to take effect in resulting executable.
2022-11-13 17:11:53 +00:00
### Parameter Configuration
#### Input Size
2022-11-11 12:23:45 +00:00
By default the `STANDARD_DATASET` as defined in the `.cuh/.h` file is used as the input size. The dataset choice can be adjusted from `STANDARD_DATASET` to other
options (`MINI_DATASET`, `SMALL_DATASET`, etc) in the `.cuh/.h` file, the dataset size can be adjusted by defining the input size manually in the `.cuh/.h` file, or
the input size can be changed by simply adjusting the `STANDARD_DATASET` so the program has different input dimensions.
2022-11-13 17:11:53 +00:00
#### `DATA_TYPE` (in `.cuh/.h` files):
2022-11-11 12:23:45 +00:00
2022-11-13 17:11:53 +00:00
By default, the `DATA_TYPE` used in these codes are `float` that can be changed to `double` by changing the `DATA_TYPE` typedef. Note that in OpenCL, the `DATA_TYPE` needs to be changed in both the .h and .cl files, as the .cl files contain the kernel code and is compiled separately at run-time.
2022-11-11 12:23:45 +00:00
2022-11-13 17:11:53 +00:00
#### Other available options
2022-11-11 12:23:45 +00:00
These are passed as macro definitions during compilation time
(e.g `-Dname_of_the_option`) or can be added with a `#define` to the code.
2022-11-13 17:11:53 +00:00
2022-11-11 12:23:45 +00:00
- `POLYBENCH_STACK_ARRAYS` (only applies to allocation on host):
use stack allocation instead of malloc [default: off]
- `POLYBENCH_DUMP_ARRAYS`: dump all live-out arrays on stderr [default: off]
- `POLYBENCH_CYCLE_ACCURATE_TIMER`: Use Time Stamp Counter to monitor
the execution time of the kernel [default: off]
- `MINI_DATASET`, `SMALL_DATASET`, `STANDARD_DATASET`, `LARGE_DATASET`,
`EXTRALARGE_DATASET`: set the dataset size to be used
[default: `STANDARD_DATASET`]
- `POLYBENCH_USE_C99_PROTO`: Use standard C99 prototype for the functions.
- `POLYBENCH_USE_SCALAR_LB`: Use scalar loop bounds instead of parametric ones.