#!/bin/bash set -x set -e rm -f bug1040659-* armv7a-cros-linux-gnueabihf-gcc \ -marm -fno-omit-frame-pointer -O2 -mapcs-frame \ testcase.c -o bug1040659-gcc-arm-fp-apcs armv7a-cros-linux-gnueabihf-gcc \ -marm -fno-omit-frame-pointer -O2 \ testcase.c -o bug1040659-gcc-arm-fp armv7a-cros-linux-gnueabihf-gcc \ -mthumb -fno-omit-frame-pointer -O2 \ testcase.c -o bug1040659-gcc-thumb-fp armv7a-cros-linux-gnueabihf-clang \ -marm -fno-omit-frame-pointer -O2 \ testcase.c -o bug1040659-clang-arm-fp armv7a-cros-linux-gnueabihf-clang \ -mthumb -fno-omit-frame-pointer -O2 \ testcase.c -o bug1040659-clang-thumb-fp # It'd be nice if these worked but they don't seem to. # #armv7a-cros-linux-gnueabihf-clang \ # -marm -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -O2 \ # testcase.c -o bug1040659-clang-arm-fp-leaf # #armv7a-cros-linux-gnueabihf-clang \ # -mthumb -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -O2 \ # testcase.c -o bug1040659-clang-thumb-fp-leaf exit 0 # Here's how to actually test: # Good perf record -e cycles:u -g -o /tmp/bug1040659-gcc-arm-fp-apcs.data -- bug1040659-gcc-arm-fp-apcs 100000001 perf report -i /tmp/bug1040659-gcc-arm-fp-apcs.data -g flat # Good perf record -e cycles:u -g -o /tmp/bug1040659-gcc-arm-fp.data -- bug1040659-gcc-arm-fp 100000001 perf report -i /tmp/bug1040659-gcc-arm-fp.data -g flat # Fails (known) perf record -e cycles:u -g -o /tmp/bug1040659-gcc-thumb-fp.data -- bug1040659-gcc-thumb-fp 100000001 perf report -i /tmp/bug1040659-gcc-thumb-fp.data -g flat # Good perf record -e cycles:u -g -o /tmp/bug1040659-clang-arm-fp.data -- bug1040659-clang-arm-fp 100000001 perf report -i /tmp/bug1040659-clang-arm-fp.data -g flat perf record -e cycles:u -g -o /tmp/bug1040659-clang-thumb-fp.data -- bug1040659-clang-thumb-fp 100000001 perf report -i /tmp/bug1040659-clang-thumb-fp.data -g flat #perf record -e cycles:u -g -o /tmp/bug1040659-clang-arm-fp-leaf.data -- bug1040659-clang-arm-fp-leaf 100000001 #perf report -i /tmp/bug1040659-clang-arm-fp-leaf.data -g flat # #perf record -e cycles:u -g -o /tmp/bug1040659-clang-thumb-fp-leaf.data -- bug1040659-clang-thumb-fp-leaf 100000001 #perf report -i /tmp/bug1040659-clang-thumb-fp-leaf.data -g flat