public inbox for igt-dev@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Ramalingam C <ramalingam.c@intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>
Cc: igt-dev@lists.freedesktop.org
Subject: Re: [igt-dev] [PATCH i-g-t v2 4/5] test/i915: gem_exec_params: use the gem_engine_topology library
Date: Thu, 30 May 2019 21:43:29 +0530	[thread overview]
Message-ID: <20190530161329.GC16874@intel.com> (raw)
In-Reply-To: <155923138502.27302.12429248375084395371@skylake-alporthouse-com>

On 2019-05-30 at 16:49:45 +0100, Chris Wilson wrote:
> Quoting Ramalingam C (2019-05-30 16:42:21)
> > Replace the legacy for_each_engine* defines with the ones implemented
> > in the gem_engine_topology library.
> > 
> > v2:
> >   has_ring() check is removed [tvertko]
> >   Engine type is identified through CLASS [tvrtko]
> > 
> > Signed-off-by: Ramalingam C <ramalingam.c@intel.com>
> > ---
> >  tests/i915/gem_exec_params.c | 41 ++++++------------------------------
> >  1 file changed, 7 insertions(+), 34 deletions(-)
> > 
> > diff --git a/tests/i915/gem_exec_params.c b/tests/i915/gem_exec_params.c
> > index 49c56a8d75e9..3bc5b0a9d531 100644
> > --- a/tests/i915/gem_exec_params.c
> > +++ b/tests/i915/gem_exec_params.c
> > @@ -52,30 +52,6 @@
> >  #define LOCAL_I915_EXEC_BATCH_FIRST (1 << 18)
> >  #define LOCAL_I915_EXEC_FENCE_ARRAY (1 << 19)
> >  
> > -static bool has_ring(int fd, unsigned ring_exec_flags)
> > -{
> > -       switch (ring_exec_flags & I915_EXEC_RING_MASK) {
> > -       case 0:
> > -       case I915_EXEC_RENDER:
> > -               return true;
> > -
> > -       case I915_EXEC_BSD:
> > -               if (ring_exec_flags & LOCAL_I915_EXEC_BSD_MASK)
> > -                       return gem_has_bsd2(fd);
> > -               else
> > -                       return gem_has_bsd(fd);
> > -
> > -       case I915_EXEC_BLT:
> > -               return gem_has_blt(fd);
> > -
> > -       case I915_EXEC_VEBOX:
> > -               return gem_has_vebox(fd);
> > -       }
> > -
> > -       igt_assert_f(0, "invalid exec flag 0x%x\n", ring_exec_flags);
> > -       return false;
> > -}
> > -
> >  static bool has_exec_batch_first(int fd)
> >  {
> >         int val = -1;
> > @@ -201,7 +177,7 @@ int fd;
> >  
> >  igt_main
> >  {
> > -       const struct intel_execution_engine *e;
> > +       const struct intel_execution_engine2 *e;
> >  
> >         igt_fixture {
> >                 fd = drm_open_driver(DRIVER_INTEL);
> > @@ -235,11 +211,9 @@ igt_main
> >         }
> >  
> >         igt_subtest("control") {
> > -               for (e = intel_execution_engines; e->name; e++) {
> > -                       if (has_ring(fd, e->exec_id | e->flags)) {
> > -                               execbuf.flags = e->exec_id | e->flags;
> > -                               gem_execbuf(fd, &execbuf);
> > -                       }
> > +               __for_each_physical_engine(fd, e) {
> > +                       execbuf.flags = e->flags;
> > +                       gem_execbuf(fd, &execbuf);
> 
> This is silly. Previously it was cross-checking the GETPARAM against the
> EXECBUFFER uABI. Now it is asking the same question twice.
> 
> This is the example that should not be using physical engines as it
> exercising ABI. Please be careful.

Still I am not able to understand this comment. If you dont mind could
you please elaborate?

As per my understanding, we iterate on physical engines and execute the
execbuf on those engines.

-Ram.
> -Chris
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

  reply	other threads:[~2019-05-30 16:10 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-30 15:42 [igt-dev] [PATCH i-g-t v2 0/5] Engine discovery for few more tests Ramalingam C
2019-05-30 15:42 ` [igt-dev] [PATCH i-g-t v2 1/5] test/i915: gem_bad_reloc: use the gem_engine_topology library Ramalingam C
2019-06-06 14:06   ` Andi Shyti
2019-05-30 15:42 ` [igt-dev] [PATCH i-g-t v2 2/5] test/i915: gem_exec_async: " Ramalingam C
2019-05-30 15:44   ` Chris Wilson
2019-05-30 16:14     ` Ramalingam C
2019-06-06 14:09   ` Andi Shyti
2019-05-30 15:42 ` [igt-dev] [PATCH i-g-t v2 3/5] test/i915: gem_exec_capture: " Ramalingam C
2019-05-30 15:47   ` Chris Wilson
2019-05-30 15:59     ` Ramalingam C
2019-06-06 14:10   ` Andi Shyti
2019-05-30 15:42 ` [igt-dev] [PATCH i-g-t v2 4/5] test/i915: gem_exec_params: " Ramalingam C
2019-05-30 15:49   ` Chris Wilson
2019-05-30 16:13     ` Ramalingam C [this message]
2019-06-06 14:12   ` Andi Shyti
2019-05-30 15:42 ` [igt-dev] [PATCH i-g-t v2 5/5] test/prime_vgem: " Ramalingam C
2019-05-30 15:50   ` Chris Wilson
2019-05-30 16:05     ` Ramalingam C
2019-06-06 14:17   ` Andi Shyti
2019-06-06 14:38     ` Tvrtko Ursulin
2019-06-06 15:31       ` Ramalingam C
2019-06-06 15:34         ` Tvrtko Ursulin
2019-06-06 15:48           ` Ramalingam C
2019-06-06 15:57             ` Tvrtko Ursulin
2019-06-07 10:38             ` Andi Shyti
2019-06-07 10:34       ` Andi Shyti
2019-05-31 11:11 ` [igt-dev] ✓ Fi.CI.BAT: success for Engine discovery for few more tests Patchwork
2019-06-01  2:54 ` [igt-dev] ✗ Fi.CI.IGT: failure " Patchwork

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190530161329.GC16874@intel.com \
    --to=ramalingam.c@intel.com \
    --cc=chris@chris-wilson.co.uk \
    --cc=igt-dev@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox