[PATCH][test-suite] Use ctimeit rather than perf for PowerPC
hfinkel at anl.gov
Tue Jul 22 13:45:32 PDT 2014
----- Original Message -----
> From: "Bill Schmidt" <wschmidt at linux.vnet.ibm.com>
> To: llvm-commits at cs.uiuc.edu
> Sent: Tuesday, July 22, 2014 3:41:57 PM
> Subject: [PATCH][test-suite] Use ctimeit rather than perf for PowerPC
> [PATCH][test-suite] Use ctimeit rather than perf for PowerPC
> A relatively recent patch (r209797) changed RunSafely.sh to use the
> script, which uses perf when available in preference to ctimeit.
> This causes
> problems on some older PowerPC distros, where perf has been
> buggy. As a result, the entire test suite appears to fail. There
> occasionally appears to be some flaky behavior from perf on newer
> distros as
> well which is less well-understood, but again results in phantom
> IBM has recommended use of operf and ocount for a while in preference
> to perf.
> Therefore we'd like to opt out of using perf on PowerPC in this
> script, even
> when perf is available. As with targets where perf is unavailable,
> we would
> like to fall back to ctimeit instead. This patch checks "uname -m"
> for ppc64
> or ppc64le to do just that.
> Is this ok to commit?
Yes, go ahead.
> Index: tools/timeit.sh
> --- tools/timeit.sh (revision 213677)
> +++ tools/timeit.sh (working copy)
> @@ -1,6 +1,14 @@
> #! /bin/bash
> # A wrapper over perf to provide similar functionality to timeit.c
> +# Fall back to ctimeit for PowerPC
> +TARGET=`uname -m`
> +if [ \( $TARGET = "ppc64" \) -o \( $TARGET = "ppc64le" \) ]; then
> + $(dirname $0)/ctimeit $@
> + exit $?
> # Fallback to ctimeit if dependencies are not met
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
Assistant Computational Scientist
Leadership Computing Facility
Argonne National Laboratory
More information about the llvm-commits