Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1216829
| From | Ingo Molnar <mingo@kernel.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 0/4] x86/insn: perf tools: Add a few new x86 instructions |
| Date | 2015-09-01 15:00 +0200 |
| Message-ID | <q3Tkn-708-23@gated-at.bofh.it> (permalink) |
| References | <q3xWx-1u3-5@gated-at.bofh.it> <q3PA6-1Ef-21@gated-at.bofh.it> <q3S4W-5ix-25@gated-at.bofh.it> <q3SHE-6h9-11@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
* Adrian Hunter <adrian.hunter@intel.com> wrote:
> > Agreed, what I concern is that someone finds a bug and fixes one of them and
> > another is not fixed.
> >
> > I'll see the forked version and check if it can be merged into the kernel.
>
> Ever since Linus complained about perf tools including kernel headers, I have
> assumed we should have separate source code. That email thread was not cc'ed to
> a mailing list but here is a quote:
>
> Em Sat, Jul 04, 2015 at 08:53:46AM -0700, Linus Torvalds escreveu:
>
> > So this is more fundamental, and looks like it's just due to perf abusing the
> > kernel headers, and now that rbtree has rcu support ("rbtree: Make lockless
> > searches non-fatal"), it gets tons of headers included that really don't work
> > from user space.
> >
> > There might be other things going on, but the rbtree one seems to be a big
> > one. I think perf needs to get its own rbtree header or something, instead of
> > doing that insane "let's include random core kernel headers" thing.
Note that even plain copying and occasional back-merges isn't a bad solution: it's
better than 'messy sharing' of code.
But we can also share code in a bit more organized fashion, and any of the two
solutions I proposed solve these complications:
- if we do the diff -u check warning during perf build then the forked versions
won't stay forked for long. This is the simplest variant.
- if we librarize this functionality into tools/lib/x86/decode/ (and make sure
it's a library that can be linked into the kernel) then we are back to shared
code.
The problem wasn't to share code per se, the problem was to share code in a messy
way, without making it apparent that it's shared code: which made it easy to break
the tools/perf build via harmless looking kernel side changes.
Thanks,
Ingo
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH 0/4] x86/insn: perf tools: Add a few new x86 instructions Adrian Hunter <adrian.hunter@intel.com> - 2015-08-31 16:10 +0200
[PATCH 4/4] x86/insn: perf tools: Add new memory instructions Adrian Hunter <adrian.hunter@intel.com> - 2015-08-31 16:10 +0200
Re: [PATCH 0/4] x86/insn: perf tools: Add a few new x86 instructions Arnaldo Carvalho de Melo <acme@kernel.org> - 2015-08-31 16:50 +0200
Re: [PATCH 1/4] perf tools: Add a test for decoding of new x86 instructions Adrian Hunter <adrian.hunter@intel.com> - 2015-09-01 10:30 +0200
RE: [PATCH 1/4] perf tools: Add a test for decoding of new x86 instructions 平松雅巳 / HIRAMATU,MASAMI <masami.hiramatsu.pt@hitachi.com> - 2015-09-01 13:10 +0200
Re: [PATCH 0/4] x86/insn: perf tools: Add a few new x86 instructions Ingo Molnar <mingo@kernel.org> - 2015-09-01 11:00 +0200
RE: [PATCH 0/4] x86/insn: perf tools: Add a few new x86 instructions 平松雅巳 / HIRAMATU,MASAMI <masami.hiramatsu.pt@hitachi.com> - 2015-09-01 13:40 +0200
Re: [PATCH 0/4] x86/insn: perf tools: Add a few new x86 instructions Adrian Hunter <adrian.hunter@intel.com> - 2015-09-01 14:20 +0200
Re: [PATCH 0/4] x86/insn: perf tools: Add a few new x86 instructions Ingo Molnar <mingo@kernel.org> - 2015-09-01 15:00 +0200
RE: [PATCH 0/4] x86/insn: perf tools: Add a few new x86 instructions 平松雅巳 / HIRAMATU,MASAMI <masami.hiramatsu.pt@hitachi.com> - 2015-09-01 17:20 +0200
Re: [PATCH 0/4] x86/insn: perf tools: Add a few new x86 instructions Adrian Hunter <adrian.hunter@intel.com> - 2015-09-01 14:20 +0200
Re: [PATCH 0/4] x86/insn: perf tools: Add a few new x86 instructions Jiri Olsa <jolsa@redhat.com> - 2015-09-01 16:00 +0200
Re: [PATCH 0/4] x86/insn: perf tools: Add a few new x86 instructions Arnaldo Carvalho de Melo <acme@kernel.org> - 2015-09-01 17:00 +0200
Re: [PATCH 0/4] x86/insn: perf tools: Add a few new x86 instructions Arnaldo Carvalho de Melo <acme@kernel.org> - 2015-09-01 16:00 +0200
Re: [PATCH 0/4] x86/insn: perf tools: Add a few new x86 instructions Arnaldo Carvalho de Melo <acme@kernel.org> - 2015-09-01 22:00 +0200
Re: [PATCH 0/4] x86/insn: perf tools: Add a few new x86 instructions Jiri Olsa <jolsa@redhat.com> - 2015-09-02 08:00 +0200
RE: [PATCH 0/4] x86/insn: perf tools: Add a few new x86 instructions 平松雅巳 / HIRAMATU,MASAMI <masami.hiramatsu.pt@hitachi.com> - 2015-09-02 08:50 +0200
Re: [PATCH 0/4] x86/insn: perf tools: Add a few new x86 instructions Ingo Molnar <mingo@kernel.org> - 2015-09-02 09:40 +0200
RE: [PATCH 0/4] x86/insn: perf tools: Add a few new x86 instructions 平松雅巳 / HIRAMATU,MASAMI <masami.hiramatsu.pt@hitachi.com> - 2015-09-02 12:30 +0200
csiph-web