From 2c3e1948407e58c8637605fa73b85c3bf593e374 Mon Sep 17 00:00:00 2001 From: Neil Kichler Date: Tue, 25 Jun 2024 18:02:55 +0200 Subject: [PATCH] put everything into namespace cu:: and fix ADL issues --- examples/bisection.cu | 1 + examples/cuinterval/examples/bisection.cuh | 8 +- include/cuinterval/arithmetic/basic.cuh | 75 ++++++++- include/cuinterval/arithmetic/intrinsic.cuh | 4 +- include/cuinterval/format.h | 25 +++ include/cuinterval/interval.h | 6 +- src/CMakeLists.txt | 1 + tests/generated/tests_atan2.cpp | 2 +- tests/generated/tests_c_xsc.cpp | 2 +- tests/generated/tests_filib.cpp | 2 +- .../generated/tests_intervalarithmeticjl.cpp | 2 +- tests/generated/tests_libieeep1788_bool.cpp | 2 +- tests/generated/tests_libieeep1788_cancel.cpp | 2 +- tests/generated/tests_libieeep1788_elem.cpp | 2 +- tests/generated/tests_libieeep1788_num.cpp | 2 +- .../generated/tests_libieeep1788_rec_bool.cpp | 2 +- tests/generated/tests_libieeep1788_set.cpp | 2 +- tests/generated/tests_mpfi.cpp | 2 +- tests/test_converter.py | 4 +- tests/tests.h | 16 +- tests/tests_bisect.cpp | 3 + tests/tests_bisect.cu | 3 + tests/tests_loop.cpp | 3 + tests/tests_loop.cu | 1 + tests/tests_ops.cu | 140 ++++++++--------- tests/tests_ops.cuh | 148 +++++++++--------- tests/tests_ops.h | 140 ++++++++--------- tests/tests_utils.h | 2 +- 28 files changed, 347 insertions(+), 255 deletions(-) create mode 100644 include/cuinterval/format.h diff --git a/examples/bisection.cu b/examples/bisection.cu index fdf62c2..303f191 100644 --- a/examples/bisection.cu +++ b/examples/bisection.cu @@ -6,6 +6,7 @@ #include "utils.h" +using cu::interval; template __device__ I f(I x) diff --git a/examples/cuinterval/examples/bisection.cuh b/examples/cuinterval/examples/bisection.cuh index 6c5dcc2..8bb83cc 100644 --- a/examples/cuinterval/examples/bisection.cuh +++ b/examples/cuinterval/examples/bisection.cuh @@ -18,13 +18,13 @@ struct local_stack size_type len {}; }; -typedef interval (*fn_t)(interval); +typedef cu::interval (*fn_t)(cu::interval); // Example implementation of the bisection method for finding all roots in a given interval. template -__global__ void bisection(fn_t f, interval x_init, double tol, interval *roots, std::size_t *max_roots) +__global__ void bisection(fn_t f, cu::interval x_init, double tol, cu::interval *roots, std::size_t *max_roots) { - using I = interval; + using I = cu::interval; std::size_t n_roots = 0; local_stack intervals; @@ -66,7 +66,7 @@ __global__ void bisection(fn_t f, interval x_init, double tol, interval *r } } else { // interval could still contain a root -> bisect - split c = bisect(x, 0.5); + cu::split c = bisect(x, 0.5); // we do depth-first search which often will not be optimal intervals.push(c.upper_half); intervals.push(c.lower_half); diff --git a/include/cuinterval/arithmetic/basic.cuh b/include/cuinterval/arithmetic/basic.cuh index 4ec1ac7..560746e 100644 --- a/include/cuinterval/arithmetic/basic.cuh +++ b/include/cuinterval/arithmetic/basic.cuh @@ -1,12 +1,16 @@ #ifndef CUINTERVAL_ARITHMETIC_BASIC_CUH #define CUINTERVAL_ARITHMETIC_BASIC_CUH -#include #include "intrinsic.cuh" +#include #include +#include #include +namespace cu +{ + // // Constant intervals // @@ -120,6 +124,8 @@ inline constexpr __device__ interval sqrt(interval x) template inline constexpr __device__ interval cbrt(interval x) { + using std::cbrt; + if (empty(x)) { return x; } @@ -144,9 +150,9 @@ inline constexpr __device__ interval recip(interval a) } else if (a.lb == zero && zero < a.ub) { return { intrinsic::rcp_down(a.ub), intrinsic::pos_inf() }; } else if (a.lb < zero && zero < a.ub) { - return ::entire(); + return entire(); } else if (a.lb == zero && zero == a.ub) { - return ::empty(); + return empty(); } } @@ -214,6 +220,8 @@ inline constexpr __device__ interval div(interval x, interval y) template inline constexpr __device__ T mag(interval x) { + using std::max; + if (empty(x)) { return intrinsic::nan(); } @@ -223,6 +231,8 @@ inline constexpr __device__ T mag(interval x) template inline constexpr __device__ T mig(interval x) { + using std::min; + // TODO: we might want to split up the function into the bare interval operation and this part. // we could perhaps use a monad for either result or empty using expected? if (empty(x)) { @@ -264,6 +274,8 @@ inline constexpr __device__ interval abs(interval x) template inline constexpr __device__ interval max(interval x, interval y) { + using std::max; + if (empty(x) || empty(y)) { return empty(); } @@ -274,6 +286,8 @@ inline constexpr __device__ interval max(interval x, interval y) template inline constexpr __device__ interval min(interval x, interval y) { + using std::min; + if (empty(x) || empty(y)) { return empty(); } @@ -565,6 +579,9 @@ inline constexpr __device__ interval cancel_plus(interval x, interval y template inline constexpr __device__ interval intersection(interval x, interval y) { + using std::max; + using std::min; + // extended if (disjoint(x, y)) { return empty(); @@ -576,6 +593,9 @@ inline constexpr __device__ interval intersection(interval x, interval template inline constexpr __device__ interval convex_hull(interval x, interval y) { + using std::max; + using std::min; + // extended if (empty(x)) { return y; @@ -770,9 +790,9 @@ inline constexpr __device__ interval pown(interval x, std::integral auto n return empty(); } + using intrinsic::next_after; using intrinsic::next_floating; using intrinsic::prev_floating; - using intrinsic::next_after; if (n % 2) { // odd power if (entire(x)) { @@ -857,6 +877,8 @@ inline constexpr __device__ interval pow_(interval x, T y) template inline constexpr __device__ interval rootn(interval x, std::integral auto n) { + using std::pow; + if (empty(x)) { return x; } @@ -941,6 +963,10 @@ inline constexpr __device__ unsigned int quadrant_pi(T v) template inline constexpr __device__ interval sin(interval x) { + using std::max; + using std::min; + using std::sin; + if (empty(x)) { return x; } @@ -1016,6 +1042,10 @@ inline constexpr __device__ interval sin(interval x) template inline constexpr __device__ interval sinpi(interval x) { + using ::sinpi; + using std::max; + using std::min; + if (empty(x)) { return x; } @@ -1064,6 +1094,10 @@ inline constexpr __device__ interval sinpi(interval x) template inline constexpr __device__ interval cos(interval x) { + using std::cos; + using std::max; + using std::min; + if (empty(x)) { return x; } @@ -1114,6 +1148,10 @@ inline constexpr __device__ interval cos(interval x) template inline constexpr __device__ interval cospi(interval x) { + using ::cospi; + using std::max; + using std::min; + if (empty(x)) { return x; } @@ -1161,6 +1199,8 @@ inline constexpr __device__ interval cospi(interval x) template inline constexpr __device__ interval tan(interval x) { + using std::tan; + if (empty(x)) { return x; } @@ -1192,6 +1232,8 @@ inline constexpr __device__ interval tan(interval x) template inline constexpr __device__ interval asin(interval x) { + using std::asin; + if (empty(x)) { return x; } @@ -1207,6 +1249,8 @@ inline constexpr __device__ interval asin(interval x) template inline constexpr __device__ interval acos(interval x) { + using std::acos; + if (empty(x)) { return x; } @@ -1222,6 +1266,8 @@ inline constexpr __device__ interval acos(interval x) template inline constexpr __device__ interval atan(interval x) { + using std::atan; + if (empty(x)) { return x; } @@ -1235,6 +1281,9 @@ inline constexpr __device__ interval atan(interval x) template inline constexpr __device__ interval atan2(interval y, interval x) { + using std::abs; + using std::atan2; + if (empty(x) || empty(y)) { return empty(); } @@ -1324,6 +1373,8 @@ inline constexpr __device__ interval atan2(interval y, interval x) template inline constexpr __device__ interval sinh(interval x) { + using std::sinh; + if (empty(x)) { return x; } @@ -1335,6 +1386,8 @@ inline constexpr __device__ interval sinh(interval x) template inline constexpr __device__ interval cosh(interval x) { + using std::cosh; + if (empty(x)) { return x; } @@ -1348,6 +1401,8 @@ inline constexpr __device__ interval cosh(interval x) template inline constexpr __device__ interval tanh(interval x) { + using std::tanh; + if (empty(x)) { return x; } @@ -1361,6 +1416,8 @@ inline constexpr __device__ interval tanh(interval x) template inline constexpr __device__ interval asinh(interval x) { + using std::asinh; + if (empty(x)) { return x; } @@ -1372,6 +1429,8 @@ inline constexpr __device__ interval asinh(interval x) template inline constexpr __device__ interval acosh(interval x) { + using std::acosh; + if (empty(x)) { return x; } @@ -1388,6 +1447,8 @@ inline constexpr __device__ interval acosh(interval x) template inline constexpr __device__ interval atanh(interval x) { + using std::atanh; + if (empty(x)) { return x; } @@ -1465,8 +1526,8 @@ inline constexpr __device__ void mince(interval x, interval *xs, std::size xs[i] = empty(); } } else { - T lb = x.lb; - T ub = x.ub; + T lb = x.lb; + T ub = x.ub; T step = (ub - lb) / static_cast(out_xs_size); for (std::size_t i = 0; i < out_xs_size; i++) { @@ -1475,4 +1536,6 @@ inline constexpr __device__ void mince(interval x, interval *xs, std::size } } +} // namespace cu + #endif // CUINTERVAL_ARITHMETIC_BASIC_CUH diff --git a/include/cuinterval/arithmetic/intrinsic.cuh b/include/cuinterval/arithmetic/intrinsic.cuh index f9d0157..62ed585 100644 --- a/include/cuinterval/arithmetic/intrinsic.cuh +++ b/include/cuinterval/arithmetic/intrinsic.cuh @@ -1,7 +1,7 @@ #ifndef CUINTERVAL_ARITHMETIC_INTRINSIC_CUH #define CUINTERVAL_ARITHMETIC_INTRINSIC_CUH -namespace intrinsic +namespace cu::intrinsic { // clang-format off template inline __device__ T fma_down (T x, T y, T z); @@ -104,6 +104,6 @@ namespace intrinsic template<> inline __device__ float prev_floating(float x) { return nextafterf(x, intrinsic::neg_inf()); } // clang-format on -} // namespace intrinsic +} // namespace cu::intrinsic #endif // CUINTERVAL_ARITHMETIC_INTRINSIC_CUH diff --git a/include/cuinterval/format.h b/include/cuinterval/format.h new file mode 100644 index 0000000..66e6044 --- /dev/null +++ b/include/cuinterval/format.h @@ -0,0 +1,25 @@ +#ifndef CUINTERVAL_FORMAT_H +#define CUINTERVAL_FORMAT_H + +#include + +#include + +namespace cu +{ + +template +std::ostream &operator<<(std::ostream &os, interval x) +{ + return os << "[" << x.lb << ", " << x.ub << "]"; +} + +template +std::ostream &operator<<(std::ostream &os, split x) +{ + return os << "[" << x.lower_half << ", " << x.upper_half << "]"; +} + +} // namespace cu + +#endif diff --git a/include/cuinterval/interval.h b/include/cuinterval/interval.h index d72ad7c..04c4e32 100644 --- a/include/cuinterval/interval.h +++ b/include/cuinterval/interval.h @@ -1,6 +1,9 @@ #ifndef CUINTERVAL_INTERVAL_H #define CUINTERVAL_INTERVAL_H +namespace cu +{ + template struct interval { @@ -11,7 +14,6 @@ struct interval template bool operator==(interval lhs, interval rhs) { - auto empty = [](interval x) { return !(x.lb <= x.ub); }; if (empty(lhs) && empty(rhs)) { @@ -30,4 +32,6 @@ struct split auto operator<=>(const split &) const = default; }; +} // namespace cu + #endif // CUINTERVAL_INTERVAL_H diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 6391082..ced24de 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -5,6 +5,7 @@ set(headers "${LIB_PATH}/arithmetic/intrinsic.cuh" "${LIB_PATH}/arithmetic/basic.cuh" "${LIB_PATH}/cuinterval.h" + "${LIB_PATH}/format.h" ) add_library(cuinterval "main.cu" ${headers}) diff --git a/tests/generated/tests_atan2.cpp b/tests/generated/tests_atan2.cpp index 0e1cae2..5fb03b5 100644 --- a/tests/generated/tests_atan2.cpp +++ b/tests/generated/tests_atan2.cpp @@ -12,7 +12,7 @@ void tests_atan2(cuda_buffer buffer, cudaStream_t stream, cudaEvent_t event) { using namespace boost::ut; using T = double; - using I = interval; + using I = cu::interval; using B = bool; using N = int; diff --git a/tests/generated/tests_c_xsc.cpp b/tests/generated/tests_c_xsc.cpp index 4759589..b345197 100644 --- a/tests/generated/tests_c_xsc.cpp +++ b/tests/generated/tests_c_xsc.cpp @@ -12,7 +12,7 @@ void tests_c_xsc(cuda_buffer buffer, cudaStream_t stream, cudaEvent_t event) { using namespace boost::ut; using T = double; - using I = interval; + using I = cu::interval; using B = bool; using N = int; diff --git a/tests/generated/tests_filib.cpp b/tests/generated/tests_filib.cpp index 2aa8c4c..58a3c29 100644 --- a/tests/generated/tests_filib.cpp +++ b/tests/generated/tests_filib.cpp @@ -12,7 +12,7 @@ void tests_filib(cuda_buffer buffer, cudaStream_t stream, cudaEvent_t event) { using namespace boost::ut; using T = double; - using I = interval; + using I = cu::interval; using B = bool; using N = int; diff --git a/tests/generated/tests_intervalarithmeticjl.cpp b/tests/generated/tests_intervalarithmeticjl.cpp index 545abc0..c1ac8ad 100644 --- a/tests/generated/tests_intervalarithmeticjl.cpp +++ b/tests/generated/tests_intervalarithmeticjl.cpp @@ -12,7 +12,7 @@ void tests_intervalarithmeticjl(cuda_buffer buffer, cudaStream_t stream, cudaEve using namespace boost::ut; using T = double; - using I = interval; + using I = cu::interval; using B = bool; using N = int; diff --git a/tests/generated/tests_libieeep1788_bool.cpp b/tests/generated/tests_libieeep1788_bool.cpp index 505dea2..02ab2cf 100644 --- a/tests/generated/tests_libieeep1788_bool.cpp +++ b/tests/generated/tests_libieeep1788_bool.cpp @@ -12,7 +12,7 @@ void tests_libieeep1788_bool(cuda_buffer buffer, cudaStream_t stream, cudaEvent_ using namespace boost::ut; using T = double; - using I = interval; + using I = cu::interval; using B = bool; using N = int; diff --git a/tests/generated/tests_libieeep1788_cancel.cpp b/tests/generated/tests_libieeep1788_cancel.cpp index 892ce66..9c12cf0 100644 --- a/tests/generated/tests_libieeep1788_cancel.cpp +++ b/tests/generated/tests_libieeep1788_cancel.cpp @@ -12,7 +12,7 @@ void tests_libieeep1788_cancel(cuda_buffer buffer, cudaStream_t stream, cudaEven using namespace boost::ut; using T = double; - using I = interval; + using I = cu::interval; using B = bool; using N = int; diff --git a/tests/generated/tests_libieeep1788_elem.cpp b/tests/generated/tests_libieeep1788_elem.cpp index db4d291..2e98dbd 100644 --- a/tests/generated/tests_libieeep1788_elem.cpp +++ b/tests/generated/tests_libieeep1788_elem.cpp @@ -12,7 +12,7 @@ void tests_libieeep1788_elem(cuda_buffer buffer, cudaStream_t stream, cudaEvent_ using namespace boost::ut; using T = double; - using I = interval; + using I = cu::interval; using B = bool; using N = int; diff --git a/tests/generated/tests_libieeep1788_num.cpp b/tests/generated/tests_libieeep1788_num.cpp index ed74f12..4070019 100644 --- a/tests/generated/tests_libieeep1788_num.cpp +++ b/tests/generated/tests_libieeep1788_num.cpp @@ -12,7 +12,7 @@ void tests_libieeep1788_num(cuda_buffer buffer, cudaStream_t stream, cudaEvent_t using namespace boost::ut; using T = double; - using I = interval; + using I = cu::interval; using B = bool; using N = int; diff --git a/tests/generated/tests_libieeep1788_rec_bool.cpp b/tests/generated/tests_libieeep1788_rec_bool.cpp index e8697b4..5918e9f 100644 --- a/tests/generated/tests_libieeep1788_rec_bool.cpp +++ b/tests/generated/tests_libieeep1788_rec_bool.cpp @@ -12,7 +12,7 @@ void tests_libieeep1788_rec_bool(cuda_buffer buffer, cudaStream_t stream, cudaEv using namespace boost::ut; using T = double; - using I = interval; + using I = cu::interval; using B = bool; using N = int; diff --git a/tests/generated/tests_libieeep1788_set.cpp b/tests/generated/tests_libieeep1788_set.cpp index e85c2c0..127ad6e 100644 --- a/tests/generated/tests_libieeep1788_set.cpp +++ b/tests/generated/tests_libieeep1788_set.cpp @@ -12,7 +12,7 @@ void tests_libieeep1788_set(cuda_buffer buffer, cudaStream_t stream, cudaEvent_t using namespace boost::ut; using T = double; - using I = interval; + using I = cu::interval; using B = bool; using N = int; diff --git a/tests/generated/tests_mpfi.cpp b/tests/generated/tests_mpfi.cpp index 385be43..5e6c6d1 100644 --- a/tests/generated/tests_mpfi.cpp +++ b/tests/generated/tests_mpfi.cpp @@ -12,7 +12,7 @@ void tests_mpfi(cuda_buffer buffer, cudaStream_t stream, cudaEvent_t event) { using namespace boost::ut; using T = double; - using I = interval; + using I = cu::interval; using B = bool; using N = int; diff --git a/tests/test_converter.py b/tests/test_converter.py index 6e4637b..9766b92 100644 --- a/tests/test_converter.py +++ b/tests/test_converter.py @@ -116,7 +116,7 @@ def convert_to_test(file_path): using namespace boost::ut; using T = double; - using I = interval; + using I = cu::interval; using B = bool; using N = int; @@ -261,7 +261,7 @@ def generate_kernel_wrappers(ops: dict): wrappers_cpp = auto_generated_comment + '#include "tests_ops.cuh"\n#include "tests_common.h"\n' wrappers_h = auto_generated_comment + '#include "tests_common.h"\n#include \n' - template = {I: 'interval', + template = {I: 'cu::interval', B: 'bool', T: 'double', N: 'int'} diff --git a/tests/tests.h b/tests/tests.h index 0bdab4a..189c3cf 100644 --- a/tests/tests.h +++ b/tests/tests.h @@ -16,26 +16,14 @@ #include #endif +#include #include #include -#include #include #include #include -template -std::ostream &operator<<(std::ostream &os, const interval &x) -{ - return os << '[' << x.lb << ',' << x.ub << ']'; -} - -template -std::ostream &operator<<(std::ostream &os, const split &x) -{ - return os << '(' << x.lower_half << ',' << x.upper_half << ')'; -} - template bool check_within_ulps(T x, T y, std::size_t n, T direction) { @@ -76,7 +64,7 @@ void check_all_equal(T *h_res, std::span h_ref, int max_ulps_diff, std::so if (h_res[i] != h_res[i] && h_ref[i] != h_ref[i]) // both are NaN continue; - if constexpr (std::is_same_v>) { + if constexpr (std::is_same_v>) { if (!empty(h_res[i]) || !empty(h_ref[i])) { bool lb_within_ulps = check_within_ulps(h_res[i].lb, h_ref[i].lb, max_ulps_diff, -std::numeric_limits::infinity()); bool ub_within_ulps = check_within_ulps(h_res[i].ub, h_ref[i].ub, max_ulps_diff, std::numeric_limits::infinity()); diff --git a/tests/tests_bisect.cpp b/tests/tests_bisect.cpp index de07f0d..290b641 100644 --- a/tests/tests_bisect.cpp +++ b/tests/tests_bisect.cpp @@ -8,6 +8,9 @@ #include "tests_ops.h" #include "tests_utils.h" +using cu::interval; +using cu::split; + void test_bisect_call(cudaStream_t stream, int n, interval *x, double *y, split *res); diff --git a/tests/tests_bisect.cu b/tests/tests_bisect.cu index 8a11adc..d9914b8 100644 --- a/tests/tests_bisect.cu +++ b/tests/tests_bisect.cu @@ -9,6 +9,9 @@ #include "tests_common.h" #include "tests_ops.cuh" +using cu::interval; +using cu::split; + void test_bisect_call(cudaStream_t stream, int n, interval *x, double *y, split *res) { diff --git a/tests/tests_loop.cpp b/tests/tests_loop.cpp index 77514b4..d7faa03 100644 --- a/tests/tests_loop.cpp +++ b/tests/tests_loop.cpp @@ -9,6 +9,9 @@ #include #include +using cu::interval; +using cu::split; + thrust::host_vector> compute_pi_approximation(cudaStream_t stream); void tests_pi_approximation(cudaStream_t stream, cudaEvent_t event) diff --git a/tests/tests_loop.cu b/tests/tests_loop.cu index 4bd6bce..14cde38 100644 --- a/tests/tests_loop.cu +++ b/tests/tests_loop.cu @@ -10,6 +10,7 @@ #include #include +using cu::interval; struct to_interval_fn { diff --git a/tests/tests_ops.cu b/tests/tests_ops.cu index 51fdd68..f813bb1 100644 --- a/tests/tests_ops.cu +++ b/tests/tests_ops.cu @@ -3,421 +3,421 @@ #include "tests_common.h" void tests_pos_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_pos<<>>(n, d_xs, d_res); } void tests_neg_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_neg<<>>(n, d_xs, d_res); } void tests_add_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res) { test_add<<>>(n, d_xs, d_ys, d_res); } void tests_sub_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res) { test_sub<<>>(n, d_xs, d_ys, d_res); } void tests_mul_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res) { test_mul<<>>(n, d_xs, d_ys, d_res); } void tests_div_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res) { test_div<<>>(n, d_xs, d_ys, d_res); } void tests_recip_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_recip<<>>(n, d_xs, d_res); } void tests_sqr_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_sqr<<>>(n, d_xs, d_res); } void tests_sqrt_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_sqrt<<>>(n, d_xs, d_res); } void tests_fma_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_zs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_zs, cu::interval *d_res) { test_fma<<>>(n, d_xs, d_ys, d_zs, d_res); } void tests_mig_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, double *d_res) + int n, cu::interval *d_xs, double *d_res) { test_mig<<>>(n, d_xs, d_res); } void tests_mag_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, double *d_res) + int n, cu::interval *d_xs, double *d_res) { test_mag<<>>(n, d_xs, d_res); } void tests_wid_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, double *d_res) + int n, cu::interval *d_xs, double *d_res) { test_wid<<>>(n, d_xs, d_res); } void tests_inf_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, double *d_res) + int n, cu::interval *d_xs, double *d_res) { test_inf<<>>(n, d_xs, d_res); } void tests_sup_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, double *d_res) + int n, cu::interval *d_xs, double *d_res) { test_sup<<>>(n, d_xs, d_res); } void tests_mid_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, double *d_res) + int n, cu::interval *d_xs, double *d_res) { test_mid<<>>(n, d_xs, d_res); } void tests_rad_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, double *d_res) + int n, cu::interval *d_xs, double *d_res) { test_rad<<>>(n, d_xs, d_res); } void tests_floor_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_floor<<>>(n, d_xs, d_res); } void tests_ceil_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_ceil<<>>(n, d_xs, d_res); } void tests_abs_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_abs<<>>(n, d_xs, d_res); } void tests_min_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res) { test_min<<>>(n, d_xs, d_ys, d_res); } void tests_max_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res) { test_max<<>>(n, d_xs, d_ys, d_res); } void tests_trunc_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_trunc<<>>(n, d_xs, d_res); } void tests_sign_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_sign<<>>(n, d_xs, d_res); } void tests_intersection_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res) { test_intersection<<>>(n, d_xs, d_ys, d_res); } void tests_convexHull_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res) { test_convexHull<<>>(n, d_xs, d_ys, d_res); } void tests_equal_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, bool *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, bool *d_res) { test_equal<<>>(n, d_xs, d_ys, d_res); } void tests_subset_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, bool *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, bool *d_res) { test_subset<<>>(n, d_xs, d_ys, d_res); } void tests_interior_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, bool *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, bool *d_res) { test_interior<<>>(n, d_xs, d_ys, d_res); } void tests_disjoint_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, bool *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, bool *d_res) { test_disjoint<<>>(n, d_xs, d_ys, d_res); } void tests_isEmpty_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, bool *d_res) + int n, cu::interval *d_xs, bool *d_res) { test_isEmpty<<>>(n, d_xs, d_res); } void tests_isEntire_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, bool *d_res) + int n, cu::interval *d_xs, bool *d_res) { test_isEntire<<>>(n, d_xs, d_res); } void tests_less_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, bool *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, bool *d_res) { test_less<<>>(n, d_xs, d_ys, d_res); } void tests_strictLess_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, bool *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, bool *d_res) { test_strictLess<<>>(n, d_xs, d_ys, d_res); } void tests_precedes_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, bool *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, bool *d_res) { test_precedes<<>>(n, d_xs, d_ys, d_res); } void tests_strictPrecedes_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, bool *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, bool *d_res) { test_strictPrecedes<<>>(n, d_xs, d_ys, d_res); } void tests_isMember_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, double *d_xs, interval *d_ys, bool *d_res) + int n, double *d_xs, cu::interval *d_ys, bool *d_res) { test_isMember<<>>(n, d_xs, d_ys, d_res); } void tests_isSingleton_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, bool *d_res) + int n, cu::interval *d_xs, bool *d_res) { test_isSingleton<<>>(n, d_xs, d_res); } void tests_isCommonInterval_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, bool *d_res) + int n, cu::interval *d_xs, bool *d_res) { test_isCommonInterval<<>>(n, d_xs, d_res); } void tests_cancelMinus_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res) { test_cancelMinus<<>>(n, d_xs, d_ys, d_res); } void tests_cancelPlus_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res) { test_cancelPlus<<>>(n, d_xs, d_ys, d_res); } void tests_roundTiesToEven_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_roundTiesToEven<<>>(n, d_xs, d_res); } void tests_roundTiesToAway_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_roundTiesToAway<<>>(n, d_xs, d_res); } void tests_cbrt_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_cbrt<<>>(n, d_xs, d_res); } void tests_exp_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_exp<<>>(n, d_xs, d_res); } void tests_exp2_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_exp2<<>>(n, d_xs, d_res); } void tests_exp10_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_exp10<<>>(n, d_xs, d_res); } void tests_expm1_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_expm1<<>>(n, d_xs, d_res); } void tests_log_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_log<<>>(n, d_xs, d_res); } void tests_log2_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_log2<<>>(n, d_xs, d_res); } void tests_log10_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_log10<<>>(n, d_xs, d_res); } void tests_log1p_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_log1p<<>>(n, d_xs, d_res); } void tests_sin_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_sin<<>>(n, d_xs, d_res); } void tests_cos_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_cos<<>>(n, d_xs, d_res); } void tests_tan_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_tan<<>>(n, d_xs, d_res); } void tests_asin_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_asin<<>>(n, d_xs, d_res); } void tests_acos_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_acos<<>>(n, d_xs, d_res); } void tests_atan_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_atan<<>>(n, d_xs, d_res); } void tests_atan2_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res) { test_atan2<<>>(n, d_xs, d_ys, d_res); } void tests_sinh_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_sinh<<>>(n, d_xs, d_res); } void tests_cosh_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_cosh<<>>(n, d_xs, d_res); } void tests_tanh_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_tanh<<>>(n, d_xs, d_res); } void tests_asinh_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_asinh<<>>(n, d_xs, d_res); } void tests_acosh_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_acosh<<>>(n, d_xs, d_res); } void tests_atanh_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_atanh<<>>(n, d_xs, d_res); } void tests_sinpi_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_sinpi<<>>(n, d_xs, d_res); } void tests_cospi_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_res) { test_cospi<<>>(n, d_xs, d_res); } void tests_pown_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, int *d_ys, interval *d_res) + int n, cu::interval *d_xs, int *d_ys, cu::interval *d_res) { test_pown<<>>(n, d_xs, d_ys, d_res); } void tests_pow_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res) + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res) { test_pow<<>>(n, d_xs, d_ys, d_res); } void tests_rootn_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, int *d_ys, interval *d_res) + int n, cu::interval *d_xs, int *d_ys, cu::interval *d_res) { test_rootn<<>>(n, d_xs, d_ys, d_res); } diff --git a/tests/tests_ops.cuh b/tests/tests_ops.cuh index 6a1e1e0..b80bfe2 100644 --- a/tests/tests_ops.cuh +++ b/tests/tests_ops.cuh @@ -4,7 +4,7 @@ #include template -__global__ void test_pos(int n, interval *x, interval *res) +__global__ void test_pos(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -13,7 +13,7 @@ __global__ void test_pos(int n, interval *x, interval *res) } template -__global__ void test_neg(int n, interval *x, interval *res) +__global__ void test_neg(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -22,7 +22,7 @@ __global__ void test_neg(int n, interval *x, interval *res) } template -__global__ void test_recip(int n, interval *x, interval *res) +__global__ void test_recip(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -31,7 +31,7 @@ __global__ void test_recip(int n, interval *x, interval *res) } template -__global__ void test_sqr(int n, interval *x, interval *res) +__global__ void test_sqr(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -40,7 +40,7 @@ __global__ void test_sqr(int n, interval *x, interval *res) } template -__global__ void test_sqrt(int n, interval *x, interval *res) +__global__ void test_sqrt(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -49,7 +49,7 @@ __global__ void test_sqrt(int n, interval *x, interval *res) } template -__global__ void test_cbrt(int n, interval *x, interval *res) +__global__ void test_cbrt(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -58,7 +58,7 @@ __global__ void test_cbrt(int n, interval *x, interval *res) } template -__global__ void test_add(int n, interval *x, interval *y, interval *res) +__global__ void test_add(int n, cu::interval *x, cu::interval *y, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -67,7 +67,7 @@ __global__ void test_add(int n, interval *x, interval *y, interval *res } template -__global__ void test_cancelPlus(int n, interval *x, interval *y, interval *res) +__global__ void test_cancelPlus(int n, cu::interval *x, cu::interval *y, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -76,7 +76,7 @@ __global__ void test_cancelPlus(int n, interval *x, interval *y, interval< } template -__global__ void test_cancelMinus(int n, interval *x, interval *y, interval *res) +__global__ void test_cancelMinus(int n, cu::interval *x, cu::interval *y, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -85,7 +85,7 @@ __global__ void test_cancelMinus(int n, interval *x, interval *y, interval } template -__global__ void test_sub(int n, interval *x, interval *y, interval *res) +__global__ void test_sub(int n, cu::interval *x, cu::interval *y, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -94,7 +94,7 @@ __global__ void test_sub(int n, interval *x, interval *y, interval *res } template -__global__ void test_mul(int n, interval *x, interval *y, interval *res) +__global__ void test_mul(int n, cu::interval *x, cu::interval *y, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -103,7 +103,7 @@ __global__ void test_mul(int n, interval *x, interval *y, interval *res } template -__global__ void test_div(int n, interval *x, interval *y, interval *res) +__global__ void test_div(int n, cu::interval *x, cu::interval *y, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -112,7 +112,7 @@ __global__ void test_div(int n, interval *x, interval *y, interval *res } template -__global__ void test_fma(int n, interval *x, interval *y, interval *z, interval *res) +__global__ void test_fma(int n, cu::interval *x, cu::interval *y, cu::interval *z, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -121,7 +121,7 @@ __global__ void test_fma(int n, interval *x, interval *y, interval *z, } template -__global__ void test_inf(int n, interval *x, T *res) +__global__ void test_inf(int n, cu::interval *x, T *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -130,7 +130,7 @@ __global__ void test_inf(int n, interval *x, T *res) } template -__global__ void test_sup(int n, interval *x, T *res) +__global__ void test_sup(int n, cu::interval *x, T *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -139,7 +139,7 @@ __global__ void test_sup(int n, interval *x, T *res) } template -__global__ void test_mid(int n, interval *x, T *res) +__global__ void test_mid(int n, cu::interval *x, T *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -148,7 +148,7 @@ __global__ void test_mid(int n, interval *x, T *res) } template -__global__ void test_rad(int n, interval *x, T *res) +__global__ void test_rad(int n, cu::interval *x, T *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -157,7 +157,7 @@ __global__ void test_rad(int n, interval *x, T *res) } template -__global__ void test_mag(int n, interval *x, T *res) +__global__ void test_mag(int n, cu::interval *x, T *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -166,7 +166,7 @@ __global__ void test_mag(int n, interval *x, T *res) } template -__global__ void test_mig(int n, interval *x, T *res) +__global__ void test_mig(int n, cu::interval *x, T *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -175,7 +175,7 @@ __global__ void test_mig(int n, interval *x, T *res) } template -__global__ void test_wid(int n, interval *x, T *res) +__global__ void test_wid(int n, cu::interval *x, T *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -184,7 +184,7 @@ __global__ void test_wid(int n, interval *x, T *res) } template -__global__ void test_floor(int n, interval *x, interval *res) +__global__ void test_floor(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -193,7 +193,7 @@ __global__ void test_floor(int n, interval *x, interval *res) } template -__global__ void test_ceil(int n, interval *x, interval *res) +__global__ void test_ceil(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -202,7 +202,7 @@ __global__ void test_ceil(int n, interval *x, interval *res) } template -__global__ void test_trunc(int n, interval *x, interval *res) +__global__ void test_trunc(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -211,7 +211,7 @@ __global__ void test_trunc(int n, interval *x, interval *res) } template -__global__ void test_sign(int n, interval *x, interval *res) +__global__ void test_sign(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -220,7 +220,7 @@ __global__ void test_sign(int n, interval *x, interval *res) } template -__global__ void test_abs(int n, interval *x, interval *res) +__global__ void test_abs(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -229,7 +229,7 @@ __global__ void test_abs(int n, interval *x, interval *res) } template -__global__ void test_min(int n, interval *x, interval *y, interval *res) +__global__ void test_min(int n, cu::interval *x, cu::interval *y, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -238,7 +238,7 @@ __global__ void test_min(int n, interval *x, interval *y, interval *res } template -__global__ void test_max(int n, interval *x, interval *y, interval *res) +__global__ void test_max(int n, cu::interval *x, cu::interval *y, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -247,7 +247,7 @@ __global__ void test_max(int n, interval *x, interval *y, interval *res } template -__global__ void test_intersection(int n, interval *x, interval *y, interval *res) +__global__ void test_intersection(int n, cu::interval *x, cu::interval *y, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -256,7 +256,7 @@ __global__ void test_intersection(int n, interval *x, interval *y, interva } template -__global__ void test_convexHull(int n, interval *x, interval *y, interval *res) +__global__ void test_convexHull(int n, cu::interval *x, cu::interval *y, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -265,7 +265,7 @@ __global__ void test_convexHull(int n, interval *x, interval *y, interval< } template -__global__ void test_equal(int n, interval *x, interval *y, bool *res) +__global__ void test_equal(int n, cu::interval *x, cu::interval *y, bool *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -274,7 +274,7 @@ __global__ void test_equal(int n, interval *x, interval *y, bool *res) } template -__global__ void test_subset(int n, interval *x, interval *y, bool *res) +__global__ void test_subset(int n, cu::interval *x, cu::interval *y, bool *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -283,7 +283,7 @@ __global__ void test_subset(int n, interval *x, interval *y, bool *res) } template -__global__ void test_interior(int n, interval *x, interval *y, bool *res) +__global__ void test_interior(int n, cu::interval *x, cu::interval *y, bool *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -292,7 +292,7 @@ __global__ void test_interior(int n, interval *x, interval *y, bool *res) } template -__global__ void test_disjoint(int n, interval *x, interval *y, bool *res) +__global__ void test_disjoint(int n, cu::interval *x, cu::interval *y, bool *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -301,7 +301,7 @@ __global__ void test_disjoint(int n, interval *x, interval *y, bool *res) } template -__global__ void test_isEmpty(int n, interval *x, bool *res) +__global__ void test_isEmpty(int n, cu::interval *x, bool *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -310,7 +310,7 @@ __global__ void test_isEmpty(int n, interval *x, bool *res) } template -__global__ void test_isEntire(int n, interval *x, bool *res) +__global__ void test_isEntire(int n, cu::interval *x, bool *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -319,7 +319,7 @@ __global__ void test_isEntire(int n, interval *x, bool *res) } template -__global__ void test_less(int n, interval *x, interval *y, bool *res) +__global__ void test_less(int n, cu::interval *x, cu::interval *y, bool *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -328,7 +328,7 @@ __global__ void test_less(int n, interval *x, interval *y, bool *res) } template -__global__ void test_strictLess(int n, interval *x, interval *y, bool *res) +__global__ void test_strictLess(int n, cu::interval *x, cu::interval *y, bool *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -337,7 +337,7 @@ __global__ void test_strictLess(int n, interval *x, interval *y, bool *res } template -__global__ void test_precedes(int n, interval *x, interval *y, bool *res) +__global__ void test_precedes(int n, cu::interval *x, cu::interval *y, bool *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -346,7 +346,7 @@ __global__ void test_precedes(int n, interval *x, interval *y, bool *res) } template -__global__ void test_strictPrecedes(int n, interval *x, interval *y, bool *res) +__global__ void test_strictPrecedes(int n, cu::interval *x, cu::interval *y, bool *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -355,7 +355,7 @@ __global__ void test_strictPrecedes(int n, interval *x, interval *y, bool } template -__global__ void test_isMember(int n, T *x, interval *y, bool *res) +__global__ void test_isMember(int n, T *x, cu::interval *y, bool *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -364,7 +364,7 @@ __global__ void test_isMember(int n, T *x, interval *y, bool *res) } template -__global__ void test_isSingleton(int n, interval *x, bool *res) +__global__ void test_isSingleton(int n, cu::interval *x, bool *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -373,7 +373,7 @@ __global__ void test_isSingleton(int n, interval *x, bool *res) } template -__global__ void test_isCommonInterval(int n, interval *x, bool *res) +__global__ void test_isCommonInterval(int n, cu::interval *x, bool *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -382,7 +382,7 @@ __global__ void test_isCommonInterval(int n, interval *x, bool *res) } template -__global__ void test_roundTiesToEven(int n, interval *x, interval *res) +__global__ void test_roundTiesToEven(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -391,7 +391,7 @@ __global__ void test_roundTiesToEven(int n, interval *x, interval *res) } template -__global__ void test_roundTiesToAway(int n, interval *x, interval *res) +__global__ void test_roundTiesToAway(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -400,7 +400,7 @@ __global__ void test_roundTiesToAway(int n, interval *x, interval *res) } template -__global__ void test_exp(int n, interval *x, interval *res) +__global__ void test_exp(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -409,7 +409,7 @@ __global__ void test_exp(int n, interval *x, interval *res) } template -__global__ void test_exp2(int n, interval *x, interval *res) +__global__ void test_exp2(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -418,7 +418,7 @@ __global__ void test_exp2(int n, interval *x, interval *res) } template -__global__ void test_exp10(int n, interval *x, interval *res) +__global__ void test_exp10(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -427,7 +427,7 @@ __global__ void test_exp10(int n, interval *x, interval *res) } template -__global__ void test_expm1(int n, interval *x, interval *res) +__global__ void test_expm1(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -436,7 +436,7 @@ __global__ void test_expm1(int n, interval *x, interval *res) } template -__global__ void test_log(int n, interval *x, interval *res) +__global__ void test_log(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -445,7 +445,7 @@ __global__ void test_log(int n, interval *x, interval *res) } template -__global__ void test_log2(int n, interval *x, interval *res) +__global__ void test_log2(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -454,7 +454,7 @@ __global__ void test_log2(int n, interval *x, interval *res) } template -__global__ void test_log10(int n, interval *x, interval *res) +__global__ void test_log10(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -463,7 +463,7 @@ __global__ void test_log10(int n, interval *x, interval *res) } template -__global__ void test_log1p(int n, interval *x, interval *res) +__global__ void test_log1p(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -472,7 +472,7 @@ __global__ void test_log1p(int n, interval *x, interval *res) } template -__global__ void test_pown(int n, interval *x, int p, interval *res) +__global__ void test_pown(int n, cu::interval *x, int p, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -481,7 +481,7 @@ __global__ void test_pown(int n, interval *x, int p, interval *res) } template -__global__ void test_sin(int n, interval *x, interval *res) +__global__ void test_sin(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -490,7 +490,7 @@ __global__ void test_sin(int n, interval *x, interval *res) } template -__global__ void test_cos(int n, interval *x, interval *res) +__global__ void test_cos(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -499,7 +499,7 @@ __global__ void test_cos(int n, interval *x, interval *res) } template -__global__ void test_tan(int n, interval *x, interval *res) +__global__ void test_tan(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -508,7 +508,7 @@ __global__ void test_tan(int n, interval *x, interval *res) } template -__global__ void test_asin(int n, interval *x, interval *res) +__global__ void test_asin(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -517,7 +517,7 @@ __global__ void test_asin(int n, interval *x, interval *res) } template -__global__ void test_acos(int n, interval *x, interval *res) +__global__ void test_acos(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -526,7 +526,7 @@ __global__ void test_acos(int n, interval *x, interval *res) } template -__global__ void test_atan(int n, interval *x, interval *res) +__global__ void test_atan(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -535,7 +535,7 @@ __global__ void test_atan(int n, interval *x, interval *res) } template -__global__ void test_sinh(int n, interval *x, interval *res) +__global__ void test_sinh(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -544,7 +544,7 @@ __global__ void test_sinh(int n, interval *x, interval *res) } template -__global__ void test_cosh(int n, interval *x, interval *res) +__global__ void test_cosh(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -553,7 +553,7 @@ __global__ void test_cosh(int n, interval *x, interval *res) } template -__global__ void test_tanh(int n, interval *x, interval *res) +__global__ void test_tanh(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -562,7 +562,7 @@ __global__ void test_tanh(int n, interval *x, interval *res) } template -__global__ void test_asinh(int n, interval *x, interval *res) +__global__ void test_asinh(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -571,7 +571,7 @@ __global__ void test_asinh(int n, interval *x, interval *res) } template -__global__ void test_acosh(int n, interval *x, interval *res) +__global__ void test_acosh(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -580,7 +580,7 @@ __global__ void test_acosh(int n, interval *x, interval *res) } template -__global__ void test_atanh(int n, interval *x, interval *res) +__global__ void test_atanh(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -589,7 +589,7 @@ __global__ void test_atanh(int n, interval *x, interval *res) } template -__global__ void test_atan2(int n, interval *y, interval *x, interval *res) +__global__ void test_atan2(int n, cu::interval *y, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -598,7 +598,7 @@ __global__ void test_atan2(int n, interval *y, interval *x, interval *r } template -__global__ void test_sinpi(int n, interval *x, interval *res) +__global__ void test_sinpi(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -607,7 +607,7 @@ __global__ void test_sinpi(int n, interval *x, interval *res) } template -__global__ void test_cospi(int n, interval *x, interval *res) +__global__ void test_cospi(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -616,7 +616,7 @@ __global__ void test_cospi(int n, interval *x, interval *res) } template -__global__ void test_cot(int n, interval *x, interval *res) +__global__ void test_cot(int n, cu::interval *x, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -625,7 +625,7 @@ __global__ void test_cot(int n, interval *x, interval *res) } template -__global__ void test_pown(int n, interval *x, int *n_pow, interval *res) +__global__ void test_pown(int n, cu::interval *x, int *n_pow, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -634,7 +634,7 @@ __global__ void test_pown(int n, interval *x, int *n_pow, interval *res) } template -__global__ void test_rootn(int n, interval *x, int *n_pow, interval *res) +__global__ void test_rootn(int n, cu::interval *x, int *n_pow, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -643,7 +643,7 @@ __global__ void test_rootn(int n, interval *x, int *n_pow, interval *res) } template -__global__ void test_pow(int n, interval *x, interval *y, interval *res) +__global__ void test_pow(int n, cu::interval *x, cu::interval *y, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -652,7 +652,7 @@ __global__ void test_pow(int n, interval *x, interval *y, interval *res } template -__global__ void test_bisect(int n, interval *x, T *y, split *res) +__global__ void test_bisect(int n, cu::interval *x, T *y, cu::split *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { @@ -661,7 +661,7 @@ __global__ void test_bisect(int n, interval *x, T *y, split *res) } template -__global__ void test_mince(int n, interval *x, int *d_offsets, interval *res) +__global__ void test_mince(int n, cu::interval *x, int *d_offsets, cu::interval *res) { int i = threadIdx.x + blockIdx.x * blockDim.x; if (i < n) { diff --git a/tests/tests_ops.h b/tests/tests_ops.h index a45b141..5adc6b4 100644 --- a/tests/tests_ops.h +++ b/tests/tests_ops.h @@ -3,211 +3,211 @@ #include void tests_pos_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_neg_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_add_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res); void tests_sub_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res); void tests_mul_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res); void tests_div_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res); void tests_recip_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_sqr_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_sqrt_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_fma_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_zs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_zs, cu::interval *d_res); void tests_mig_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, double *d_res); + int n, cu::interval *d_xs, double *d_res); void tests_mag_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, double *d_res); + int n, cu::interval *d_xs, double *d_res); void tests_wid_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, double *d_res); + int n, cu::interval *d_xs, double *d_res); void tests_inf_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, double *d_res); + int n, cu::interval *d_xs, double *d_res); void tests_sup_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, double *d_res); + int n, cu::interval *d_xs, double *d_res); void tests_mid_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, double *d_res); + int n, cu::interval *d_xs, double *d_res); void tests_rad_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, double *d_res); + int n, cu::interval *d_xs, double *d_res); void tests_floor_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_ceil_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_abs_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_min_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res); void tests_max_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res); void tests_trunc_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_sign_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_intersection_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res); void tests_convexHull_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res); void tests_equal_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, bool *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, bool *d_res); void tests_subset_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, bool *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, bool *d_res); void tests_interior_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, bool *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, bool *d_res); void tests_disjoint_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, bool *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, bool *d_res); void tests_isEmpty_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, bool *d_res); + int n, cu::interval *d_xs, bool *d_res); void tests_isEntire_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, bool *d_res); + int n, cu::interval *d_xs, bool *d_res); void tests_less_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, bool *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, bool *d_res); void tests_strictLess_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, bool *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, bool *d_res); void tests_precedes_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, bool *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, bool *d_res); void tests_strictPrecedes_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, bool *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, bool *d_res); void tests_isMember_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, double *d_xs, interval *d_ys, bool *d_res); + int n, double *d_xs, cu::interval *d_ys, bool *d_res); void tests_isSingleton_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, bool *d_res); + int n, cu::interval *d_xs, bool *d_res); void tests_isCommonInterval_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, bool *d_res); + int n, cu::interval *d_xs, bool *d_res); void tests_cancelMinus_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res); void tests_cancelPlus_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res); void tests_roundTiesToEven_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_roundTiesToAway_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_cbrt_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_exp_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_exp2_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_exp10_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_expm1_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_log_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_log2_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_log10_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_log1p_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_sin_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_cos_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_tan_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_asin_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_acos_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_atan_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_atan2_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res); void tests_sinh_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_cosh_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_tanh_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_asinh_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_acosh_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_atanh_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_sinpi_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_cospi_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_res); void tests_pown_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, int *d_ys, interval *d_res); + int n, cu::interval *d_xs, int *d_ys, cu::interval *d_res); void tests_pow_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, interval *d_ys, interval *d_res); + int n, cu::interval *d_xs, cu::interval *d_ys, cu::interval *d_res); void tests_rootn_call(int numBlocks, int blockSize, cudaStream_t stream, - int n, interval *d_xs, int *d_ys, interval *d_res); + int n, cu::interval *d_xs, int *d_ys, cu::interval *d_res); diff --git a/tests/tests_utils.h b/tests/tests_utils.h index 3561230..56ad40b 100644 --- a/tests/tests_utils.h +++ b/tests/tests_utils.h @@ -6,7 +6,7 @@ #include template -void contains(interval x, T y) +void contains(cu::interval x, T y) { using namespace boost::ut;