mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Markus Elfring <Markus.Elfring@web.de>
To: Reinette Chatre <reinette.chatre@intel.com>,
	x86@kernel.org, kernel-janitors@vger.kernel.org,
	Borislav Petkov <bp@alien8.de>,
	Dave Hansen <dave.hansen@linux.intel.com>,
	Fenghua Yu <fenghua.yu@intel.com>,
	"H. Peter Anvin" <hpa@zytor.com>, Ingo Molnar <mingo@redhat.com>,
	Thomas Gleixner <tglx@linutronix.de>
Cc: LKML <linux-kernel@vger.kernel.org>,
	Julia Lawall <julia.lawall@inria.fr>
Subject: Re: x86/resctrl: Use seq_putc() in two functions
Date: Wed, 17 Jul 2024 08:42:07 +0200	[thread overview]
Message-ID: <d4d6c5ec-f884-4942-b90e-a3b58edd1e4e@web.de> (raw)
In-Reply-To: <cb908d7f-db6a-4b04-8867-bf36fb2dd45f@intel.com>

>> Single characters should be put into a sequence.
>> Thus use the corresponding function “seq_putc”.
>>
>> This issue was transformed by using the Coccinelle software.
>
> Could you please point me to how you accomplished this?
…

Maybe.


> Is this a new coccinelle script outside of the kernel

I constructed small scripts for the semantic patch language according to
the presented code refactoring a while ago.


> or still on its way upstream?

I am curious if such a transformation approach can eventually be integrated
for the coccicheck tool.


> Could you please highlight the benefit of this change? Looking at seq_puts() implementation, thanks
> to [1], it seems to me these seq_puts() calls will result in seq_putc() anyway?

If the appropriate function call would be directly used, extra optimisation efforts can be avoided
by the compiler.

Regards,
Markus

      parent reply	other threads:[~2024-07-17  6:43 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-13  9:00 [PATCH] " Markus Elfring
2024-07-16 21:43 ` Reinette Chatre
2024-07-16 22:07   ` Christian Heusel
2024-07-17  6:58     ` Markus Elfring
2024-07-17  5:12   ` [PATCH] " Christophe JAILLET
2024-07-17  6:42   ` Markus Elfring [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=d4d6c5ec-f884-4942-b90e-a3b58edd1e4e@web.de \
    --to=markus.elfring@web.de \
    --cc=bp@alien8.de \
    --cc=dave.hansen@linux.intel.com \
    --cc=fenghua.yu@intel.com \
    --cc=hpa@zytor.com \
    --cc=julia.lawall@inria.fr \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=reinette.chatre@intel.com \
    --cc=tglx@linutronix.de \
    --cc=x86@kernel.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

all inboxes | Powered by JetHome®