From efaac624afb2c5d74230dbec3dc358f1d50bc806 Mon Sep 17 00:00:00 2001 From: Giuseppe Bilotta Date: Sun, 29 Nov 2015 18:19:35 +0100 Subject: [PATCH] xvmc: force assertion in XvMC tests This follows the src/util/u_atomic_test.c model of undefining NDEBUG unconditionally throughouth the XvMC tests, to force asserts regardless of debug mode. The comment on u_atomic_test.c is also fixed (read 'debug' where it should have been 'release'). v2: s/debug/release/ in relevant comments Signed-off-by: Giuseppe Bilotta [Emil Velikov: keep the src/util/ hunk as separate patch] Signed-off-by: Emil Velikov --- src/gallium/state_trackers/xvmc/tests/test_blocks.c | 2 ++ src/gallium/state_trackers/xvmc/tests/test_context.c | 2 ++ src/gallium/state_trackers/xvmc/tests/test_rendering.c | 2 ++ src/gallium/state_trackers/xvmc/tests/test_subpicture.c | 2 ++ src/gallium/state_trackers/xvmc/tests/test_surface.c | 2 ++ 5 files changed, 10 insertions(+) diff --git a/src/gallium/state_trackers/xvmc/tests/test_blocks.c b/src/gallium/state_trackers/xvmc/tests/test_blocks.c index a35838f3309..53c29bc5ae1 100644 --- a/src/gallium/state_trackers/xvmc/tests/test_blocks.c +++ b/src/gallium/state_trackers/xvmc/tests/test_blocks.c @@ -25,6 +25,8 @@ * **************************************************************************/ +/* Force assertions, even on release builds. */ +#undef NDEBUG #include #include #include diff --git a/src/gallium/state_trackers/xvmc/tests/test_context.c b/src/gallium/state_trackers/xvmc/tests/test_context.c index 344ac76decc..81d26fcffd5 100644 --- a/src/gallium/state_trackers/xvmc/tests/test_context.c +++ b/src/gallium/state_trackers/xvmc/tests/test_context.c @@ -25,6 +25,8 @@ * **************************************************************************/ +/* Force assertions, even on release builds. */ +#undef NDEBUG #include #include #include diff --git a/src/gallium/state_trackers/xvmc/tests/test_rendering.c b/src/gallium/state_trackers/xvmc/tests/test_rendering.c index b3b3794810d..c5494ecc8c2 100644 --- a/src/gallium/state_trackers/xvmc/tests/test_rendering.c +++ b/src/gallium/state_trackers/xvmc/tests/test_rendering.c @@ -25,6 +25,8 @@ * **************************************************************************/ +/* Force assertions, even on release builds. */ +#undef NDEBUG #include #include #include diff --git a/src/gallium/state_trackers/xvmc/tests/test_subpicture.c b/src/gallium/state_trackers/xvmc/tests/test_subpicture.c index 57ba1c75138..006972fa8ee 100644 --- a/src/gallium/state_trackers/xvmc/tests/test_subpicture.c +++ b/src/gallium/state_trackers/xvmc/tests/test_subpicture.c @@ -25,6 +25,8 @@ * **************************************************************************/ +/* Force assertions, even on release builds. */ +#undef NDEBUG #include #include #include diff --git a/src/gallium/state_trackers/xvmc/tests/test_surface.c b/src/gallium/state_trackers/xvmc/tests/test_surface.c index 964ca82c506..d5a121d5ab0 100644 --- a/src/gallium/state_trackers/xvmc/tests/test_surface.c +++ b/src/gallium/state_trackers/xvmc/tests/test_surface.c @@ -25,6 +25,8 @@ * **************************************************************************/ +/* Force assertions, even on release builds. */ +#undef NDEBUG #include #include #include -- 2.30.2