File: test-json-instruction-count

package info (click to toggle)
libdbusmenu 18.10.20180917~bzr492%2Brepack1-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 15,316 kB
  • sloc: ansic: 11,181; makefile: 956; xml: 464; python: 202; sh: 20
file content (6 lines) | stat: -rwxr-xr-x 324 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
#!/bin/sh

COMMAND=$@
INSTRUCTIONS=`valgrind --tool=callgrind --callgrind-out-file=/dev/null --instr-atstart=no --collect-atstart=no --combine-dumps=yes $COMMAND 2>&1 > /dev/null | grep refs | grep I | tail --lines=1 | cut -d ":" -f 2 | sed -e 's/^[ \t]*//'`

echo "Instructions needed to execute '$COMMAND': $INSTRUCTIONS"