bpf.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jesper Dangaard Brouer <jbrouer@redhat.com>
To: "Björn Töpel" <bjorn.topel@gmail.com>
Cc: "Alexei Starovoitov" <ast@kernel.org>,
	"Daniel Borkmann" <daniel@iogearbox.net>,
	Netdev <netdev@vger.kernel.org>, bpf <bpf@vger.kernel.org>,
	"Björn Töpel" <bjorn.topel@intel.com>,
	"Karlsson, Magnus" <magnus.karlsson@intel.com>,
	"Fijalkowski, Maciej" <maciej.fijalkowski@intel.com>,
	"Jakub Kicinski" <kuba@kernel.org>,
	"Jonathan Lemon" <jonathan.lemon@gmail.com>,
	maximmi@nvidia.com, "David Miller" <davem@davemloft.net>,
	"Jesper Dangaard Brouer" <hawk@kernel.org>,
	"John Fastabend" <john.fastabend@gmail.com>,
	"Toke Høiland-Jørgensen" <toke@redhat.com>
Subject: Re: [RFC PATCH bpf-next] bpf, xdp: per-map bpf_redirect_map functions for XDP
Date: Fri, 29 Jan 2021 19:06:06 +0100	[thread overview]
Message-ID: <20210129190606.33c697cf@carbon> (raw)
In-Reply-To: <CAJ+HfNiFtRd-KKMB1t3Mi3MZ=C+u5TTM5YFnzJFfR4Ruzc7c9Q@mail.gmail.com>

On Fri, 29 Jan 2021 16:35:47 +0100
Björn Töpel <bjorn.topel@gmail.com> wrote:

> On Fri, 29 Jan 2021 at 16:32, Björn Töpel <bjorn.topel@gmail.com> wrote:
> >
> > From: Björn Töpel <bjorn.topel@intel.com>
> >  
> [...]
> >
> > For AF_XDP rxdrop this yields +600Mpps. I'll do CPU/DEVMAP
> > measurements for the patch proper.
> >  
> 
> Kpps, not Mpps. :-P

+600Kpps from 24Mpps to 24.6Mpps I assume.  This corresponds to approx
1 ns ((1/24-1/24.6)*1000 = 1.01626 ns).

This also correlate with saving one function call, which is basically
what the patch does.

Fresh measurement "Intel(R) Xeon(R) CPU E5-1650 v4 @ 3.60GHz" with [1]:
 time_bench: Type:funcion_call_cost Per elem: 3 cycles(tsc) 1.053 ns
 time_bench: Type:func_ptr_call_cost Per elem: 4 cycles(tsc) 1.317 ns

[1] https://github.com/netoptimizer/prototype-kernel/blob/master/kernel/lib/time_bench_sample.c
-- 
Best regards,
  Jesper Dangaard Brouer
  MSc.CS, Principal Kernel Engineer at Red Hat
  LinkedIn: http://www.linkedin.com/in/brouer


      parent reply	other threads:[~2021-01-29 18:08 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20210129153215.190888-1-bjorn.topel@gmail.com>
2021-01-29 16:45 ` Toke Høiland-Jørgensen
2021-02-01  6:27   ` Björn Töpel
2021-02-01  9:31     ` Jesper Dangaard Brouer
2021-02-01  9:49       ` Björn Töpel
     [not found] ` <CAJ+HfNiFtRd-KKMB1t3Mi3MZ=C+u5TTM5YFnzJFfR4Ruzc7c9Q@mail.gmail.com>
2021-01-29 18:06   ` Jesper Dangaard Brouer [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=20210129190606.33c697cf@carbon \
    --to=jbrouer@redhat.com \
    --cc=ast@kernel.org \
    --cc=bjorn.topel@gmail.com \
    --cc=bjorn.topel@intel.com \
    --cc=bpf@vger.kernel.org \
    --cc=daniel@iogearbox.net \
    --cc=davem@davemloft.net \
    --cc=hawk@kernel.org \
    --cc=john.fastabend@gmail.com \
    --cc=jonathan.lemon@gmail.com \
    --cc=kuba@kernel.org \
    --cc=maciej.fijalkowski@intel.com \
    --cc=magnus.karlsson@intel.com \
    --cc=maximmi@nvidia.com \
    --cc=netdev@vger.kernel.org \
    --cc=toke@redhat.com \
    --subject='Re: [RFC PATCH bpf-next] bpf, xdp: per-map bpf_redirect_map functions for XDP' \
    /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

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 NNTP newsgroup(s).