This file is indexed.

/usr/share/sagemath/bin/sage-cachegrind is in sagemath-common 8.1-7ubuntu1.

This file is owned by root:root, with mode 0o755.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/usr/bin/env bash

# We reuse the gdb pythonstartup script.
PYTHONSTARTUP=$SAGE_SCRIPTS_DIR/sage-ipython
export PYTHONSTARTUP
echo $PYTHONSTARTUP
if [ ! -d "$DOT_SAGE/valgrind" ]; then
    mkdir "$DOT_SAGE/valgrind"
fi

LOG="$DOT_SAGE"/valgrind/sage-cachegrind.%p
echo "Log file is $LOG"

CACHEGRIND_FLAGS="--log-file=$LOG "; export CACHEGRIND_FLAGS
if [ "$SAGE_CACHEGRIND_FLAGS" ]; then
    echo "Overwriting cachegrind flags with:"
    echo $SAGE_CACHEGRIND_FLAGS
    CACHEGRIND_FLAGS=$SAGE_CACHEGRIND_FLAGS; export CACHEGRIND_FLAGS
else
    echo "Using default flags:"
    echo $CACHEGRIND_FLAGS
fi

valgrind --tool=cachegrind $CACHEGRIND_FLAGS python -i