|
Peano
|
Go to the source code of this file.
Functions | |
| tarch::logging::Log | _log ("::") |
| void | initInputData (double *Q) |
| Set input data. | |
| void | allocateAndStoreOutcome (const double *const *Q, const double *const maxEigenvalue, const int numberOfCells) |
| Allocates and stores outcome of one compute kernel. | |
| void | freeOutcome (const int numberOfCells) |
| void | validateOutcome (const double *const *Q, const double *const maxEigenvalue, const int numberOfCells) |
| Validate data against pre-stored simulation outcome. | |
| void | reportRuntime (const std::string &kernelIdentificator, const tarch::timing::Measurement &timingKernelLaunch, int numberOfCells) |
| Reports the runtime and throughput of the benchmarks. | |
| double | runKernels (int device, exahype2::CellData< double, double > &cellData, int cellIndex, tarch::timing::Measurement &measurement) |
| void | runBenchmarks (int numberOfCells) |
| Run the benchmark for one particular number of cells. | |
| int | main (int argc, char **argv) |
Variables | |
| constexpr double | TimeStamp = 0.0 |
| constexpr double | TimeStepSize = 1e-6 |
| const tarch::la::Vector< DIMENSIONS, double > | CellCenter = benchmarks::exahype2::kernelbenchmarks::DomainOffset + 0.5*benchmarks::exahype2::kernelbenchmarks::DomainSize |
| const tarch::la::Vector< DIMENSIONS, double > | CellSize = benchmarks::exahype2::kernelbenchmarks::DomainSize / 81.0 |
| constexpr int | NumberOfInputEntriesPerCell |
| constexpr int | NumberOfOutputEntriesPerCell = 0 |
| constexpr int | NumberOfFiniteVolumesPerCell |
| double ** | validQ = nullptr |
| double * | validMaxEigenvalue = nullptr |
| bool | outcomeIsInvalid = false |
| tarch::timing::Measurement | timingComputeKernel |
| tarch::logging::Log _log | ( | "::" | ) |
| void allocateAndStoreOutcome | ( | const double *const * | Q, |
| const double *const | maxEigenvalue, | ||
| const int | numberOfCells ) |
Allocates and stores outcome of one compute kernel.
Make a persistent snapshot of a solution and assume, from hereon, that this snapshot is the valid data. You can call this routine as often as you want. Only the very first call will trigger a snapshot.
Note: needs to freed using the freeOutcome() routine.
Definition at line 123 of file KernelBenchmarks-main.cpp.
References benchmarks::exahype2::kernelbenchmarks::NumberOfOutputEntriesPerCell, validMaxEigenvalue, and validQ.
Referenced by runBenchmarks().

| void freeOutcome | ( | const int | numberOfCells | ) |
Definition at line 140 of file KernelBenchmarks-main.cpp.
References validMaxEigenvalue, and validQ.
Referenced by main().

| void initInputData | ( | double * | Q | ) |
Set input data.
We use the values from the centralMost Cell in the domain with an arbitrary cell size of 1/81 of the domain size.
TODO: should we update this to actual initial conditions?
Definition at line 90 of file KernelBenchmarks-main.cpp.
References CellCenter, and CellSize.
| int main | ( | int | argc, |
| char ** | argv ) |
Definition at line 417 of file KernelBenchmarks-main.cpp.
References freeOutcome(), outcomeIsInvalid, and runBenchmarks().

