On Mon, 2016-02-22 at 20:38 -0600, Aaron Watry wrote:
> Signed-off-by: Aaron Watry <[email protected]>

Reviewed-by: Jan Vesely <[email protected]>


> ---
>  tests/cl/program/execute/builtin/math/ilogb.cl | 31
> ++++++++++++++++++++++++++
>  1 file changed, 31 insertions(+)
>  create mode 100644 tests/cl/program/execute/builtin/math/ilogb.cl
> 
> diff --git a/tests/cl/program/execute/builtin/math/ilogb.cl
> b/tests/cl/program/execute/builtin/math/ilogb.cl
> new file mode 100644
> index 0000000..0b23f2c
> --- /dev/null
> +++ b/tests/cl/program/execute/builtin/math/ilogb.cl
> @@ -0,0 +1,31 @@
> +/*!
> +[config]
> +name: ilogb
> +clc_version_min: 10
> +dimensions: 1
> +
> +[test]
> +name: float scalar ilogb(0.0)
> +kernel_name: ilogb_macro_ilogb0
> +global_size: 1 0 0
> +arg_out: 0 buffer int[1] 0
> +arg_in: 1 buffer float[1] 0.0
> +
> +[test]
> +name: float scalar ilogb(nan)
> +kernel_name: ilogb_macro_ilogbnan
> +global_size: 1 0 0
> +arg_out: 0 buffer int[1] 0
> +arg_in: 1 buffer float[1] nan
> +
> +!*/
> +
> +kernel void ilogb_macro_ilogb0(global int* out, global float* in1) {
> +    size_t id = get_global_id(0);
> +    out[id] = ilogb(in1[id]) - FP_ILOGB0;
> +}
> +
> +kernel void ilogb_macro_ilogbnan(global int* out, global float* in1)
> {
> +    size_t id = get_global_id(0);
> +    out[id] = ilogb(in1[id]) - FP_ILOGBNAN;
> +}
-- 
Jan Vesely <[email protected]>

Attachment: signature.asc
Description: This is a digitally signed message part

_______________________________________________
Piglit mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/piglit

Reply via email to