qutil_double_max - Man Page
find the maximum value within an array in parallel
Synopsis
#include <qthread.h>
#include <qthread/qutil.h>
double
qutil_double_max (double *array, size_t length, int checkfeb);
unsigned int
qutil_uint_max (unsigned int *array, size_t length, int checkfeb);
int
qutil_int_max (int *array, size_t length, int checkfeb);
Description
These functions take as input an array of length numbers and will return the maximum value within those numbers. This value is computed in parallel by using a chained-loop structure, using qthreads to compute the maximum in chunks.
If checkfeb is non-zero, these functions will wait for the entries in the array to be full before comparing them. They DO NOT check whether the array entries are properly aligned. If the datatype is too small to do a FEB operation on, they will abort, if sanity checks are turned on.
Return Value
The maximum value of the first length entries of array.
See Also
qutil_double_mult(3), qutil_double_sum(3), qutil_double_min(3), qutil_uint_mult(3), qutil_uint_sum(3), qutil_uint_min(3), qutil_int_mult(3), qutil_int_sum(3), qutil_int_min(3), qutil_mergesort(3), qutil_qsort(3)
Referenced By
qutil_double_min(3), qutil_double_mult(3), qutil_double_sum(3), qutil_qsort(3).