Dwarves Archive on lore.kernel.org
 help / color / Atom feed
From: Hao Luo <haoluo@google.com>
To: Alexei Starovoitov <alexei.starovoitov@gmail.com>
Cc: Arnaldo Carvalho de Melo <arnaldo.melo@gmail.com>,
	Andrii Nakryiko <andrii.nakryiko@gmail.com>,
	Daniel Borkmann <daniel@iogearbox.net>,
	dwarves@vger.kernel.org, Yonghong Song <yhs@fb.com>
Subject: Re: [PATCH 0/2] pahole: Make encoding percpu vars into BTF optional.
Date: Fri, 18 Sep 2020 21:00:10 -0700
Message-ID: <CA+khW7i5vWnUMCvHmtEDVUQ92Wy+sLhOmnLjHBgVUdgdMWKQdQ@mail.gmail.com> (raw)
In-Reply-To: <CAADnVQL_Qudg34PpgKDz4pObwUZBJfbmKm+NcSLiQf575JcvEQ@mail.gmail.com>

Hi Alexei,

I was syncing with Arnaldo offline on whether the change in Pahole was
enough for supporting percpu vars in BPF. While I think about it, I
felt it's better to have a flag in pahole to toggle the feature on and
off. My concern is mainly malformed BTF caused by the newly introduced
VAR entries. I've tested over some kernel configurations and compilers
but not confident enough.

I haven't thought about opt-out. Maybe we should use opt-out instead of opt-in?


On Fri, Sep 18, 2020 at 5:58 PM Alexei Starovoitov
<alexei.starovoitov@gmail.com> wrote:
> On Fri, Sep 18, 2020 at 1:41 PM Hao Luo <haoluo@google.com> wrote:
> >
> > Previous commit f3d9054ba8ff ("btf_encoder: Teach pahole to store
> > percpu variables in vmlinux BTF.") introduced a feature in btf_encoder
> > that encodes global symbols in BTF. However, this feature is not
> > protected by any flag. In order to avoid surprises after Pahole v1.18
> > rolls out, make this feature off by default and enable only upon
> > request. On the kernel side, we can add a Kconfig to enable this
> > new capability on an opt-in pattern.
> I think I've missed some earlier discussions and motivation for opt-in.
> Why opt-out is a problem?
> I would think the kernel build should always include percpu vars.

  reply index

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-18 20:40 Hao Luo
2020-09-18 20:40 ` [PATCH 1/2] btf_encoder: Make encoding " Hao Luo
2020-09-18 21:24   ` Arnaldo Carvalho de Melo
2020-09-18 21:26     ` Hao Luo
2020-09-18 21:40       ` Arnaldo Carvalho de Melo
2020-09-18 20:40 ` [PATCH 2/2] btf_encoder: Introduce option '--btf_encode_force' Hao Luo
2020-09-19  0:57 ` [PATCH 0/2] pahole: Make encoding percpu vars into BTF optional Alexei Starovoitov
2020-09-19  4:00   ` Hao Luo [this message]
2020-09-21 12:27     ` Arnaldo Carvalho de Melo

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:

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

  git send-email \
    --in-reply-to=CA+khW7i5vWnUMCvHmtEDVUQ92Wy+sLhOmnLjHBgVUdgdMWKQdQ@mail.gmail.com \
    --to=haoluo@google.com \
    --cc=alexei.starovoitov@gmail.com \
    --cc=andrii.nakryiko@gmail.com \
    --cc=arnaldo.melo@gmail.com \
    --cc=daniel@iogearbox.net \
    --cc=dwarves@vger.kernel.org \
    --cc=yhs@fb.com \


* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

Dwarves Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/dwarves/0 dwarves/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 dwarves dwarves/ https://lore.kernel.org/dwarves \
	public-inbox-index dwarves

Example config snippet for mirrors

Newsgroup available over NNTP:

AGPL code for this site: git clone https://public-inbox.org/public-inbox.git