mirror of https://github.com/xemu-project/xemu.git
Revert "Add support for generating a systemtap tapset static probes"
This reverts commit 2834c3e014
.
Conflicts:
Makefile.target
This commit is contained in:
parent
39deb1e496
commit
371c338eca
|
@ -41,18 +41,7 @@ kvm.o kvm-all.o vhost.o vhost_net.o: QEMU_CFLAGS+=$(KVM_CFLAGS)
|
||||||
config-target.h: config-target.h-timestamp
|
config-target.h: config-target.h-timestamp
|
||||||
config-target.h-timestamp: config-target.mak
|
config-target.h-timestamp: config-target.mak
|
||||||
|
|
||||||
ifdef CONFIG_SYSTEMTAP_TRACE
|
all: $(PROGS)
|
||||||
STPFILES+=$(QEMU_PROG).stp
|
|
||||||
|
|
||||||
$(QEMU_PROG).stp:
|
|
||||||
$(call quiet-command,sh $(SRC_PATH)/tracetool \
|
|
||||||
--$(TRACE_BACKEND) \
|
|
||||||
--bindir $(bindir) \
|
|
||||||
--target $(TARGET_ARCH) \
|
|
||||||
-s < $(SRC_PATH)/trace-events > $@," GEN $@")
|
|
||||||
endif
|
|
||||||
|
|
||||||
all: $(PROGS) $(STPFILES)
|
|
||||||
|
|
||||||
# Dummy command so that make thinks it has done something
|
# Dummy command so that make thinks it has done something
|
||||||
@true
|
@true
|
||||||
|
@ -360,10 +349,6 @@ ifneq ($(STRIP),)
|
||||||
$(STRIP) $(patsubst %,"$(DESTDIR)$(bindir)/%",$(PROGS))
|
$(STRIP) $(patsubst %,"$(DESTDIR)$(bindir)/%",$(PROGS))
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
ifdef CONFIG_SYSTEMTAP_TRACE
|
|
||||||
$(INSTALL_DIR) "$(DESTDIR)$(datadir)/../systemtap/tapset"
|
|
||||||
$(INSTALL_DATA) $(STPFILES) "$(DESTDIR)$(datadir)/../systemtap/tapset"
|
|
||||||
endif
|
|
||||||
|
|
||||||
# Include automatically generated dependency files
|
# Include automatically generated dependency files
|
||||||
-include $(wildcard *.d */*.d)
|
-include $(wildcard *.d */*.d)
|
||||||
|
|
|
@ -2192,10 +2192,6 @@ EOF
|
||||||
echo
|
echo
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
trace_backend_stap="no"
|
|
||||||
if has 'stap' ; then
|
|
||||||
trace_backend_stap="yes"
|
|
||||||
fi
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
##########################################
|
##########################################
|
||||||
|
@ -2649,9 +2645,6 @@ fi
|
||||||
if test "$trace_backend" = "simple"; then
|
if test "$trace_backend" = "simple"; then
|
||||||
trace_file="\"$trace_file-%u\""
|
trace_file="\"$trace_file-%u\""
|
||||||
fi
|
fi
|
||||||
if test "$trace_backend" = "dtrace" -a "$trace_backend_stap" = "yes" ; then
|
|
||||||
echo "CONFIG_SYSTEMTAP_TRACE=y" >> $config_host_mak
|
|
||||||
fi
|
|
||||||
echo "CONFIG_TRACE_FILE=$trace_file" >> $config_host_mak
|
echo "CONFIG_TRACE_FILE=$trace_file" >> $config_host_mak
|
||||||
|
|
||||||
echo "TOOLS=$tools" >> $config_host_mak
|
echo "TOOLS=$tools" >> $config_host_mak
|
||||||
|
|
92
tracetool
92
tracetool
|
@ -26,12 +26,6 @@ Output formats:
|
||||||
-h Generate .h file
|
-h Generate .h file
|
||||||
-c Generate .c file
|
-c Generate .c file
|
||||||
-d Generate .d file (DTrace only)
|
-d Generate .d file (DTrace only)
|
||||||
-s Generate .stp file (DTrace with SystemTAP only)
|
|
||||||
|
|
||||||
Options:
|
|
||||||
--bindir [bindir] QEMU binary install location
|
|
||||||
--target [arch] QEMU target architecture
|
|
||||||
|
|
||||||
EOF
|
EOF
|
||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
@ -396,54 +390,6 @@ linetod_end_dtrace()
|
||||||
EOF
|
EOF
|
||||||
}
|
}
|
||||||
|
|
||||||
linetos_begin_dtrace()
|
|
||||||
{
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
linetos_dtrace()
|
|
||||||
{
|
|
||||||
local name args arglist state
|
|
||||||
name=$(get_name "$1")
|
|
||||||
args=$(get_args "$1")
|
|
||||||
arglist=$(get_argnames "$1", "")
|
|
||||||
state=$(get_state "$1")
|
|
||||||
if [ "$state" = "0" ] ; then
|
|
||||||
name=${name##disable }
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "$target" = "i386" ]
|
|
||||||
then
|
|
||||||
binary="qemu"
|
|
||||||
else
|
|
||||||
binary="qemu-system-$target"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Define prototype for probe arguments
|
|
||||||
cat <<EOF
|
|
||||||
probe qemu.system.$target.$name = process("$bindir/$binary").mark("$name")
|
|
||||||
{
|
|
||||||
EOF
|
|
||||||
|
|
||||||
i=1
|
|
||||||
for arg in $arglist
|
|
||||||
do
|
|
||||||
cat <<EOF
|
|
||||||
$arg = \$arg$i;
|
|
||||||
EOF
|
|
||||||
i="$((i+1))"
|
|
||||||
done
|
|
||||||
|
|
||||||
cat <<EOF
|
|
||||||
}
|
|
||||||
EOF
|
|
||||||
}
|
|
||||||
|
|
||||||
linetos_end_dtrace()
|
|
||||||
{
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
# Process stdin by calling begin, line, and end functions for the backend
|
# Process stdin by calling begin, line, and end functions for the backend
|
||||||
convert()
|
convert()
|
||||||
{
|
{
|
||||||
|
@ -509,24 +455,6 @@ tracetod()
|
||||||
convert d
|
convert d
|
||||||
}
|
}
|
||||||
|
|
||||||
tracetos()
|
|
||||||
{
|
|
||||||
if [ $backend != "dtrace" ]; then
|
|
||||||
echo "SystemTAP tapset generator not applicable to $backend backend"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
if [ -z "$target" ]; then
|
|
||||||
echo "--target is required for SystemTAP tapset generator"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
if [ -z "$bindir" ]; then
|
|
||||||
echo "--bindir is required for SystemTAP tapset generator"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
echo "/* This file is autogenerated by tracetool, do not edit. */"
|
|
||||||
convert s
|
|
||||||
}
|
|
||||||
|
|
||||||
# Choose backend
|
# Choose backend
|
||||||
case "$1" in
|
case "$1" in
|
||||||
"--nop" | "--simple" | "--ust" | "--dtrace") backend="${1#--}" ;;
|
"--nop" | "--simple" | "--ust" | "--dtrace") backend="${1#--}" ;;
|
||||||
|
@ -534,30 +462,10 @@ case "$1" in
|
||||||
esac
|
esac
|
||||||
shift
|
shift
|
||||||
|
|
||||||
bindir=
|
|
||||||
case "$1" in
|
|
||||||
"--bindir")
|
|
||||||
bindir=$2
|
|
||||||
shift
|
|
||||||
shift
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
target=
|
|
||||||
case "$1" in
|
|
||||||
"--target")
|
|
||||||
target=$2
|
|
||||||
shift
|
|
||||||
shift
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
|
|
||||||
case "$1" in
|
case "$1" in
|
||||||
"-h") tracetoh ;;
|
"-h") tracetoh ;;
|
||||||
"-c") tracetoc ;;
|
"-c") tracetoc ;;
|
||||||
"-d") tracetod ;;
|
"-d") tracetod ;;
|
||||||
"-s") tracetos ;;
|
|
||||||
"--check-backend") exit 0 ;; # used by ./configure to test for backend
|
"--check-backend") exit 0 ;; # used by ./configure to test for backend
|
||||||
*) usage ;;
|
*) usage ;;
|
||||||
esac
|
esac
|
||||||
|
|
Loading…
Reference in New Issue