public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [RFC] perf tools: Including pre-generated flex files
@ 2012-03-27 18:15 Arnaldo Carvalho de Melo
  2012-03-27 18:33 ` Ingo Molnar
  2012-03-28 19:46 ` [RFC] perf tools: Including pre-generated " Linus Torvalds
  0 siblings, 2 replies; 9+ messages in thread
From: Arnaldo Carvalho de Melo @ 2012-03-27 18:15 UTC (permalink / raw)
  To: Linus Torvalds
  Cc: Ingo Molnar, Peter Zijlstra, Jiri Olsa, Linux Kernel Mailing List

Hi Linus,

	We now use lex and bison for the events and PMU parser:

[acme@sandy linux]$ wc -l tools/perf/util/*.[yl]
  126 tools/perf/util/parse-events.l
  229 tools/perf/util/parse-events.y
   43 tools/perf/util/pmu.l
   93 tools/perf/util/pmu.y
  491 total

	Jiri and Peter agreed on having pre-generated files:

[acme@sandy linux]$ wc -l tools/perf/util/*-{bison,flex}.[ch]
  1917 tools/perf/util/parse-events-bison.c
    81 tools/perf/util/parse-events-bison.h
  1663 tools/perf/util/pmu-bison.c
    73 tools/perf/util/pmu-bison.h
  2272 tools/perf/util/parse-events-flex.c
   316 tools/perf/util/parse-events-flex.h
  1821 tools/perf/util/pmu-flex.c
   316 tools/perf/util/pmu-flex.h
  8459 total

so that we don't require even more tools to build the kernel, following
the precedent of:

[acme@sandy linux]$ wc -l scripts/*/*.[ch]_shipped
  1976 scripts/dtc/dtc-lexer.lex.c_shipped
  1946 scripts/dtc/dtc-parser.tab.c_shipped
    86 scripts/dtc/dtc-parser.tab.h_shipped
   220 scripts/genksyms/keywords.hash.c_shipped
  2245 scripts/genksyms/lex.lex.c_shipped
  2399 scripts/genksyms/parse.tab.c_shipped
    95 scripts/genksyms/parse.tab.h_shipped
   286 scripts/kconfig/zconf.hash.c_shipped
  2420 scripts/kconfig/zconf.lex.c_shipped
  2504 scripts/kconfig/zconf.tab.c_shipped
 14177 total
[acme@sandy linux]$

	But Ingo argues that flex and bison are just a yum/whatever
install away, so we shouldn't clutter the kernel git history with things
we can generate at build time.

	What is your take on this?

- Arnaldo

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2012-03-31  7:48 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-03-27 18:15 [RFC] perf tools: Including pre-generated flex files Arnaldo Carvalho de Melo
2012-03-27 18:33 ` Ingo Molnar
2012-03-29  6:43   ` Jiri Olsa
2012-03-31  7:47   ` [tip:perf/urgent] perf tools: Remove auto-generated bison/ " tip-bot for Ingo Molnar
2012-03-28 19:46 ` [RFC] perf tools: Including pre-generated " Linus Torvalds
2012-03-29 12:22   ` Jiri Olsa
2012-03-29 14:37     ` Arnaldo Carvalho de Melo
2012-03-29 14:38     ` Ingo Molnar
2012-03-29 15:45       ` Arnaldo Carvalho de Melo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox