public inbox for linux-rt-users@vger.kernel.org
 help / color / mirror / Atom feed
From: Crystal Wood <crwood@redhat.com>
To: Sebastian Andrzej Siewior <bigeasy@linutronix.de>,
	Costa Shulyupin <costa.shul@redhat.com>
Cc: linux-rt-users <linux-rt-users@vger.kernel.org>,
	John Kacur <jkacur@redhat.com>, Tomas Glozar <tglozar@redhat.com>
Subject: Re: [PATCH v1] cyclictest: Generate optstring dynamically from long_options
Date: Tue, 13 Jan 2026 17:41:43 -0600	[thread overview]
Message-ID: <8522afe144e1abec56404ba84923662786228eef.camel@redhat.com> (raw)
In-Reply-To: <20260113111449.ULgrZN6N@linutronix.de>

On Tue, 2026-01-13 at 12:14 +0100, Sebastian Andrzej Siewior wrote:
> On 2026-01-13 12:00:29 [+0200], Costa Shulyupin wrote:
> > On Tue, 13 Jan 2026 at 10:13, Sebastian Andrzej Siewior
> > <bigeasy@linutronix.de> wrote:
> > > GNU ARGP might be easier to parse and maintain in the long run
> > > especially if 20 other options are added.
> > >         https://www.gnu.org/software/libc/manual/html_node/Argp-Example-4.html
> > 
> > It looks impossible to port to ARGP without CLI change: cyclictest has
> > options with optional arguments (e.g., -a can mean 'use all CPUs' or
> > -a 0,2,4 means 'use specific CPUs'). ARGP handles these differently
> > than getopt_long.
> 
> I see. It looked nice and I assumed it supports the same features. But
> if optional arguments to options are not supported then it is probably
> not doable.

It does support optional arguments (OPTION_ARG_OPTIONAL) but
rtla/cyclictest use nonstandard syntax: "-a foo" rather than "-afoo" or
"--arg=foo".  We get away with this because there's no mixing of
argument and non-argument options to create ambiguity, and it's not
worth changing at this point.

-Crystal


  reply	other threads:[~2026-01-13 23:41 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-01-10 11:37 [PATCH v1] cyclictest: Generate optstring dynamically from long_options Costa Shulyupin
2026-01-12 21:13 ` Crystal Wood
2026-01-13  8:13   ` Sebastian Andrzej Siewior
2026-01-13 10:00     ` Costa Shulyupin
2026-01-13 11:14       ` Sebastian Andrzej Siewior
2026-01-13 23:41         ` Crystal Wood [this message]
2026-01-13 23:34     ` Crystal Wood
2026-01-13 12:45   ` Costa Shulyupin

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=8522afe144e1abec56404ba84923662786228eef.camel@redhat.com \
    --to=crwood@redhat.com \
    --cc=bigeasy@linutronix.de \
    --cc=costa.shul@redhat.com \
    --cc=jkacur@redhat.com \
    --cc=linux-rt-users@vger.kernel.org \
    --cc=tglozar@redhat.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox