[Intel-gfx] [PATCH 1/2 i-g-t v2] lib: Add 64-bit version of igt_assert_cmp
Chris Wilson
chris at chris-wilson.co.uk
Tue Jun 30 06:49:06 PDT 2015
On Tue, Jun 30, 2015 at 02:41:08PM +0100, Michel Thierry wrote:
> igt_assert_cmp64 and its derivatives:
> - igt_assert_cmpu64
> - igt_assert_eq64
> - igt_assert_eq_u64
> - igt_assert_neq64
> - igt_assert_lte64
> - igt_assert_lt64
>
> v2: Add igt_assert_cmp_t, this macro handles int, long and
> double var cases. (Chris)
>
> Cc: Chris Wilson <chris at chris-wilson.co.uk>
> Signed-off-by: Michel Thierry <michel.thierry at intel.com>
> ---
> lib/igt_core.h | 125 ++++++++++++++++++++++++++++++++++++++++++++-------------
> 1 file changed, 97 insertions(+), 28 deletions(-)
>
> diff --git a/lib/igt_core.h b/lib/igt_core.h
> index 2b2b6e9..09af295 100644
> --- a/lib/igt_core.h
> +++ b/lib/igt_core.h
> @@ -323,6 +323,20 @@ void igt_exit(void) __attribute__((noreturn));
> */
> #define igt_fail_on_f(expr, f...) igt_assert_f(!(expr), f)
>
> +#define INTDECFORMAT "%d"
> +#define UINTHEXFORMAT "%#x"
> +#define DOUBLEDECFORMAT "%#lf"
> +#define LONGHEXFORMAT "%#llx"
Any particular reason? Passing in "%d" or %d would have worked just as
well, right?
Reviewed-by: Chris Wilson <chris at chris-wilson.co.uk>
-Chris
--
Chris Wilson, Intel Open Source Technology Centre
More information about the Intel-gfx
mailing list