From: Boris Brezillon <boris.brezillon@collabora.com>
To: Daniel Almeida <daniel.almeida@collabora.com>
Cc: igt-dev@lists.freedesktop.org,
"Petri Latvala" <adrinael@adrinael.net>,
"Arkadiusz Hiler" <arek@hiler.eu>,
"Kamil Konieczny" <kamil.konieczny@linux.intel.com>,
"Juha-Pekka Heikkila" <juhapekka.heikkila@gmail.com>,
"Bhanuprakash Modem" <bhanuprakash.modem@gmail.com>,
"Steven Price" <steven.price@arm.com>,
"Liviu Dudau" <liviu.dudau@arm.com>,
"Adrián Larumbe" <adrian.larumbe@collabora.com>,
kernel@collabora.com
Subject: Re: [PATCH i-g-t v2 3/3] tests/panthor: Add scheduler tests
Date: Wed, 17 Dec 2025 16:38:36 +0100 [thread overview]
Message-ID: <20251217163836.0d0cfd0f@fedora> (raw)
In-Reply-To: <ED0823EA-DE53-40F5-BA9D-00BC407CCB1C@collabora.com>
On Wed, 3 Dec 2025 16:31:59 -0300
Daniel Almeida <daniel.almeida@collabora.com> wrote:
[...]
> > diff --git a/tests/panthor/panthor_sched.c b/tests/panthor/panthor_sched.c
> > new file mode 100644
> > index 000000000000..7cded16c0acd
> > --- /dev/null
> > +++ b/tests/panthor/panthor_sched.c
> > @@ -0,0 +1,338 @@
> > +// SPDX-License-Identifier: MIT
> > +// SPDX-FileCopyrightText: Copyright (C) 2025 Collabora Ltd.
> > +
> > +#include <stdint.h>
> > +#include <sys/mman.h>
> > +#include <unistd.h>
> > +
> > +#include "drm.h"
> > +#include "igt.h"
> > +#include "igt_core.h"
> > +#include "igt_panthor.h"
> > +#include "panthor_drm.h"
> > +
> > +static size_t
> > +infinite_incr_loop(uint64_t *cs, uint64_t counter_va)
> > +{
> > + const uint8_t counter_va_reg = 68;
> > + const uint8_t val_reg = 70;
> > + uint64_t instrs[] = {
> > + /* Load the source register ([r68; r69]) with the kernel address */
> > + cs_mov48(counter_va_reg, counter_va),
> > + /* Load a 0 into r70 */
>
> Load a 1
Oops, will fix the comment.
>
> > + cs_mov48(val_reg, 1),
> > + /* STORE_MULTIPLE: Store the first register to the address pointed to by
> > + * [r68; r69]
> > + */
> > + cs_stm64(counter_va_reg, val_reg, 0),
> > + cs_wait(1, false),
>
> Wait for what? All of these seem to be synchronous instructions?
Nope, load/store instructions are asynchronous, you need to wait for
the SB assigned to "other-asynchronous-ops" (defaults to zero) for the
mem operation to be effective.
>
> > + cs_add64(1, val_reg, val_reg),
> > + cs_branch(-4, CS_BRANCH_COND_ALWAYS, 0),
> > + };
>
> This looks good, but I tried it and this is the result:
If you're not testing with drm-misc-next, that's normal. Those tests
are added to make sure we don't regress those scheduling cases again.
prev parent reply other threads:[~2025-12-17 15:38 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-11-28 9:38 [PATCH i-g-t v2 0/3] tests/panthor: Add more tests Boris Brezillon
2025-11-28 9:38 ` [PATCH i-g-t v2 1/3] drm-uapi/panthor: Sync panthor uapi Boris Brezillon
2025-11-28 9:38 ` [PATCH i-g-t v2 2/3] tests/panthor: Add a test to make sure the buffer is zeroed at alloc time Boris Brezillon
2025-12-01 11:14 ` Kamil Konieczny
2025-12-01 13:25 ` Daniel Almeida
2025-12-01 15:19 ` Kamil Konieczny
2025-12-01 15:21 ` Daniel Almeida
2025-11-28 9:38 ` [PATCH i-g-t v2 3/3] tests/panthor: Add scheduler tests Boris Brezillon
2025-12-03 19:31 ` Daniel Almeida
2025-12-17 15:38 ` Boris Brezillon [this message]
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=20251217163836.0d0cfd0f@fedora \
--to=boris.brezillon@collabora.com \
--cc=adrian.larumbe@collabora.com \
--cc=adrinael@adrinael.net \
--cc=arek@hiler.eu \
--cc=bhanuprakash.modem@gmail.com \
--cc=daniel.almeida@collabora.com \
--cc=igt-dev@lists.freedesktop.org \
--cc=juhapekka.heikkila@gmail.com \
--cc=kamil.konieczny@linux.intel.com \
--cc=kernel@collabora.com \
--cc=liviu.dudau@arm.com \
--cc=steven.price@arm.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.