/*
 * Copyright (c) Advanced Micro Devices, Inc., or its affiliates.
 *
 * SPDX-License-Identifier: MIT
 */

#include <hip_test_common.hh>

class Dummy {
 public:
  __device__ Dummy() {}
  __device__ ~Dummy() {}
};

#define NEGATIVE_KERNELS_SHELL(func_name)                                                          \
  __global__ void func_name##_kernel_v1(double* x) { double result = func_name(x); }               \
  __global__ void func_name##_kernel_v2(Dummy x) { double result = func_name(x); }                 \
  __global__ void func_name##f_kernel_v1(float* x) { float result = func_name##f(x); }             \
  __global__ void func_name##f_kernel_v2(Dummy x) { float result = func_name##f(x); }

NEGATIVE_KERNELS_SHELL(log)
NEGATIVE_KERNELS_SHELL(log2)
NEGATIVE_KERNELS_SHELL(log10)
NEGATIVE_KERNELS_SHELL(log1p)
NEGATIVE_KERNELS_SHELL(logb)
NEGATIVE_KERNELS_SHELL(ilogb)
