user/dev discussion of public-inbox itself
 help / color / mirror / code / Atom feed
From: Eric Wong <e@80x24.org>
To: meta@public-inbox.org
Subject: [PATCH 0/3] treewide: getpid() syscall reduction
Date: Mon,  1 Apr 2024 06:49:35 +0000	[thread overview]
Message-ID: <20240401064938.2334883-1-e@80x24.org> (raw)

Nowadays, getpid() isn't cached on glibc and CPU vulnerability
mitigations make syscalls slower than before.  This makes strace
slower and more noisy, so introduce some fairly large changes
to reduce getpid() syscalls.  Maybe more coming soon...  I
noticed the noisyness while debugging a different problem a
while ago.

Eric Wong (3):
  lock: get rid of PID guard
  treewide: avoid getpid() for OnDestroy checks
  treewide: avoid getpid for more ownership checks

 lib/PublicInbox/CodeSearchIdx.pm  | 29 +++++++++++------------
 lib/PublicInbox/DS.pm             |  9 ++++----
 lib/PublicInbox/DSKQXS.pm         |  7 +++---
 lib/PublicInbox/Daemon.pm         | 38 ++++++++++++-------------------
 lib/PublicInbox/Git.pm            |  8 +++----
 lib/PublicInbox/IO.pm             | 12 ++++++----
 lib/PublicInbox/IPC.pm            | 12 ++++++----
 lib/PublicInbox/LEI.pm            |  8 +++----
 lib/PublicInbox/LeiALE.pm         |  7 +++---
 lib/PublicInbox/LeiMirror.pm      | 27 ++++++++++------------
 lib/PublicInbox/LeiP2q.pm         |  2 +-
 lib/PublicInbox/LeiStore.pm       |  3 ++-
 lib/PublicInbox/LeiTag.pm         |  8 +++----
 lib/PublicInbox/Lock.pm           |  8 +++----
 lib/PublicInbox/MHreader.pm       |  4 ++--
 lib/PublicInbox/MboxLock.pm       |  6 ++---
 lib/PublicInbox/OnDestroy.pm      | 27 ++++++++++++++--------
 lib/PublicInbox/SearchIdxShard.pm |  2 +-
 lib/PublicInbox/SpawnPP.pm        |  5 ++--
 lib/PublicInbox/TestCommon.pm     |  4 ++--
 lib/PublicInbox/Umask.pm          |  2 +-
 lib/PublicInbox/ViewVCS.pm        |  5 ++--
 lib/PublicInbox/Watch.pm          |  4 ++--
 lib/PublicInbox/WwwCoderepo.pm    |  2 +-
 lib/PublicInbox/XapClient.pm      |  2 +-
 lib/PublicInbox/XapHelper.pm      |  2 +-
 lib/PublicInbox/Xapcmd.pm         |  2 +-
 script/public-inbox-init          |  2 +-
 t/lei-sigpipe.t                   |  4 +---
 t/mbox_lock.t                     |  7 +++---
 t/mh_reader.t                     |  1 -
 t/on_destroy.t                    | 25 ++++++++++++--------
 t/spawn.t                         |  3 ++-
 xt/net_writer-imap.t              |  4 ++--
 34 files changed, 150 insertions(+), 141 deletions(-)


             reply	other threads:[~2024-04-01  6:49 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-01  6:49 Eric Wong [this message]
2024-04-01  6:49 ` [PATCH 1/3] lock: get rid of PID guard Eric Wong
2024-04-01  6:49 ` [PATCH 2/3] treewide: avoid getpid() for OnDestroy checks Eric Wong
2024-04-01  6:49 ` [PATCH 3/3] treewide: avoid getpid for more ownership checks Eric Wong

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

  List information: https://public-inbox.org/README

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

  git send-email \
    --in-reply-to=20240401064938.2334883-1-e@80x24.org \
    --to=e@80x24.org \
    --cc=meta@public-inbox.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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/public-inbox.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).