All of lore.kernel.org
 help / color / mirror / Atom feed
From: Philippe Gerum <rpm@xenomai.org>
To: Richard Weinberger <richard@nod.at>
Cc: Florian Bezdeka <florian.bezdeka@siemens.com>,
	xenomai <xenomai@xenomai.org>
Subject: Re: [PATCH 3/6] testsuite: Add a simple test driver for alchemytests
Date: Fri, 08 Apr 2022 14:01:17 +0200	[thread overview]
Message-ID: <87r167okbj.fsf@xenomai.org> (raw)
In-Reply-To: <271523130.229269.1649414962370.JavaMail.zimbra@nod.at>


Richard Weinberger <richard@nod.at> writes:

> Philippe,
>
> ----- Ursprüngliche Mail -----
>> Von: "Philippe Gerum" <rpm@xenomai.org>
>>> Why is this "special" cpu-affinity necessary? What would happen if we
>>> remove that? Asking because I want to make sure that we do not miss any
>>> concurrency problems by adding this constraint.
>>>
>> 
>> The reason to pin the threads on the same CPU is to guarantee an ideal
>> execution sequence for some tests provided the scheduling policy and/or
>> the synchronization mechanisms do behave as intended. Concurrency on
>> multiple CPU would break the assumptions about that ideal sequence.
>> 
>> For instance, you could not resort to any inter-thread synchronization
>> to prevent unwanted SMP concurrency when checking that a scheduling
>> policy is properly undergone, that would make the test irrelevant by
>> papering over local preemption issues if any.  So we pin all the threads
>> on the same CPU to exclude SMP, and only that.
>
> So the tests have assumptions about the scheduling order of threads?
> I always thought even with a single CPU such assumptions can break.
>

Not if the scheduling core Xenomai provides does its job properly.

-- 
Philippe.


  reply	other threads:[~2022-04-08 12:01 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-08  8:03 [PATCH 0/6] Revive alchemy tests Richard Weinberger
2022-04-08  8:03 ` [PATCH 1/6] testsuite: Move alchemy tests into testsuite/ Richard Weinberger
2022-04-08  8:03 ` [PATCH 2/6] testsuite: Hook up alchemytests Richard Weinberger
2022-04-14 11:12   ` Jan Kiszka
2022-04-14 11:17     ` Richard Weinberger
2022-04-14 11:27       ` Jan Kiszka
2022-04-14 11:32         ` Richard Weinberger
2022-04-08  8:03 ` [PATCH 3/6] testsuite: Add a simple test driver for alchemytests Richard Weinberger
2022-04-08  9:11   ` Bezdeka, Florian
2022-04-08  9:19     ` Richard Weinberger
2022-04-08 10:34     ` Philippe Gerum
2022-04-08 10:49       ` Richard Weinberger
2022-04-08 12:01         ` Philippe Gerum [this message]
2022-04-08 12:11           ` Richard Weinberger
2022-04-08  8:03 ` [PATCH 4/6] Remove old alchemy tests Makefile Richard Weinberger
2022-04-08  8:04 ` [PATCH 5/6] alchemytests: Fix gcc warning in buffer-1 Richard Weinberger
2022-04-08  8:04 ` [PATCH 6/6] alchemytests: Fix gcc warning in task-9 Richard Weinberger
2022-04-13 12:56 ` [PATCH 0/6] Revive alchemy tests Jan Kiszka
2022-04-13 14:14   ` Richard Weinberger
2022-04-13 18:58     ` Jan Kiszka

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=87r167okbj.fsf@xenomai.org \
    --to=rpm@xenomai.org \
    --cc=florian.bezdeka@siemens.com \
    --cc=richard@nod.at \
    --cc=xenomai@xenomai.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 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.