| void reportRuntime | ( | const std::string & | kernelIdentificator, |
| const tarch::timing::Measurement & | timingKernelLaunch, | ||
| int | numberOfCells ) |
Reports the runtime and throughput of the benchmarks.
First set of outputs refers to the time of the compute kernel itself. Second set of outputs refers to the time including the kernel launch overhead. The throughput is measured in the updates of volumes per second (dof/s).
Definition at line 222 of file KernelBenchmarks-main.cpp.
References timingComputeKernel.
| void runBenchmarks | ( | int | numberOfCells | ) |
Run the benchmark for one particular number of cells.
| numberOfCells | Number of cells to study |
Definition at line 351 of file KernelBenchmarks-main.cpp.
References allocateAndStoreOutcome(), CellCenter, CellSize, benchmarks::exahype2::kernelbenchmarks::initInputData(), benchmarks::exahype2::kernelbenchmarks::NumberOfInputEntriesPerCell, benchmarks::exahype2::kernelbenchmarks::NumberOfOutputEntriesPerCell, benchmarks::exahype2::kernelbenchmarks::reportRuntime(), runKernels(), TimeStamp, TimeStepSize, timingComputeKernel, and validateOutcome().
Referenced by main().


| double runKernels | ( | int | device, |
| exahype2::CellData< double, double > & | cellData, | ||
| int | cellIndex, | ||
| tarch::timing::Measurement & | measurement ) |
Definition at line 242 of file KernelBenchmarks-main.cpp.
References CellCenter, CellSize, TimeStamp, and TimeStepSize.
Referenced by runBenchmarks().

| void validateOutcome | ( | const double *const * | Q, |
| const double *const | maxEigenvalue, | ||
| const int | numberOfCells ) |
Validate data against pre-stored simulation outcome.
Works if and only if storeOutcome has been performed before. Does not abort in case there are errors. If there are errors, we return a status code != 0.
Definition at line 159 of file KernelBenchmarks-main.cpp.
References benchmarks::exahype2::kernelbenchmarks::NumberOfOutputEntriesPerCell, outcomeIsInvalid, validMaxEigenvalue, and validQ.
Referenced by runBenchmarks().

| const tarch::la::Vector<DIMENSIONS,double> CellCenter = benchmarks::exahype2::kernelbenchmarks::DomainOffset + 0.5*benchmarks::exahype2::kernelbenchmarks::DomainSize |
Definition at line 44 of file KernelBenchmarks-main.cpp.
Referenced by initInputData(), benchmarks::exahype2::kernelbenchmarks::initInputData(), runBenchmarks(), and runKernels().
| const tarch::la::Vector<DIMENSIONS,double> CellSize = benchmarks::exahype2::kernelbenchmarks::DomainSize / 81.0 |
Definition at line 45 of file KernelBenchmarks-main.cpp.
Referenced by createMarkerFromIndex(), createRefinedMarkersFromIndex(), initInputData(), benchmarks::exahype2::kernelbenchmarks::initInputData(), interpolateBetweenAMRBorder(), runBenchmarks(), and runKernels().
|
constexpr |
Definition at line 67 of file KernelBenchmarks-main.cpp.
|
constexpr |
Definition at line 50 of file KernelBenchmarks-main.cpp.
|
constexpr |
Definition at line 58 of file KernelBenchmarks-main.cpp.
| bool outcomeIsInvalid = false |
Definition at line 78 of file KernelBenchmarks-main.cpp.
Referenced by main(), and validateOutcome().
|
constexpr |
Definition at line 42 of file KernelBenchmarks-main.cpp.
Referenced by runBenchmarks(), and runKernels().
|
constexpr |
Definition at line 43 of file KernelBenchmarks-main.cpp.
Referenced by runBenchmarks(), and runKernels().
| tarch::timing::Measurement timingComputeKernel |
Definition at line 80 of file KernelBenchmarks-main.cpp.
Referenced by benchmarks::exahype2::kernelbenchmarks::reportRuntime(), reportRuntime(), runBenchmarks(), variant1::runBenchmarks(), variant2::runBenchmarks(), variant3::runBenchmarks(), variant4::runBenchmarks(), variant5::runBenchmarks(), and variant6::runBenchmarks().
| double* validMaxEigenvalue = nullptr |
Definition at line 77 of file KernelBenchmarks-main.cpp.
Referenced by allocateAndStoreOutcome(), freeOutcome(), and validateOutcome().
| double** validQ = nullptr |
Definition at line 76 of file KernelBenchmarks-main.cpp.
Referenced by allocateAndStoreOutcome(), freeOutcome(), and validateOutcome().