LLVM OpenMP 22.0.0git
omp_for_private_reduction.cpp File Reference
#include <stdio.h>
#include <omp.h>
#include <limits.h>
#include <complex.h>
#include <math.h>
#include "omp_testsuite.h"

Go to the source code of this file.

Classes

class  Sum

Macros

#define N   10

Functions

int checkUserDefinedReduction ()
void performMinMaxRed (int &min_val, int &max_val)
std::complex< doubledoComplexReduction (std::complex< double > *arr)
void performReductions (int n_elements, const int *input_values, int &sum_val_out, int &prod_val_out, float &float_sum_val_out)
int main (void)

Macro Definition Documentation

◆ N

#define N   10

Definition at line 9 of file omp_for_private_reduction.cpp.

Function Documentation

◆ checkUserDefinedReduction()

int checkUserDefinedReduction ( )

Definition at line 30 of file omp_for_private_reduction.cpp.

References Sum::getValue(), i, and N.

Referenced by main().

◆ doComplexReduction()

std::complex< double > doComplexReduction ( std::complex< double > * arr)

Definition at line 76 of file omp_for_private_reduction.cpp.

References arr, i, N, and result.

Referenced by main().

◆ main()

◆ performMinMaxRed()

void performMinMaxRed ( int & min_val,
int & max_val )

Definition at line 62 of file omp_for_private_reduction.cpp.

References i.

Referenced by main().

◆ performReductions()

void performReductions ( int n_elements,
const int * input_values,
int & sum_val_out,
int & prod_val_out,
float & float_sum_val_out )

Definition at line 89 of file omp_for_private_reduction.cpp.

References i.

Referenced by main().