RAJA
RAJA provides a collection of platform portability abstractions for C++ HPC applications.
Namespaces | Macros
reduce.hpp File Reference

Header file providing RAJA reduction declarations. More...

#include "RAJA/config.hpp"
#include "RAJA/util/Operators.hpp"
#include "RAJA/util/macros.hpp"

Go to the source code of this file.

Namespaces

 RAJA
 

Macros

#define RAJA_MIN(a, b)   (((b) < (a)) ? (b) : (a))
 
#define RAJA_MAX(a, b)   (((b) > (a)) ? (b) : (a))
 
#define RAJA_MINLOC_UNSTRUCTURED(set_val, set_idx, a_val, a_idx, b_val, b_idx)
 Macros to support unstructured minmaxloc operations. More...
 
#define RAJA_MAXLOC_UNSTRUCTURED(set_val, set_idx, a_val, a_idx, b_val, b_idx)
 

Detailed Description

Header file providing RAJA reduction declarations.

Macro Definition Documentation

◆ RAJA_MIN

#define RAJA_MIN (   a,
 
)    (((b) < (a)) ? (b) : (a))

Macros for type agnostic reduction operations.

◆ RAJA_MAX

#define RAJA_MAX (   a,
 
)    (((b) > (a)) ? (b) : (a))

◆ RAJA_MINLOC_UNSTRUCTURED

#define RAJA_MINLOC_UNSTRUCTURED (   set_val,
  set_idx,
  a_val,
  a_idx,
  b_val,
  b_idx 
)
Value:
set_idx = ((b_val) < (a_val) ? (b_idx) : (a_idx)); \
set_val = ((b_val) < (a_val) ? (b_val) : (a_val));

Macros to support unstructured minmaxloc operations.

◆ RAJA_MAXLOC_UNSTRUCTURED

#define RAJA_MAXLOC_UNSTRUCTURED (   set_val,
  set_idx,
  a_val,
  a_idx,
  b_val,
  b_idx 
)
Value:
set_idx = ((b_val) > (a_val) ? (b_idx) : (a_idx)); \
set_val = ((b_val) > (a_val) ? (b_val) : (a_val));