[Intel-gfx] [PATCH 0/7] drmtest framework support for retval handling

Daniel Vetter daniel at ffwll.ch
Mon Aug 12 11:30:05 CEST 2013


On Mon, Aug 12, 2013 at 11:15:53AM +0200, Daniel Vetter wrote:
> On Mon, Aug 12, 2013 at 11:09:54AM +0200, Daniel Vetter wrote:
> > Hi all,
> > 
> > So I've grown fed-up with our add-hoc (and pretty much always buggy) return
> > value tracking for testcases with subtests. Furthermore sprinkling testcases
> > with tons of if (kernel_has_some_optional_feature) return 77; isn't really
> > helping test case readability.
> > 
> > So I've gone ahead and implement some magic stuff using setjmp/longjmp and a few
> > macros. On top of that a few exemplary conversions of existing testcases.
> > 
> > Comments highly welcome.
> > 
> > Cheers, Daniel
> 
> Just noticed that this already doesn't apply, so I've pushed a rebased
> version to
> 
> http://cgit.freedesktop.org/~danvet/intel-gpu-tools/log/?h=retval-infrastructure
> 
> That one also contains one hunk I've failed to git add.

One more thing I've forgotten to mention is that I want to add a
drmtest_assert macro on top of this which would replace allmost all usage
of assert in lib/drmtest and tests/*. With a few useful printks sprinkled
over drmtest_run_subtest and the drmtest_(skip|success|fail) functions we
could dump per-subtest results even when running with the legacy igt
automake testrunner. And with that we could also make sure that we run all
subtests and don't just fall over after the first one completed.

Cheers, Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch



More information about the Intel-gfx mailing list