Linux Netfilter discussions
 help / color / mirror / Atom feed
From: Kerin Millar <kfm@plushkava.net>
To: Anton <anton.khazan@gmail.com>
Cc: netfilter@vger.kernel.org
Subject: Re: Is there an efficient way to delete multiple elements from a set?
Date: Wed, 31 Jan 2024 22:39:47 +0000	[thread overview]
Message-ID: <20240131223947.525533518741b6cae01e2d6d@plushkava.net> (raw)
In-Reply-To: <CAJE3=wmhLSHY7Gqg7vHX_SAAYKx-PMQFC_i2iEek4mBnghyAbg@mail.gmail.com>

On Thu, 1 Feb 2024 00:13:37 +0200
Anton <anton.khazan@gmail.com> wrote:

> While this is better in theory, in practice no performance improvement
> is observed. This sort of detail is worth paying attention to in a
> loop. In a single operation, the 0.01s saved is insignificant.

It's not true that it is only worth paying attention to in a loop but I won't argue about it here. Suffice to say that it depends, in part, upon the ability of the program reading from the pipe to perform useful work while reading. There are plenty of programs that can. It seems that nft is not such a program, which I suppose makes sense.

Anyway, if the performance of nft seems unusually bad for deletions, it could be bug material.

-- 
Kerin Millar

  reply	other threads:[~2024-01-31 22:39 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-31  8:14 Is there an efficient way to delete multiple elements from a set? Anton
2024-01-31  8:21 ` Reindl Harald
2024-01-31  8:27   ` Anton
2024-01-31 12:20 ` Kerin Millar
2024-01-31 22:13   ` Anton
2024-01-31 22:39     ` Kerin Millar [this message]
2024-01-31 23:11       ` Anton
2024-02-01  9:41 ` Pablo Neira Ayuso
2024-02-01  9:42   ` Pablo Neira Ayuso
2024-02-01 10:24     ` Jozsef Kadlecsik
2024-02-01 12:20   ` Kerin Millar
2024-02-02  0:36     ` Anton

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=20240131223947.525533518741b6cae01e2d6d@plushkava.net \
    --to=kfm@plushkava.net \
    --cc=anton.khazan@gmail.com \
    --cc=netfilter@vger.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