diff --git a/features/perf/perf-annotate-replace-expand-with-equivalent-sed-exp.patch b/features/perf/perf-annotate-replace-expand-with-equivalent-sed-exp.patch new file mode 100644 index 0000000000000000000000000000000000000000..f980f3113b89e8b6e71509185ec8d04a32a5f193 --- /dev/null +++ b/features/perf/perf-annotate-replace-expand-with-equivalent-sed-exp.patch @@ -0,0 +1,30 @@ +From 449f7f520350700858f21a5554b81cc8ad23267d Mon Sep 17 00:00:00 2001 +From: Tom Zanussi <tom.zanussi@intel.com> +Date: Fri, 5 Oct 2012 11:35:26 -0500 +Subject: [PATCH 2/2] perf annotate: replace 'expand' with equivalent sed + expression + +We don't have 'expand' in our userspace so we need to accomplish the +same thing using 'sed', which we do have. + +Signed-off-by: Tom Zanussi <tom.zanussi@intel.com> +--- + tools/perf/util/annotate.c | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/tools/perf/util/annotate.c b/tools/perf/util/annotate.c +index 08c6d13..5594936 100644 +--- a/tools/perf/util/annotate.c ++++ b/tools/perf/util/annotate.c +@@ -330,7 +330,7 @@ fallback: + snprintf(command, sizeof(command), + "objdump %s%s --start-address=0x%016" PRIx64 + " --stop-address=0x%016" PRIx64 +- " -d %s %s -C %s|grep -v %s|expand", ++ " -d %s %s -C %s|grep -v %s|sed 's/\t/ /g'", + disassembler_style ? "-M " : "", + disassembler_style ? disassembler_style : "", + map__rip_2objdump(map, sym->start), +-- +1.7.5.4 + diff --git a/features/perf/perf-tools-Fix-parallel-build.patch b/features/perf/perf-tools-Fix-parallel-build.patch new file mode 100644 index 0000000000000000000000000000000000000000..0c7178659a0c20350b02cc7a98288ea3ef0c6242 --- /dev/null +++ b/features/perf/perf-tools-Fix-parallel-build.patch @@ -0,0 +1,54 @@ +From 42dcd1f4e2d8c277285fdf771f3a094ad9e81518 Mon Sep 17 00:00:00 2001 +From: Eric Sandeen <sandeen@redhat.com> +Date: Thu, 20 Sep 2012 21:31:44 -0500 +Subject: [PATCH 1/2] perf tools: Fix parallel build + +Parallel builds of perf were failing for me on a 32p box, with: + + * new build flags or prefix +util/pmu.l:7:23: error: pmu-bison.h: No such file or directory + +... + +make: *** [util/pmu-flex.o] Error 1 +make: *** Waiting for unfinished jobs.... + +This can pretty quickly be seen by adding a sleep in front of the bison +calls in tools/perf/Makefile and running make -j4 on a smaller box i.e.: + + sleep 10; $(QUIET_BISON)$(BISON) -v util/pmu.y -d -o $(OUTPUT)util/pmu-bison.c + +Adding the following dependencies fixes it for me. + +Signed-off-by: Eric Sandeen <sandeen@redhat.com> +Reviewed-by: Namhyung Kim <namhyung@kernel.org> +Cc: Namhyung Kim <namhyung@kernel.org> +Link: http://lkml.kernel.org/r/505BD190.40707@redhat.com +Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> +--- + tools/perf/Makefile | 4 ++-- + 1 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/tools/perf/Makefile b/tools/perf/Makefile +index 3262f98..b223a60 100644 +--- a/tools/perf/Makefile ++++ b/tools/perf/Makefile +@@ -237,13 +237,13 @@ export PERL_PATH + FLEX = flex + BISON= bison + +-$(OUTPUT)util/parse-events-flex.c: util/parse-events.l ++$(OUTPUT)util/parse-events-flex.c: util/parse-events.l $(OUTPUT)util/parse-events-bison.c + $(QUIET_FLEX)$(FLEX) --header-file=$(OUTPUT)util/parse-events-flex.h -t util/parse-events.l > $(OUTPUT)util/parse-events-flex.c + + $(OUTPUT)util/parse-events-bison.c: util/parse-events.y + $(QUIET_BISON)$(BISON) -v util/parse-events.y -d -o $(OUTPUT)util/parse-events-bison.c + +-$(OUTPUT)util/pmu-flex.c: util/pmu.l ++$(OUTPUT)util/pmu-flex.c: util/pmu.l $(OUTPUT)util/pmu-bison.c + $(QUIET_FLEX)$(FLEX) --header-file=$(OUTPUT)util/pmu-flex.h -t util/pmu.l > $(OUTPUT)util/pmu-flex.c + + $(OUTPUT)util/pmu-bison.c: util/pmu.y +-- +1.7.5.4 + diff --git a/features/perf/perf.scc b/features/perf/perf.scc index 2cacf9ece2457255a3f7b2b3320b258be472aa22..63020a931212b5c10d59036ee8162f603ff99ae1 100644 --- a/features/perf/perf.scc +++ b/features/perf/perf.scc @@ -6,3 +6,5 @@ patch perf-change-root-to-prefix-for-python-install.patch patch perf-add-sgidefs.h-to-for-mips-builds.patch patch perf-add-SLANG_INC-for-slang.h.patch patch perf-temporary-gcc-4.7-build-fixes.patch +patch perf-tools-Fix-parallel-build.patch +patch perf-annotate-replace-expand-with-equivalent-sed-exp.patch