From 1b351ce0ad705a9099f1720a613681e80a3e3afb Mon Sep 17 00:00:00 2001 From: Thomas Rodgers Date: Wed, 4 May 2022 11:42:19 +0200 Subject: [PATCH 001/101] Rebuilt for Boost 1.78 --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index a74d4fb..c1b393f 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -118,7 +118,7 @@ m stapdev stapdev Name: systemtap Version: 4.7 -Release: 1%{?release_override}%{?dist} +Release: 2%{?release_override}%{?dist} # for version, see also configure.ac @@ -1275,6 +1275,9 @@ exit 0 # PRERELEASE %changelog +* Wed May 04 2022 Thomas Rodgers - 4.7-2 +- Rebuilt for Boost 1.78 + * Mon May 02 2022 Frank Ch. Eigler - 4.7-1 - Upstream release, see wiki page below for detailed notes. https://sourceware.org/systemtap/wiki/SystemTapReleases From 8d5d041590ab37e766ebf16828cc193424d6a15c Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Tue, 10 May 2022 09:56:18 +0200 Subject: [PATCH 002/101] Include downstream/RHEL tests Find new home for downstream RHEL tests. Upstream them. The set of tests used for fedora gating stays intact: The gating tests are only those having the tier1 tag set in their main.fmf file. The testplan plans/ci.fmf filters the others out from gating. The set of Fedora gating tests stays the same as it was before this change. --- plans/ci.fmf | 1 + tests/Regression/PR16166/main.fmf | 16 + tests/Regression/PR16166/runtest.sh | 67 +++ tests/Regression/PR16166/towers.c | 155 ++++++ .../RHEL6Feature-cpp-backtraces/README | 31 ++ .../backtrackator.stp | 15 + .../RHEL6Feature-cpp-backtraces/classes.cpp | 43 ++ .../RHEL6Feature-cpp-backtraces/classes.hpp | 16 + .../golden-ppc64-17.out | 142 ++++++ .../golden-ppc64.out | 76 +++ .../golden-s390x.out | 65 +++ .../golden.el9.aarch64.out | 153 ++++++ .../golden.el9.ppc64le.out | 142 ++++++ .../golden.el9.s390x.out | 153 ++++++ .../golden.el9.x86_64.out | 153 ++++++ .../RHEL6Feature-cpp-backtraces/golden.out | 142 ++++++ .../RHEL6Feature-cpp-backtraces/main.cpp | 10 + .../RHEL6Feature-cpp-backtraces/main.fmf | 14 + .../RHEL6Feature-cpp-backtraces/runtest.sh | 116 +++++ .../classes.cpp | 39 ++ .../golden.out | 16 + .../RHEL6Feature-cpp-ctors-and-dtors/main.fmf | 13 + .../runtest.sh | 52 ++ .../tracker.stp | 23 + .../RHEL6Feature-cpp-inheritance/classes.cpp | 56 +++ .../RHEL6Feature-cpp-inheritance/main.fmf | 13 + .../RHEL6Feature-cpp-inheritance/runtest.sh | 56 +++ .../RHEL6Feature-cpp-inheritance/tracker.stp | 6 + .../RHEL6Feature-cpp-methods/classes.cpp | 71 +++ .../RHEL6Feature-cpp-methods/golden.el7.out | 70 +++ .../RHEL6Feature-cpp-methods/golden.el8.out | 83 ++++ .../RHEL6Feature-cpp-methods/golden.out | 70 +++ .../golden_summary.out | 13 + .../RHEL6Feature-cpp-methods/main.fmf | 13 + .../RHEL6Feature-cpp-methods/runtest.sh | 72 +++ .../RHEL6Feature-cpp-methods/tracker.stp | 162 +++++++ .../main.fmf | 14 + .../runtest.sh | 49 ++ .../bz544960-no-cfa_ops-supplied/README | 63 +++ .../bz544960-no-cfa_ops-supplied/bdflush.stp | 8 + .../bz544960-no-cfa_ops-supplied/main.fmf | 14 + .../readpages.stp | 19 + .../bz544960-no-cfa_ops-supplied/runtest.sh | 48 ++ .../tcp.sendmsg.stp | 7 + .../bz706185-various-build-and-run/main.fmf | 15 + .../bz706185-various-build-and-run/runtest.sh | 87 ++++ .../softirq.run | 1 + .../softirq.stp | 3 + .../main.fmf | 15 + .../runtest.sh | 57 +++ .../dotest.sh | 28 ++ .../main.fmf | 14 + .../runtest.sh | 52 ++ .../hellotrace.stp | 8 + .../main.fmf | 14 + .../runtest.sh | 47 ++ tests/Regression/ipv6-tapset-support/main.fmf | 16 + .../ipv6-tapset-support/nfsd.proc.lookup.stp | 12 + .../Regression/ipv6-tapset-support/runtest.sh | 76 +++ .../irq-vector-tracepoints/main.fmf | 15 + .../irq-vector-tracepoints/runtest.sh | 74 +++ tests/Regression/netdev-receive/main.fmf | 14 + tests/Regression/netdev-receive/runtest.sh | 44 ++ .../main.fmf | 16 + .../runtest.sh | 55 +++ tests/Regression/python-probing/main.fmf | 8 +- .../second-command-not-captured/main.fmf | 16 + .../ruby-exercise.stp | 7 + .../second-command-not-captured/runtest.sh | 42 ++ .../second-command-not-captured/test.sh | 7 + .../main.fmf | 23 + .../runtest.sh | 184 +++++++ .../main.fmf | 14 + .../nfs.proc.read_setup.stp | 5 + .../runtest.sh | 45 ++ .../semantic-errors-bz1062076/main.fmf | 14 + .../semantic-errors-bz1062076/runtest.sh | 40 ++ .../semantic-errors-bz1062076/script.stp | 3 + .../semantic-errors-bz953776/main.fmf | 17 + .../semantic-errors-bz953776/runtest.sh | 161 +++++++ tests/Regression/small-tests/main.fmf | 3 +- tests/Regression/small-tests/runtest.sh | 39 ++ .../main.fmf | 14 + .../runtest.sh | 43 ++ .../main.fmf | 15 + .../runtest.sh | 74 +++ .../Regression/suspicious-RCU-usage/main.fmf | 14 + .../suspicious-RCU-usage/runtest.sh | 49 ++ .../main.fmf | 15 + .../runtest.sh | 76 +++ .../main.fmf | 14 + .../reproducer.stp | 10 + .../runtest.sh | 46 ++ .../trigger.sh | 7 + .../main.fmf | 14 + .../reproducer.stp | 6 + .../reproducer2.stp | 5 + .../runtest.sh | 45 ++ .../trigger.sh | 7 + .../testsuite-upstream-raw/check_BPF.sh | 158 ++++++ .../testsuite-upstream-raw/check_DEFAULT.sh | 55 +++ .../dg-extract-results.sh | 453 ++++++++++++++++++ .../helpers/createreport.sh | 49 ++ .../helpers/report-helper.sh | 130 +++++ .../testsuite-upstream-raw/helpers/wikiup | 22 + .../internal-watchdog.sh | 21 + .../testsuite-upstream-raw/main.fmf | 50 ++ .../testsuite-upstream-raw/runtest.sh | 282 +++++++++++ .../testsuite-upstream-raw/stap-prep | 150 ++++++ .../utrace-taskfinder-misses-events/main.fmf | 16 + .../pthreadtestcase.cpp | 35 ++ .../pthreadtestcase.stp | 28 ++ .../runtest.sh | 77 +++ .../main.fmf | 14 + .../runtest.sh | 73 +++ .../testpro/Makefile | 11 + .../testpro/nfs.proc.commit_done.c | 84 ++++ .../testpro/nfs.proc.commit_done.stp | 3 + .../testpro/test-for-nfs | 111 +++++ 119 files changed, 6120 insertions(+), 7 deletions(-) create mode 100644 tests/Regression/PR16166/main.fmf create mode 100755 tests/Regression/PR16166/runtest.sh create mode 100644 tests/Regression/PR16166/towers.c create mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/README create mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/backtrackator.stp create mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/classes.cpp create mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/classes.hpp create mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/golden-ppc64-17.out create mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/golden-ppc64.out create mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/golden-s390x.out create mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.aarch64.out create mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.ppc64le.out create mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.s390x.out create mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.x86_64.out create mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/golden.out create mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/main.cpp create mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf create mode 100755 tests/Regression/RHEL6Feature-cpp-backtraces/runtest.sh create mode 100644 tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/classes.cpp create mode 100644 tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/golden.out create mode 100644 tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/main.fmf create mode 100755 tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/runtest.sh create mode 100644 tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/tracker.stp create mode 100644 tests/Regression/RHEL6Feature-cpp-inheritance/classes.cpp create mode 100644 tests/Regression/RHEL6Feature-cpp-inheritance/main.fmf create mode 100755 tests/Regression/RHEL6Feature-cpp-inheritance/runtest.sh create mode 100644 tests/Regression/RHEL6Feature-cpp-inheritance/tracker.stp create mode 100644 tests/Regression/RHEL6Feature-cpp-methods/classes.cpp create mode 100644 tests/Regression/RHEL6Feature-cpp-methods/golden.el7.out create mode 100644 tests/Regression/RHEL6Feature-cpp-methods/golden.el8.out create mode 100644 tests/Regression/RHEL6Feature-cpp-methods/golden.out create mode 100644 tests/Regression/RHEL6Feature-cpp-methods/golden_summary.out create mode 100644 tests/Regression/RHEL6Feature-cpp-methods/main.fmf create mode 100755 tests/Regression/RHEL6Feature-cpp-methods/runtest.sh create mode 100644 tests/Regression/RHEL6Feature-cpp-methods/tracker.stp create mode 100644 tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/main.fmf create mode 100755 tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/runtest.sh create mode 100644 tests/Regression/bz544960-no-cfa_ops-supplied/README create mode 100644 tests/Regression/bz544960-no-cfa_ops-supplied/bdflush.stp create mode 100644 tests/Regression/bz544960-no-cfa_ops-supplied/main.fmf create mode 100644 tests/Regression/bz544960-no-cfa_ops-supplied/readpages.stp create mode 100755 tests/Regression/bz544960-no-cfa_ops-supplied/runtest.sh create mode 100644 tests/Regression/bz544960-no-cfa_ops-supplied/tcp.sendmsg.stp create mode 100644 tests/Regression/bz706185-various-build-and-run/main.fmf create mode 100755 tests/Regression/bz706185-various-build-and-run/runtest.sh create mode 100644 tests/Regression/bz706185-various-build-and-run/softirq.run create mode 100644 tests/Regression/bz706185-various-build-and-run/softirq.stp create mode 100644 tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/main.fmf create mode 100755 tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/runtest.sh create mode 100644 tests/Regression/elfutils-debuginfod-client-not-being-called/dotest.sh create mode 100644 tests/Regression/elfutils-debuginfod-client-not-being-called/main.fmf create mode 100755 tests/Regression/elfutils-debuginfod-client-not-being-called/runtest.sh create mode 100644 tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/hellotrace.stp create mode 100644 tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/main.fmf create mode 100755 tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/runtest.sh create mode 100644 tests/Regression/ipv6-tapset-support/main.fmf create mode 100755 tests/Regression/ipv6-tapset-support/nfsd.proc.lookup.stp create mode 100755 tests/Regression/ipv6-tapset-support/runtest.sh create mode 100644 tests/Regression/irq-vector-tracepoints/main.fmf create mode 100755 tests/Regression/irq-vector-tracepoints/runtest.sh create mode 100644 tests/Regression/netdev-receive/main.fmf create mode 100755 tests/Regression/netdev-receive/runtest.sh create mode 100644 tests/Regression/pass-4-failure-netfilter-examples/main.fmf create mode 100755 tests/Regression/pass-4-failure-netfilter-examples/runtest.sh create mode 100644 tests/Regression/second-command-not-captured/main.fmf create mode 100644 tests/Regression/second-command-not-captured/ruby-exercise.stp create mode 100755 tests/Regression/second-command-not-captured/runtest.sh create mode 100755 tests/Regression/second-command-not-captured/test.sh create mode 100644 tests/Regression/selected-parts-of-upstream-testsuite/main.fmf create mode 100755 tests/Regression/selected-parts-of-upstream-testsuite/runtest.sh create mode 100644 tests/Regression/semantic-error-nfs-proc-read_setup/main.fmf create mode 100644 tests/Regression/semantic-error-nfs-proc-read_setup/nfs.proc.read_setup.stp create mode 100755 tests/Regression/semantic-error-nfs-proc-read_setup/runtest.sh create mode 100644 tests/Regression/semantic-errors-bz1062076/main.fmf create mode 100755 tests/Regression/semantic-errors-bz1062076/runtest.sh create mode 100644 tests/Regression/semantic-errors-bz1062076/script.stp create mode 100644 tests/Regression/semantic-errors-bz953776/main.fmf create mode 100755 tests/Regression/semantic-errors-bz953776/runtest.sh create mode 100644 tests/Regression/stap-ERROR-Build-id-mismatch-with/main.fmf create mode 100755 tests/Regression/stap-ERROR-Build-id-mismatch-with/runtest.sh create mode 100644 tests/Regression/stapio-possible-circular-locking-dependency/main.fmf create mode 100755 tests/Regression/stapio-possible-circular-locking-dependency/runtest.sh create mode 100644 tests/Regression/suspicious-RCU-usage/main.fmf create mode 100755 tests/Regression/suspicious-RCU-usage/runtest.sh create mode 100644 tests/Regression/syscall-get-arguments-returning-wrong-value/main.fmf create mode 100755 tests/Regression/syscall-get-arguments-returning-wrong-value/runtest.sh create mode 100644 tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/main.fmf create mode 100644 tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/reproducer.stp create mode 100755 tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/runtest.sh create mode 100755 tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/trigger.sh create mode 100644 tests/Regression/task-exe-file-results-in-an-file-struct-leak/main.fmf create mode 100644 tests/Regression/task-exe-file-results-in-an-file-struct-leak/reproducer.stp create mode 100644 tests/Regression/task-exe-file-results-in-an-file-struct-leak/reproducer2.stp create mode 100755 tests/Regression/task-exe-file-results-in-an-file-struct-leak/runtest.sh create mode 100755 tests/Regression/task-exe-file-results-in-an-file-struct-leak/trigger.sh create mode 100755 tests/Regression/testsuite-upstream-raw/check_BPF.sh create mode 100755 tests/Regression/testsuite-upstream-raw/check_DEFAULT.sh create mode 100755 tests/Regression/testsuite-upstream-raw/dg-extract-results.sh create mode 100755 tests/Regression/testsuite-upstream-raw/helpers/createreport.sh create mode 100755 tests/Regression/testsuite-upstream-raw/helpers/report-helper.sh create mode 100755 tests/Regression/testsuite-upstream-raw/helpers/wikiup create mode 100755 tests/Regression/testsuite-upstream-raw/internal-watchdog.sh create mode 100644 tests/Regression/testsuite-upstream-raw/main.fmf create mode 100755 tests/Regression/testsuite-upstream-raw/runtest.sh create mode 100755 tests/Regression/testsuite-upstream-raw/stap-prep create mode 100644 tests/Regression/utrace-taskfinder-misses-events/main.fmf create mode 100644 tests/Regression/utrace-taskfinder-misses-events/pthreadtestcase.cpp create mode 100644 tests/Regression/utrace-taskfinder-misses-events/pthreadtestcase.stp create mode 100755 tests/Regression/utrace-taskfinder-misses-events/runtest.sh create mode 100644 tests/Regression/wrong-data-returned-by-nfs-commit-done/main.fmf create mode 100755 tests/Regression/wrong-data-returned-by-nfs-commit-done/runtest.sh create mode 100644 tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/Makefile create mode 100644 tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/nfs.proc.commit_done.c create mode 100644 tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/nfs.proc.commit_done.stp create mode 100755 tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/test-for-nfs diff --git a/plans/ci.fmf b/plans/ci.fmf index e1aad9b..a9301ab 100644 --- a/plans/ci.fmf +++ b/plans/ci.fmf @@ -2,6 +2,7 @@ summary: CI Gating Plan discover: how: fmf directory: tests + filter: 'tier: 1' prepare: how: install exclude: diff --git a/tests/Regression/PR16166/main.fmf b/tests/Regression/PR16166/main.fmf new file mode 100644 index 0000000..9a85d18 --- /dev/null +++ b/tests/Regression/PR16166/main.fmf @@ -0,0 +1,16 @@ +summary: Test for BZ#1054962 (Backport PR16166 stap -vvv causes SIGSEGV when) +description: Backport PR16166 +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +require: +recommend: + - valgrind + - systemtap +duration: 15m +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1054962 +extra-summary: /tools/systemtap/Regression/PR16166 +extra-task: /tools/systemtap/Regression/PR16166 diff --git a/tests/Regression/PR16166/runtest.sh b/tests/Regression/PR16166/runtest.sh new file mode 100755 index 0000000..b2b2258 --- /dev/null +++ b/tests/Regression/PR16166/runtest.sh @@ -0,0 +1,67 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/PR16166 +# Description: Test for BZ#1054962 (Backport PR16166 stap -vvv causes SIGSEGV when) +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2014 Red Hat, Inc. +# +# This copyrighted material is made available to anyone wishing +# to use, modify, copy, or redistribute it subject to the terms +# and conditions of the GNU General Public License version 2. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public +# License along with this program; if not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +# Boston, MA 02110-1301, USA. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +rlJournalStart + rlPhaseStartSetup + rlRun "TMPDIR=\$(mktemp -d)" + rlRun "cp towers.c $TMPDIR/" + rlRun "pushd $TMPDIR" + + rlRun "gcc -g towers.c -o towers.x" + + cat > script.stp <<-EOF +global x + +probe perf.hw.cpu_cycles.process("towers.x").counter("a") {} + +probe process("towers.x").function("main") +{ + # wrong type + x = "b" . @perf("a") +} +EOF + rlRun "which valgrind" + rlRun "valgrind --version" + rlPhaseEnd + + rlPhaseStartTest + # following is expected to fail + rlRun "valgrind --log-file=output.txt stap -vvv script.stp" 1 + # ... but not to segfault + rlRun "grep SIGSEGV output.txt" 1 + rlPhaseEnd + + rlPhaseStartCleanup + rlRun "popd" + rlRun "rm -r $TMPDIR" + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/PR16166/towers.c b/tests/Regression/PR16166/towers.c new file mode 100644 index 0000000..6465bc4 --- /dev/null +++ b/tests/Regression/PR16166/towers.c @@ -0,0 +1,155 @@ +# include +# include + +#define towersbase 2.39 + +/* Towers */ +#define maxcells 18 +#define stackrange 3 +#define true 1 +#define false 0 + +struct element +{ + int discsize; + int next; +}; + +/* Towers */ +int stack[stackrange + 1]; +struct element cellspace[maxcells + 1]; +int freelist, movesdone; + +/* Program to Solve the Towers of Hanoi */ + +void +error (emsg) + char *emsg; +{ + printf ("Error in Towers: %s\n", emsg); +} + +void +makenull (s) +{ + stack[s] = 0; +} + +int +get_element () +{ + int temp; + if (freelist > 0) + { + temp = freelist; + freelist = cellspace[freelist].next; + } + else + error ("out of space "); + return (temp); +} + +void +push (i, s) + int i, s; +{ + int errorfound, localel; + errorfound = false; + if (stack[s] > 0) + if (cellspace[stack[s]].discsize <= i) + { + errorfound = true; + error ("disc size error"); + }; + if (!errorfound) + { + localel = get_element (); + cellspace[localel].next = stack[s]; + stack[s] = localel; + cellspace[localel].discsize = i; + } +} + +void +init (s, n) + int s, n; +{ + int discctr; + makenull (s); + for (discctr = n; discctr >= 1; discctr--) + push (discctr, s); +} + +int +pop (s) + int s; +{ + int temp, temp1; + if (stack[s] > 0) + { + temp1 = cellspace[stack[s]].discsize; + temp = cellspace[stack[s]].next; + cellspace[stack[s]].next = freelist; + freelist = stack[s]; + stack[s] = temp; + return (temp1); + } + else + error ("nothing to pop "); + return 0; +} + +void +move (s1, s2) + int s1, s2; +{ + push (pop (s1), s2); + movesdone = movesdone + 1; +} + +void +tower (i, j, k) + int i, j, k; +{ + int other; + if (k == 1) + move (i, j); + else + { + other = 6 - i - j; + tower (i, other, k - 1); + move (i, j); + tower (other, j, k - 1); + } +} + + +void +towers () +{ + int i; + for (i = 1; i <= maxcells; i++) + cellspace[i].next = i - 1; + freelist = maxcells; + init (1, 14); + makenull (2); + makenull (3); + movesdone = 0; + tower (1, 2, 14); + if (movesdone != 16383) + printf (" error in Towers.\n"); +} + +#ifndef LOOP +#define LOOP 500 +#endif + +int +main () +{ + int i; + for (i= 0; i < LOOP; i++) + towers(); + return 0; +} + diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/README b/tests/Regression/RHEL6Feature-cpp-backtraces/README new file mode 100644 index 0000000..3211489 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/README @@ -0,0 +1,31 @@ + +With 5.18.0-0.rc5.20220504git107c948d1d3e61d.42.fc37.x86_64 we have + + + +---------------------8<-------------------------------------------------------- +:: [ 08:26:39 ] :: [ BEGIN ] :: Running 'stap --skip-badvars --ldd backtrackator.stp -c ./classes > output.out' +In file included from /usr/share/systemtap/runtime/linux/../regs.c:20, + from /usr/share/systemtap/runtime/linux/runtime.h:270, + from /usr/share/systemtap/runtime/runtime.h:26, + from /tmp/stap7hYYpn/stap_9beffd9064cc2c18ddd2daf7f47a7e44_5966_src.c:21: +/usr/share/systemtap/runtime/stack.c: In function ‘_stp_stack_unwind_one_kernel’: +/usr/share/systemtap/runtime/linux/../linux/regs.c:23:32: error: ‘struct kretprobe_instance’ has no member named ‘ret_addr’ + 23 | #define _stp_ret_addr_r(ri) (ri->ret_addr) + | ^~ +/usr/share/systemtap/runtime/stack.c:358:47: note: in expansion of macro ‘_stp_ret_addr_r’ + 358 | return (unsigned long)_stp_ret_addr_r(c->ips.krp.pi); + | ^~~~~~~~~~~~~~~ +make[1]: *** [scripts/Makefile.build:288: /tmp/stap7hYYpn/stap_9beffd9064cc2c18ddd2daf7f47a7e44_5966_src.o] Error 1 +make[1]: *** Waiting for unfinished jobs.... +make: *** [Makefile:1844: /tmp/stap7hYYpn] Error 2 +WARNING: kbuild exited with status: 2 +Pass 4: compilation failed. [man error::pass4] +:: [ 08:26:59 ] :: [ FAIL ] :: Command 'stap --skip-badvars --ldd backtrackator.stp -c ./classes > output.out' (Expected 0, got 1) +---------------------8<-------------------------------------------------------- + + +Related to CONFIG_KRETPROBE_ON_RETHOOK https://elixir.bootlin.com/linux/v5.18-rc5/source/include/linux/kprobes.h#L163 + + +Needs fixing on the stap side. diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/backtrackator.stp b/tests/Regression/RHEL6Feature-cpp-backtraces/backtrackator.stp new file mode 100644 index 0000000..18a4248 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/backtrackator.stp @@ -0,0 +1,15 @@ +function mypr:long(){ + printf("================================================================================\n"); + printf("Probed function: [%s]\n\n", probefunc()); + printf ("Backtrace:\n"); + + print_ubacktrace(); + return 0; +} + + + +probe process("classes").function("public*") { mypr(); } +probe process("classes").function("private*") { mypr(); } +probe process("classes").function("recursive*") { mypr(); } +probe process("classes").function("main*") { mypr(); } diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/classes.cpp b/tests/Regression/RHEL6Feature-cpp-backtraces/classes.cpp new file mode 100644 index 0000000..1c42084 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/classes.cpp @@ -0,0 +1,43 @@ +#include "classes.hpp" +#include + +void A::privateA1(){ + std::cout << "privateA1" << std::endl; + this->privateA2(); + +} + +void A::privateA2(){ + std::cout << "privateA2" << std::endl; + this->recursiveA1(3); + +} + +void A::recursiveA1(int count){ + std::cout << "recursiveA1: " << count << std::endl; + if (count == 0) + return; + this->recursiveA1(count-1); + return; +} + +void A::publicA1(){ + std::cout << "publicA1" << std::endl; + this->publicA2(); +} + +void A::publicA2(){ + std::cout << "publicA2" << std::endl; + this->privateA1(); +} + + +void B::privateB1(A a){ + std::cout << "privateB1" << std::endl; + a.publicA1(); +} + +void B::publicB1(A a){ + std::cout << "publicB1" << std::endl; + this->privateB1(a); +} diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/classes.hpp b/tests/Regression/RHEL6Feature-cpp-backtraces/classes.hpp new file mode 100644 index 0000000..0846ae2 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/classes.hpp @@ -0,0 +1,16 @@ +class A{ + private: + void privateA1(); + void privateA2(); + void recursiveA1(int); + public: + void publicA1(); + void publicA2(); +}; + +class B{ + private: + void privateB1(A); + public: + void publicB1(A); +}; diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden-ppc64-17.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden-ppc64-17.out new file mode 100644 index 0000000..1a9d1ce --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/golden-ppc64-17.out @@ -0,0 +1,142 @@ +publicB1 +privateB1 +publicA1 +publicA2 +privateA1 +privateA2 +recursiveA1: 3 +recursiveA1: 2 +recursiveA1: 1 +recursiveA1: 0 +================================================================================ +Probed function: [main] + +Backtrace: + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicB1] + +Backtrace: + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateB1] + +Backtrace: + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicA1] + +Backtrace: + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicA2] + +Backtrace: + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateA1] + +Backtrace: + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateA2] + +Backtrace: + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden-ppc64.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden-ppc64.out new file mode 100644 index 0000000..0f98c88 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/golden-ppc64.out @@ -0,0 +1,76 @@ +publicB1 +privateB1 +publicA1 +publicA2 +privateA1 +privateA2 +recursiveA1: 3 +recursiveA1: 2 +recursiveA1: 1 +recursiveA1: 0 +================================================================================ +Probed function: [main] + +Backtrace: + ADDRESS : main+ADDRESS/ADDRESS [PATH] +[ADDRESS] [ADDRESS] ADDRESS (inexact) +================================================================================ +Probed function: [publicB1] + +Backtrace: + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] +[ADDRESS] [ADDRESS] ADDRESS (inexact) +================================================================================ +Probed function: [privateB1] + +Backtrace: + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] +[ADDRESS] [ADDRESS] ADDRESS (inexact) +================================================================================ +Probed function: [publicA1] + +Backtrace: + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] +[ADDRESS] [ADDRESS] ADDRESS (inexact) +================================================================================ +Probed function: [publicA2] + +Backtrace: + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] +[ADDRESS] [ADDRESS] ADDRESS (inexact) +================================================================================ +Probed function: [privateA1] + +Backtrace: + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] +[ADDRESS] [ADDRESS] ADDRESS (inexact) +================================================================================ +Probed function: [privateA2] + +Backtrace: + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] +[ADDRESS] [ADDRESS] ADDRESS (inexact) +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] +[ADDRESS] [ADDRESS] ADDRESS (inexact) +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] +[ADDRESS] [ADDRESS] ADDRESS (inexact) +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] +[ADDRESS] [ADDRESS] ADDRESS (inexact) +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] +[ADDRESS] [ADDRESS] ADDRESS (inexact) diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden-s390x.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden-s390x.out new file mode 100644 index 0000000..1f5f902 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/golden-s390x.out @@ -0,0 +1,65 @@ +publicB1 +privateB1 +publicA1 +publicA2 +privateA1 +privateA2 +recursiveA1: 3 +recursiveA1: 2 +recursiveA1: 1 +recursiveA1: 0 +================================================================================ +Probed function: [main] + +Backtrace: + ADDRESS : main+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicB1] + +Backtrace: + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateB1] + +Backtrace: + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicA1] + +Backtrace: + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicA2] + +Backtrace: + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateA1] + +Backtrace: + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateA2] + +Backtrace: + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.aarch64.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.aarch64.out new file mode 100644 index 0000000..15c7b1e --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.aarch64.out @@ -0,0 +1,153 @@ +publicB1 +privateB1 +publicA1 +publicA2 +privateA1 +privateA2 +recursiveA1: 3 +recursiveA1: 2 +recursiveA1: 1 +recursiveA1: 0 +================================================================================ +Probed function: [main] + +Backtrace: + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicB1] + +Backtrace: + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateB1] + +Backtrace: + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicA1] + +Backtrace: + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicA2] + +Backtrace: + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateA1] + +Backtrace: + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateA2] + +Backtrace: + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.ppc64le.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.ppc64le.out new file mode 100644 index 0000000..64f2232 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.ppc64le.out @@ -0,0 +1,142 @@ +publicB1 +privateB1 +publicA1 +publicA2 +privateA1 +privateA2 +recursiveA1: 3 +recursiveA1: 2 +recursiveA1: 1 +recursiveA1: 0 +================================================================================ +Probed function: [main] + +Backtrace: + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicB1] + +Backtrace: + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateB1] + +Backtrace: + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicA1] + +Backtrace: + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicA2] + +Backtrace: + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateA1] + +Backtrace: + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateA2] + +Backtrace: + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.s390x.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.s390x.out new file mode 100644 index 0000000..c0c1262 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.s390x.out @@ -0,0 +1,153 @@ +publicB1 +privateB1 +publicA1 +publicA2 +privateA1 +privateA2 +recursiveA1: 3 +recursiveA1: 2 +recursiveA1: 1 +recursiveA1: 0 +================================================================================ +Probed function: [main] + +Backtrace: + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicB1] + +Backtrace: + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateB1] + +Backtrace: + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicA1] + +Backtrace: + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicA2] + +Backtrace: + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateA1] + +Backtrace: + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateA2] + +Backtrace: + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.x86_64.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.x86_64.out new file mode 100644 index 0000000..ac8d8c9 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.x86_64.out @@ -0,0 +1,153 @@ +publicB1 +privateB1 +publicA1 +publicA2 +privateA1 +privateA2 +recursiveA1: 3 +recursiveA1: 2 +recursiveA1: 1 +recursiveA1: 0 +================================================================================ +Probed function: [main] + +Backtrace: + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicB1] + +Backtrace: + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateB1] + +Backtrace: + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicA1] + +Backtrace: + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicA2] + +Backtrace: + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateA1] + +Backtrace: + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateA2] + +Backtrace: + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.out new file mode 100644 index 0000000..5013977 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.out @@ -0,0 +1,142 @@ +publicB1 +privateB1 +publicA1 +publicA2 +privateA1 +privateA2 +recursiveA1: 3 +recursiveA1: 2 +recursiveA1: 1 +recursiveA1: 0 +================================================================================ +Probed function: [main] + +Backtrace: + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicB1] + +Backtrace: + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateB1] + +Backtrace: + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicA1] + +Backtrace: + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicA2] + +Backtrace: + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateA1] + +Backtrace: + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateA2] + +Backtrace: + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/main.cpp b/tests/Regression/RHEL6Feature-cpp-backtraces/main.cpp new file mode 100644 index 0000000..69ae514 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/main.cpp @@ -0,0 +1,10 @@ +#include "classes.hpp" + +int main(){ + A a; + B b; + + b.publicB1(a); + return 0; +} + diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf b/tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf new file mode 100644 index 0000000..3600214 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf @@ -0,0 +1,14 @@ +summary: Tests backtracking in C++ programs +description: '' +contact: Petr Muller +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap + - gcc-c++ + - glibc-debuginfo +duration: 10m +extra-summary: /tools/systemtap/Regression/RHEL6Feature-cpp-backtraces +extra-task: /tools/systemtap/Regression/RHEL6Feature-cpp-backtraces diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/runtest.sh b/tests/Regression/RHEL6Feature-cpp-backtraces/runtest.sh new file mode 100755 index 0000000..eddbc83 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/runtest.sh @@ -0,0 +1,116 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/RHEL6Feature-cpp-backtraces +# Description: Tests backtracking in C++ programs +# Author: Petr Muller +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2010 Red Hat, Inc. All rights reserved. +# +# This copyrighted material is made available to anyone wishing +# to use, modify, copy, or redistribute it subject to the terms +# and conditions of the GNU General Public License version 2. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public +# License along with this program; if not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +# Boston, MA 02110-1301, USA. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include rhts environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +PACKAGE="systemtap" + +inputAs_rlLog(){ + while read line + do + rlLog "$line" + done +} + +compareAndLog(){ + rlAssertNotDiffer "$1" "$2" + if [ "$?" != "0" ] + then + rlLog "Difference:" + diff -u "$1" "$2" | inputAs_rlLog + fi +} + +rlJournalStart + +rlPhaseStartSetup + rlRun "g++ classes.cpp main.cpp -g -o classes" + rlAssertRpm glibc # show NVR + rlAssertRpm glibc-debuginfo + rlRun "stap-prep" 0-255 +rlPhaseEnd + +rlPhaseStartTest + rlRun "stap --ldd backtrackator.stp -c ./classes > output.out" + rlRun "cp output.out unprocessed.out" + rlLog "Processing output" + rlRun "sed -i -r -e 's/0x[0-9a-f]+/ADDRESS/g' output.out" + rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*publicA1[A-Za-z0-9]*/publicA1/g' output.out" + rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*publicA2[A-Za-z0-9]*/publicA2/g' output.out" + rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*privateA1[A-Za-z0-9]*/privateA1/g' output.out" + rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*privateA2[A-Za-z0-9]*/privateA2/g' output.out" + rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*recursiveA1[A-Za-z0-9]*/recursiveA1/g' output.out" + rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*publicB1[A-Za-z0-9]*/publicB1/g' output.out" + rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*privateB1[A-Za-z0-9]*/privateB1/g' output.out" + rlRun "sed -i -r -e 's!\[((.*\/.*)|(classes))\]!\[PATH\]!g' output.out" + # http://stackoverflow.com/questions/13963150/what-does-the-gcc-function-suffix-isra-mean + rlIsRHEL '>=' 7 && arch | grep -q ppc && \ + rlRun "sed -i 's/generic_start_main.isra.0/generic_start_main/' output.out" + + if rlIsRHEL '>=' 9; then + [[ "`uname -m`" =~ "ppc64" ]] && \ + rlRun "cat golden.el9.`arch`.out > golden-ppc64-17.out" || \ + rlRun "cat golden.el9.`arch`.out > golden.out" + fi + + # RHEL-9 s390x runtime/stack-s390.c:63:52: error: ‘ASYNC_SIZE’ undeclared + # (PAGE_SIZE << 1) on stap side seems to work it around + + + if [ "`uname -m`" == "s390x" ] && ( rlIsRHEL 5 || rlIsRHEL 4 ) + then + rlLog "Detected we are running on: s390x && RHEL <= 5" + rlLog "Using special expected output" + compareAndLog golden-s390x.out output.out + elif [ "`uname -m`" == "ppc64" ] && ( rlIsRHEL 5 || rlIsRHEL 4 ) + then + rlLog "Detected we are running on: ppc64 && RHEL <= 5" + rlLog "Using special expected output" + compareAndLog golden-ppc64.out output.out + elif [[ "`uname -m`" =~ "ppc64" ]] + then + rlLog "Detected we are running on: ppc64" + rlLog "Using special expected output" + compareAndLog golden-ppc64-17.out output.out + else + rlLog "Detected we are running on: nothing special" + rlLog "Using generic expected output" + compareAndLog golden.out output.out + fi +rlPhaseEnd + +rlPhaseStartCleanup + rlFileSubmit output.out + rlFileSubmit golden.out + rlFileSubmit unprocessed.out + rlRun "rm -f classes output.out unprocessed.out" +rlPhaseEnd + +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/classes.cpp b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/classes.cpp new file mode 100644 index 0000000..cd488c5 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/classes.cpp @@ -0,0 +1,39 @@ +#include + +class Explicit{ + public: + int data; + Explicit(); + Explicit(int argument); + Explicit(const Explicit &original); + ~Explicit(); +}; + +class Implicit{ + public: + int data; +}; + +Explicit::Explicit() { this->data=0; } +Explicit::Explicit(int a) {this->data=0; } +Explicit::Explicit(const Explicit &orig){this->data = orig.data;} +Explicit::~Explicit(){} + +int main(){ + Explicit e1; //static ctor call + Explicit *e2; + + e2 = new Explicit(); //dynamic ctor call + delete e2; //dynamic dtor call + + e2 = new Explicit(2); //dynamic ctor call + Explicit e3 = *e2; //copy ctor + delete e2; //dtor + + Implicit i1; //ctor + Implicit *i2 = new Implicit(); //ctor + Implicit i3 = *i2; //implicit copy ctor + delete i2; //dtor + + return 0; // dtor e1, e3, i1, i3 +} diff --git a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/golden.out b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/golden.out new file mode 100644 index 0000000..f45ff90 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/golden.out @@ -0,0 +1,16 @@ +Explicit constructor start +Explicit constructor end +Explicit constructor start +Explicit constructor end +Explicit destructor start +Explicit destructor end +Explicit constructor start +Explicit constructor end +Explicit constructor start +Explicit constructor end +Explicit destructor start +Explicit destructor end +Explicit destructor start +Explicit destructor end +Explicit destructor start +Explicit destructor end diff --git a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/main.fmf b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/main.fmf new file mode 100644 index 0000000..ba18df9 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/main.fmf @@ -0,0 +1,13 @@ +summary: Tests probing constructors and destructors +description: '' +contact: Petr Muller +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap + - gcc-c++ +duration: 5m +extra-summary: /tools/systemtap/Regression/RHEL6Feature-cpp-ctors-and-dtors +extra-task: /tools/systemtap/Regression/RHEL6Feature-cpp-ctors-and-dtors diff --git a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/runtest.sh b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/runtest.sh new file mode 100755 index 0000000..fc72f6b --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/runtest.sh @@ -0,0 +1,52 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/RHEL6Feature-cpp-ctors-and-dtors +# Description: Tests probing constructors and destructors +# Author: Petr Muller +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2010 Red Hat, Inc. All rights reserved. +# +# This copyrighted material is made available to anyone wishing +# to use, modify, copy, or redistribute it subject to the terms +# and conditions of the GNU General Public License version 2. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public +# License along with this program; if not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +# Boston, MA 02110-1301, USA. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include rhts environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +PACKAGE="systemtap" + +rlJournalStart + +rlPhaseStartSetup + rlRun "g++ classes.cpp -g -o classes" +rlPhaseEnd + +rlPhaseStartTest + rlRun "stap -c ./classes tracker.stp -o output.out" + rlAssertNotDiffer golden.out output.out +rlPhaseEnd + +rlPhaseStartCleanup + rlFileSubmit "output.out" + rlFileSubmit "golden.out" + rlRun "rm -rf classes output.out" +rlPhaseEnd + +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/tracker.stp b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/tracker.stp new file mode 100644 index 0000000..8ff0bb1 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/tracker.stp @@ -0,0 +1,23 @@ +probe process("classes").function("Explicit::Explicit"){ + printf("Explicit constructor start\n"); +} + +probe process("classes").function("Explicit::~Explicit"){ + printf("Explicit destructor start\n"); +} + +probe process("classes").function("Explicit::Explicit").return{ + printf("Explicit constructor end\n"); +} + +probe process("classes").function("Explicit::~Explicit").return{ + printf("Explicit destructor end\n"); +} + +//probe process("classes").function("Implicit::Implicit"){ +// printf("Implicitconstructor\n"); +//} + +//probe process("classes").function("Implicit::Implicit"){ +// printf("Implicit constructor\n"); +//} diff --git a/tests/Regression/RHEL6Feature-cpp-inheritance/classes.cpp b/tests/Regression/RHEL6Feature-cpp-inheritance/classes.cpp new file mode 100644 index 0000000..2ab3e54 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-inheritance/classes.cpp @@ -0,0 +1,56 @@ +#include + +class A{ + public: + void one(){ std::cout << "A::one" << std::endl; } + void two(){ std::cout << "A::two" << std::endl; } + virtual void three() { std::cout << "A::three" << std::endl; } + virtual void four() { std::cout << "A::four" << std::endl; } +}; + +class B : public A{ + public: + void one() { std::cout << "B::one" << std::endl; } + int one(int a) { std::cout << "B::one" << std::endl; } + + virtual void three() { std::cout << "B::three" << std::endl; } +}; + +int main(){ + A a; + B b; + + A *ap = new A(); + A *apb = new B(); + + B *bp = new B(); + + + a.one(); + a.two(); + a.three(); + a.four(); + + b.one(); + b.two(); + b.three(); + b.four(); + + ap->one(); + ap->two(); + ap->three(); + ap->four(); + + apb->one(); + apb->two(); + apb->three(); + apb->four(); + + bp->one(); + bp->two(); + bp->three(); + bp->four(); + + + return 0; +} diff --git a/tests/Regression/RHEL6Feature-cpp-inheritance/main.fmf b/tests/Regression/RHEL6Feature-cpp-inheritance/main.fmf new file mode 100644 index 0000000..dba249b --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-inheritance/main.fmf @@ -0,0 +1,13 @@ +summary: Tests systemtap handling inheritance +description: '' +contact: Petr Muller +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap + - gcc-c++ +duration: 10m +extra-summary: /tools/systemtap/Regression/RHEL6Feature-cpp-inheritance +extra-task: /tools/systemtap/Regression/RHEL6Feature-cpp-inheritance diff --git a/tests/Regression/RHEL6Feature-cpp-inheritance/runtest.sh b/tests/Regression/RHEL6Feature-cpp-inheritance/runtest.sh new file mode 100755 index 0000000..deec9ce --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-inheritance/runtest.sh @@ -0,0 +1,56 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/RHEL6Feature-cpp-inheritance +# Description: Tests systemtap handling inheritance +# Author: Petr Muller +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2010 Red Hat, Inc. All rights reserved. +# +# This copyrighted material is made available to anyone wishing +# to use, modify, copy, or redistribute it subject to the terms +# and conditions of the GNU General Public License version 2. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public +# License along with this program; if not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +# Boston, MA 02110-1301, USA. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include rhts environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +# if this testcase caused kernel crash and reboot, don't try to rerun it +[[ $REBOOTCOUNT -gt 0 ]] && exit 1 + +PACKAGE="systemtap" + +rlJournalStart + +rlPhaseStartSetup + rlRun "g++ classes.cpp -o classes -g" + rlRun "./classes > program.out" 0 "Preparing the golden output" +rlPhaseEnd + +rlPhaseStartTest + rlRun "stap -c ./classes tracker.stp -o stap.out" + rlAssertNotDiffer program.out stap.out +rlPhaseEnd + +rlPhaseStartCleanup + rlFileSubmit program.out + rlFileSubmit stap.out + rlRun "rm -f classes stap.out program.out" +rlPhaseEnd + +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/RHEL6Feature-cpp-inheritance/tracker.stp b/tests/Regression/RHEL6Feature-cpp-inheritance/tracker.stp new file mode 100644 index 0000000..525ced5 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-inheritance/tracker.stp @@ -0,0 +1,6 @@ +probe process("classes").function("A::one"){printf("A::one\n");} +probe process("classes").function("A::two"){printf("A::two\n");} +probe process("classes").function("A::three"){printf("A::three\n");} +probe process("classes").function("A::four"){printf("A::four\n");} +probe process("classes").function("B::one"){printf("B::one\n");} +probe process("classes").function("B::three"){printf("B::three\n");} diff --git a/tests/Regression/RHEL6Feature-cpp-methods/classes.cpp b/tests/Regression/RHEL6Feature-cpp-methods/classes.cpp new file mode 100644 index 0000000..e947234 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-methods/classes.cpp @@ -0,0 +1,71 @@ +__attribute__((noinline)) void StandaloneFunction(){ + +} + +class CLASS1{ + private: + void prMethod() {}; + public: + void puMethod() {this->prMethod();}; + static void stMethod() {}; +}; + +namespace inner{ + void StandaloneFunction(){ + } + + class CLASS1{ + private: + void prMethod() {}; + public: + void puMethod() {this->prMethod();}; + static void stMethod() {}; + }; +}; + +namespace moreinner{ + void StandaloneFunction(){ + } + + class CLASS1{ + private: + __attribute__((noinline)) void prMethod() {}; + public: + __attribute__((noinline)) void puMethod() {this->prMethod();}; + __attribute__((noinline)) static void stMethod() {}; + }; +}; + +int main(){ + StandaloneFunction(); + inner::StandaloneFunction(); + moreinner::StandaloneFunction(); + + CLASS1 A; + inner::CLASS1 B; + moreinner::CLASS1 C; + + CLASS1* pA = new CLASS1(); + inner::CLASS1 *pB = new inner::CLASS1(); + moreinner::CLASS1 *pC = new moreinner::CLASS1(); + + A.puMethod(); + A.stMethod(); + + B.puMethod(); + B.stMethod(); + + C.puMethod(); + C.stMethod(); + + pA->puMethod(); + pA->stMethod(); + + pB->puMethod(); + pB->stMethod(); + + pC->puMethod(); + pC->stMethod(); + + return 0; +} diff --git a/tests/Regression/RHEL6Feature-cpp-methods/golden.el7.out b/tests/Regression/RHEL6Feature-cpp-methods/golden.el7.out new file mode 100644 index 0000000..d7cff12 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-methods/golden.el7.out @@ -0,0 +1,70 @@ +StandaloneFunction start: _Z18StandaloneFunctionv +StandaloneFunction end: main +StandaloneFunction start: _ZN5inner18StandaloneFunctionEv +inner::StandaloneFunction start: _ZN5inner18StandaloneFunctionEv +StandaloneFunction end: main +inner::StandaloneFunction end: main +StandaloneFunction start: _ZN9moreinner18StandaloneFunctionEv +moreinner::StandaloneFunction start: _ZN9moreinner18StandaloneFunctionEv +StandaloneFunction end: main +moreinner::StandaloneFunction end: main +puMethod start: _ZN6CLASS18puMethodEv +prMethod start: _ZN6CLASS18prMethodEv +prMethod end: _ZN6CLASS18puMethodEv +puMethod end: main +stMethod start: _ZN6CLASS18stMethodEv +stMethod end: main +puMethod start: _ZN5inner6CLASS18puMethodEv +inner::puMethod start: _ZN5inner6CLASS18puMethodEv +prMethod start: _ZN5inner6CLASS18prMethodEv +inner::prMethod start: _ZN5inner6CLASS18prMethodEv +prMethod end: _ZN5inner6CLASS18puMethodEv +inner::prMethod end: _ZN5inner6CLASS18puMethodEv +puMethod end: main +inner::puMethod end: main +stMethod start: _ZN5inner6CLASS18stMethodEv +inner::stMethod start: _ZN5inner6CLASS18stMethodEv +stMethod end: main +inner::stMethod end: main +puMethod start: _ZN9moreinner6CLASS18puMethodEv +moreinner::puMethod start: _ZN9moreinner6CLASS18puMethodEv +prMethod start: _ZN9moreinner6CLASS18prMethodEv +moreinner::prMethod start: _ZN9moreinner6CLASS18prMethodEv +prMethod end: _ZN9moreinner6CLASS18puMethodEv +moreinner::prMethod end: _ZN9moreinner6CLASS18puMethodEv +puMethod end: main +moreinner::puMethod end: main +stMethod start: _ZN9moreinner6CLASS18stMethodEv +moreinner::stMethod start: _ZN9moreinner6CLASS18stMethodEv +stMethod end: main +moreinner::stMethod end: main +puMethod start: _ZN6CLASS18puMethodEv +prMethod start: _ZN6CLASS18prMethodEv +prMethod end: _ZN6CLASS18puMethodEv +puMethod end: main +stMethod start: _ZN6CLASS18stMethodEv +stMethod end: main +puMethod start: _ZN5inner6CLASS18puMethodEv +inner::puMethod start: _ZN5inner6CLASS18puMethodEv +prMethod start: _ZN5inner6CLASS18prMethodEv +inner::prMethod start: _ZN5inner6CLASS18prMethodEv +prMethod end: _ZN5inner6CLASS18puMethodEv +inner::prMethod end: _ZN5inner6CLASS18puMethodEv +puMethod end: main +inner::puMethod end: main +stMethod start: _ZN5inner6CLASS18stMethodEv +inner::stMethod start: _ZN5inner6CLASS18stMethodEv +stMethod end: main +inner::stMethod end: main +puMethod start: _ZN9moreinner6CLASS18puMethodEv +moreinner::puMethod start: _ZN9moreinner6CLASS18puMethodEv +prMethod start: _ZN9moreinner6CLASS18prMethodEv +moreinner::prMethod start: _ZN9moreinner6CLASS18prMethodEv +prMethod end: _ZN9moreinner6CLASS18puMethodEv +moreinner::prMethod end: _ZN9moreinner6CLASS18puMethodEv +puMethod end: main +moreinner::puMethod end: main +stMethod start: _ZN9moreinner6CLASS18stMethodEv +moreinner::stMethod start: _ZN9moreinner6CLASS18stMethodEv +stMethod end: main +moreinner::stMethod end: main diff --git a/tests/Regression/RHEL6Feature-cpp-methods/golden.el8.out b/tests/Regression/RHEL6Feature-cpp-methods/golden.el8.out new file mode 100644 index 0000000..6ba6bc9 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-methods/golden.el8.out @@ -0,0 +1,83 @@ +StandaloneFunction start: _Z18StandaloneFunctionv +StandaloneFunction end: main +StandaloneFunction start: _ZN5inner18StandaloneFunctionEv +inner::StandaloneFunction start: _ZN5inner18StandaloneFunctionEv +StandaloneFunction end: main +inner::StandaloneFunction end: main +StandaloneFunction start: _ZN9moreinner18StandaloneFunctionEv +moreinner::StandaloneFunction start: _ZN9moreinner18StandaloneFunctionEv +StandaloneFunction end: main +moreinner::StandaloneFunction end: main +puMethod start: _ZN6CLASS18puMethodEv +prMethod start: _ZN6CLASS18prMethodEv +prMethod end: _ZN6CLASS18puMethodEv +puMethod end: main +stMethod start: _ZN6CLASS18stMethodEv +stMethod end: main +puMethod start: _ZN5inner6CLASS18puMethodEv +inner::puMethod start: _ZN5inner6CLASS18puMethodEv +prMethod start: _ZN5inner6CLASS18prMethodEv +inner::prMethod start: _ZN5inner6CLASS18prMethodEv +prMethod end: _ZN5inner6CLASS18puMethodEv +inner::prMethod end: _ZN5inner6CLASS18puMethodEv +puMethod end: main +inner::puMethod end: main +stMethod start: _ZN5inner6CLASS18stMethodEv +inner::stMethod start: _ZN5inner6CLASS18stMethodEv +stMethod end: main +inner::stMethod end: main +puMethod start: _ZN9moreinner6CLASS18puMethodEv +moreinner::puMethod start: _ZN9moreinner6CLASS18puMethodEv +prMethod start: _ZN9moreinner6CLASS18prMethodEv +moreinner::prMethod start: _ZN9moreinner6CLASS18prMethodEv +prMethod end: _ZN9moreinner6CLASS18puMethodEv +moreinner::prMethod end: _ZN9moreinner6CLASS18puMethodEv +puMethod end: main +moreinner::puMethod end: main +stMethod start: _ZN9moreinner6CLASS18stMethodEv +moreinner::stMethod start: _ZN9moreinner6CLASS18stMethodEv +stMethod end: main +moreinner::stMethod end: main +puMethod start: _ZN6CLASS18puMethodEv +prMethod start: _ZN6CLASS18prMethodEv +prMethod end: _ZN6CLASS18puMethodEv +puMethod end: main +stMethod start: _ZN6CLASS18stMethodEv +stMethod end: main +puMethod start: _ZN5inner6CLASS18puMethodEv +inner::puMethod start: _ZN5inner6CLASS18puMethodEv +prMethod start: _ZN5inner6CLASS18prMethodEv +inner::prMethod start: _ZN5inner6CLASS18prMethodEv +prMethod end: _ZN5inner6CLASS18puMethodEv +inner::prMethod end: _ZN5inner6CLASS18puMethodEv +puMethod end: main +inner::puMethod end: main +stMethod start: _ZN5inner6CLASS18stMethodEv +inner::stMethod start: _ZN5inner6CLASS18stMethodEv +stMethod end: main +inner::stMethod end: main +puMethod start: _ZN9moreinner6CLASS18puMethodEv +moreinner::puMethod start: _ZN9moreinner6CLASS18puMethodEv +prMethod start: _ZN9moreinner6CLASS18prMethodEv +moreinner::prMethod start: _ZN9moreinner6CLASS18prMethodEv +prMethod end: _ZN9moreinner6CLASS18puMethodEv +moreinner::prMethod end: _ZN9moreinner6CLASS18puMethodEv +puMethod end: main +moreinner::puMethod end: main +stMethod start: _ZN9moreinner6CLASS18stMethodEv +moreinner::stMethod start: _ZN9moreinner6CLASS18stMethodEv +stMethod end: main +moreinner::stMethod end: main +__StandaloneFunction=0 +__hitcount=70 +__inner_StandaloneFunction=0 +__moreinner_StandaloneFunction=0 +__stMethod=0 +__inner_CLASS1_stMethod=0 +__moreinner_star_stMethod=0 +__prMethod=0 +__inner_CLASS1_prMethod=0 +__moreinner_star_prMethod=0 +__puMethod=0 +__inner_CLASS1_puMethod=0 +__moreinner_star_puMethod=0 diff --git a/tests/Regression/RHEL6Feature-cpp-methods/golden.out b/tests/Regression/RHEL6Feature-cpp-methods/golden.out new file mode 100644 index 0000000..fe9c7bb --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-methods/golden.out @@ -0,0 +1,70 @@ +StandaloneFunction start: StandaloneFunction +StandaloneFunction end: StandaloneFunction +StandaloneFunction start: StandaloneFunction +inner::StandaloneFunction start: inner::StandaloneFunction +inner::StandaloneFunction end: inner::StandaloneFunction +StandaloneFunction end: StandaloneFunction +StandaloneFunction start: StandaloneFunction +moreinner::StandaloneFunction start: moreinner::StandaloneFunction +moreinner::StandaloneFunction end: moreinner::StandaloneFunction +StandaloneFunction end: StandaloneFunction +puMethod start: puMethod +prMethod start: prMethod +prMethod end: prMethod +puMethod end: puMethod +stMethod start: stMethod +stMethod end: stMethod +puMethod start: puMethod +inner::puMethod start: inner::CLASS1::puMethod +prMethod start: prMethod +inner::prMethod start: inner::CLASS1::prMethod +inner::prMethod end: inner::CLASS1::prMethod +prMethod end: prMethod +inner::puMethod end: inner::CLASS1::puMethod +puMethod end: puMethod +stMethod start: stMethod +inner::stMethod start: inner::CLASS1::stMethod +inner::stMethod end: inner::CLASS1::stMethod +stMethod end: stMethod +puMethod start: puMethod +moreinner::puMethod start: moreinner::CLASS1::puMethod +prMethod start: prMethod +moreinner::prMethod start: moreinner::CLASS1::prMethod +moreinner::prMethod end: moreinner::CLASS1::prMethod +prMethod end: prMethod +moreinner::puMethod end: moreinner::CLASS1::puMethod +puMethod end: puMethod +stMethod start: stMethod +moreinner::stMethod start: moreinner::CLASS1::stMethod +moreinner::stMethod end: moreinner::CLASS1::stMethod +stMethod end: stMethod +puMethod start: puMethod +prMethod start: prMethod +prMethod end: prMethod +puMethod end: puMethod +stMethod start: stMethod +stMethod end: stMethod +puMethod start: puMethod +inner::puMethod start: inner::CLASS1::puMethod +prMethod start: prMethod +inner::prMethod start: inner::CLASS1::prMethod +inner::prMethod end: inner::CLASS1::prMethod +prMethod end: prMethod +inner::puMethod end: inner::CLASS1::puMethod +puMethod end: puMethod +stMethod start: stMethod +inner::stMethod start: inner::CLASS1::stMethod +inner::stMethod end: inner::CLASS1::stMethod +stMethod end: stMethod +puMethod start: puMethod +moreinner::puMethod start: moreinner::CLASS1::puMethod +prMethod start: prMethod +moreinner::prMethod start: moreinner::CLASS1::prMethod +moreinner::prMethod end: moreinner::CLASS1::prMethod +prMethod end: prMethod +moreinner::puMethod end: moreinner::CLASS1::puMethod +puMethod end: puMethod +stMethod start: stMethod +moreinner::stMethod start: moreinner::CLASS1::stMethod +moreinner::stMethod end: moreinner::CLASS1::stMethod +stMethod end: stMethod diff --git a/tests/Regression/RHEL6Feature-cpp-methods/golden_summary.out b/tests/Regression/RHEL6Feature-cpp-methods/golden_summary.out new file mode 100644 index 0000000..4072ed7 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-methods/golden_summary.out @@ -0,0 +1,13 @@ +__hitcount=70 +__inner_CLASS1_prMethod=0 +__inner_CLASS1_puMethod=0 +__inner_CLASS1_stMethod=0 +__inner_StandaloneFunction=0 +__moreinner_StandaloneFunction=0 +__moreinner_star_prMethod=0 +__moreinner_star_puMethod=0 +__moreinner_star_stMethod=0 +__prMethod=0 +__puMethod=0 +__StandaloneFunction=0 +__stMethod=0 diff --git a/tests/Regression/RHEL6Feature-cpp-methods/main.fmf b/tests/Regression/RHEL6Feature-cpp-methods/main.fmf new file mode 100644 index 0000000..56ac081 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-methods/main.fmf @@ -0,0 +1,13 @@ +summary: Tests C++ methods +description: '' +contact: Petr Muller +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap + - gcc-c++ +duration: 120m +extra-summary: /tools/systemtap/Regression/RHEL6Feature-cpp-methods +extra-task: /tools/systemtap/Regression/RHEL6Feature-cpp-methods diff --git a/tests/Regression/RHEL6Feature-cpp-methods/runtest.sh b/tests/Regression/RHEL6Feature-cpp-methods/runtest.sh new file mode 100755 index 0000000..443ff56 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-methods/runtest.sh @@ -0,0 +1,72 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/RHEL6Feature-cpp-methods +# Description: Tests C++ methods +# Author: Petr Muller +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2010 Red Hat, Inc. All rights reserved. +# +# This copyrighted material is made available to anyone wishing +# to use, modify, copy, or redistribute it subject to the terms +# and conditions of the GNU General Public License version 2. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public +# License along with this program; if not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +# Boston, MA 02110-1301, USA. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include rhts environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +PACKAGE="systemtap" + +rlJournalStart + +rlPhaseStartSetup + rlRun "stap-prep" 0-255 + rlRun "g++ -O0 classes.cpp -o classes -g" + + rlIsRHEL 6 && COMPAT='--compatible=1.8' + # rlIsRHEL 7 && cp -f golden.el7.out golden.out + # rlIsRHEL 8 && cp -f golden.el8.out golden.out +rlPhaseEnd + +rlPhaseStartTest + rlRun "stap $COMPAT -c ./classes tracker.stp -o output.out" + # Stop comparing literally against a golden file, + # do a sanity check instead. The literal golden file check + # sort of regressed between rhel-8.2 and rhel-8.3 + # rlRun "diff golden.out output.out" + rlRun "grep ^__ output.out | sort > summary.out" + + # RHEL6: covert hex to dec: + rlRun "sed -i 's/0x0/0/' summary.out" + rlRun "sed -i 's/0x46/70/' summary.out" + + # Sanity check + rlRun "diff golden_summary.out summary.out" || ( + rlRun "cat golden_summary.out" + rlRun "cat summary.out" + ) +rlPhaseEnd + +rlPhaseStartCleanup + rlFileSubmit golden.out + rlFileSubmit output.out + + rlRun "rm -f output.out classes" +rlPhaseEnd + +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/RHEL6Feature-cpp-methods/tracker.stp b/tests/Regression/RHEL6Feature-cpp-methods/tracker.stp new file mode 100644 index 0000000..54e15b3 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-methods/tracker.stp @@ -0,0 +1,162 @@ +global __hitcount = 0 +global __StandaloneFunction = 0 +global __inner_StandaloneFunction = 0 +global __moreinner_StandaloneFunction = 0 +global __stMethod = 0 +global __inner_CLASS1_stMethod = 0 +global __moreinner_star_stMethod = 0 +global __prMethod = 0 +global __inner_CLASS1_prMethod = 0 +global __moreinner_star_prMethod = 0 +global __puMethod = 0 +global __inner_CLASS1_puMethod = 0 +global __moreinner_star_puMethod = 0 + +probe process("classes").function("StandaloneFunction").call{ + __StandaloneFunction++ + __hitcount++ + printf("StandaloneFunction start: %s\n", probefunc()); +} + +probe process("classes").function("StandaloneFunction").return{ + __StandaloneFunction-- + __hitcount++ + printf("StandaloneFunction end: %s\n", probefunc()); +} + +probe process("classes").function("inner::StandaloneFunction").call{ + __inner_StandaloneFunction++ + __hitcount++ + printf("inner::StandaloneFunction start: %s\n", probefunc()); +} + +probe process("classes").function("inner::StandaloneFunction").return{ + __inner_StandaloneFunction-- + __hitcount++ + printf("inner::StandaloneFunction end: %s\n", probefunc()); +} + +probe process("classes").function("moreinner::StandaloneFunction").call{ + __moreinner_StandaloneFunction++ + __hitcount++ + printf("moreinner::StandaloneFunction start: %s\n", probefunc()); +} + +probe process("classes").function("moreinner::StandaloneFunction").return{ + __moreinner_StandaloneFunction-- + __hitcount++ + printf("moreinner::StandaloneFunction end: %s\n", probefunc()); +} +// ============================================================================ +probe process("classes").function("stMethod").call{ + __stMethod++ + __hitcount++ + printf("stMethod start: %s\n", probefunc()); +} + +probe process("classes").function("stMethod").return{ + __stMethod-- + __hitcount++ + printf("stMethod end: %s\n", probefunc()); +} + +probe process("classes").function("inner::CLASS1::stMethod").call{ + __inner_CLASS1_stMethod++ + __hitcount++ + printf("inner::stMethod start: %s\n", probefunc()); +} + +probe process("classes").function("inner::CLASS1::stMethod").return{ + __inner_CLASS1_stMethod-- + __hitcount++ + printf("inner::stMethod end: %s\n", probefunc()); +} + +probe process("classes").function("moreinner::*::stMethod").call{ + __moreinner_star_stMethod++ + __hitcount++ + printf("moreinner::stMethod start: %s\n", probefunc()); +} + +probe process("classes").function("moreinner::*::stMethod").return{ + __moreinner_star_stMethod-- + __hitcount++ + printf("moreinner::stMethod end: %s\n", probefunc()); +} +//============================================================================= + +probe process("classes").function("prMethod").call{ + __prMethod++ + __hitcount++ + printf("prMethod start: %s\n", probefunc()); +} + +probe process("classes").function("prMethod").return{ + __prMethod-- + __hitcount++ + printf("prMethod end: %s\n", probefunc()); +} + +probe process("classes").function("inner::CLASS1::prMethod").call{ + __inner_CLASS1_prMethod++ + __hitcount++ + printf("inner::prMethod start: %s\n", probefunc()); +} + +probe process("classes").function("inner::CLASS1::prMethod").return{ + __inner_CLASS1_prMethod-- + __hitcount++ + printf("inner::prMethod end: %s\n", probefunc()); +} + +probe process("classes").function("moreinner::*::prMethod").call{ + __moreinner_star_prMethod++ + __hitcount++ + printf("moreinner::prMethod start: %s\n", probefunc()); +} + +probe process("classes").function("moreinner::*::prMethod").return{ + __moreinner_star_prMethod-- + __hitcount++ + printf("moreinner::prMethod end: %s\n", probefunc()); +} + +//============================================================================= + +probe process("classes").function("puMethod").call{ + __puMethod++ + __hitcount++ + printf("puMethod start: %s\n", probefunc()); +} + +probe process("classes").function("puMethod").return{ + __puMethod-- + __hitcount++ + printf("puMethod end: %s\n", probefunc()); +} + +probe process("classes").function("inner::CLASS1::puMethod").call{ + __inner_CLASS1_puMethod++ + __hitcount++ + printf("inner::puMethod start: %s\n", probefunc()); +} + +probe process("classes").function("inner::CLASS1::puMethod").return{ + __inner_CLASS1_puMethod-- + __hitcount++ + printf("inner::puMethod end: %s\n", probefunc()); +} + +probe process("classes").function("moreinner::*::puMethod").call{ + __moreinner_star_puMethod++ + __hitcount++ + printf("moreinner::puMethod start: %s\n", probefunc()); +} + +probe process("classes").function("moreinner::*::puMethod").return{ + __moreinner_star_puMethod-- + __hitcount++ + printf("moreinner::puMethod end: %s\n", probefunc()); +} + + diff --git a/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/main.fmf b/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/main.fmf new file mode 100644 index 0000000..33847c6 --- /dev/null +++ b/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/main.fmf @@ -0,0 +1,14 @@ +summary: Test for BZ#1572501 (RHEL7.5 - backtraces no longer work with systemtap) +description: Test for BZ#1572501 +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap +duration: 48h +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1572501 +extra-summary: /tools/systemtap/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap +extra-task: /tools/systemtap/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap diff --git a/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/runtest.sh b/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/runtest.sh new file mode 100755 index 0000000..a4b1a26 --- /dev/null +++ b/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/runtest.sh @@ -0,0 +1,49 @@ +#!/bin/bash +# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap +# Description: Test for BZ#1572501 (RHEL7.5 - backtraces no longer work with systemtap) +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2018 Red Hat, Inc. +# +# This program is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation, either version 2 of +# the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see http://www.gnu.org/licenses/. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +PACKAGE="systemtap" + +rlJournalStart + rlPhaseStartTest + if arch | grep -q s390x; then + rlLogWarning "Test not relevant" + else + TEMPFILE=$(mktemp) + rlRun "stap --all-modules -vwe 'probe kernel.function(\"kmem_cache_alloc\") { print_backtrace(); exit() }' >& $TEMPFILE" + # since it's hard to find some reasonable pattern to grep for across arches in the backrtrace + # we'll simply count the lines. We'll want at least 9 lines of output (6 as the results of -v, + # and another at least three coming from the backtrace itself. + rlRun "cat $TEMPFILE" + rlRun "test 9 -le $(wc -l $TEMPFILE | awk '{print $1}')" + rm $TEMPFILE + fi + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/bz544960-no-cfa_ops-supplied/README b/tests/Regression/bz544960-no-cfa_ops-supplied/README new file mode 100644 index 0000000..f1152ea --- /dev/null +++ b/tests/Regression/bz544960-no-cfa_ops-supplied/README @@ -0,0 +1,63 @@ +Kernel porting needed. + +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:: Test +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: + +:: [ 09:22:47 ] :: [ INFO ] :: Checking whether we might want to try prologue search. +:: [ 09:23:10 ] :: [ BEGIN ] :: Running 'stap -P -vp4 readpages.stp' +Pass 1: parsed user script and 484 library scripts using 122428virt/95036res/15532shr/79120data kb, in 200usr/110sys/315real ms. +WARNING: never-assigned local variable 'nr_pages' (similar: rpages, __page, dev, name, file): identifier 'nr_pages' at readpages.stp:5:26 + source: printf("nr_pages=%d\n", nr_pages); + ^ +WARNING: never-assigned local variable 'rpages' (similar: nr_pages, __page, dev, name, rsize): identifier 'rpages' at :7:24 + source: printf("rpages=%d\n", rpages); + ^ +Pass 2: analyzed script: 2 probes, 17 functions, 3 embeds, 0 globals using 351676virt/327836res/19060shr/308368data kb, in 2880usr/1970sys/4927real ms. +Pass 3: translated to C into "/tmp/stapWU958g/stap_f189533513b6d61221ada924fedfc9c4_6369_src.c" using 351692virt/327964res/19188shr/308384data kb, in 490usr/800sys/1301real ms. +In file included from /usr/share/systemtap/runtime/linux/../regs.c:16, + from /usr/share/systemtap/runtime/linux/runtime.h:270, + from /usr/share/systemtap/runtime/runtime.h:26, + from /tmp/stapWU958g/stap_f189533513b6d61221ada924fedfc9c4_6369_src.c:21: +/tmp/stapWU958g/stap_f189533513b6d61221ada924fedfc9c4_6369_src.c: In function ‘enter_kretprobe_common’: +/tmp/stapWU958g/stap_f189533513b6d61221ada924fedfc9c4_6369_src.c:2499:45: error: ‘struct kretprobe_instance’ has no member named ‘ret_addr’ + 2499 | SET_REG_IP(regs, (unsigned long)inst->ret_addr); + | ^~ +/usr/share/systemtap/runtime/linux/../regs.h:85:44: note: in definition of macro ‘SET_REG_IP’ + 85 | #define SET_REG_IP(regs, x) REG_IP(regs) = x + | ^ +make[1]: *** [scripts/Makefile.build:288: /tmp/stapWU958g/stap_f189533513b6d61221ada924fedfc9c4_6369_src.o] Error 1 +make: *** [Makefile:1844: /tmp/stapWU958g] Error 2 +WARNING: kbuild exited with status: 2 +Pass 4: compiled C into "stap_f189533513b6d61221ada924fedfc9c4_6369.ko" in 1150usr/1910sys/2659real ms. +Pass 4: compilation failed. [man error::pass4] +:: [ 09:23:20 ] :: [ FAIL ] :: Command 'stap -P -vp4 readpages.stp' (Expected 0, got 1) +:: [ 09:23:20 ] :: [ BEGIN ] :: Running 'stap -P -vp4 tcp.sendmsg.stp' +Pass 1: parsed user script and 484 library scripts using 122428virt/95044res/15536shr/79120data kb, in 180usr/130sys/316real ms. +Pass 2: analyzed script: 5 probes, 2 functions, 4 embeds, 3 globals using 202292virt/178300res/19224shr/158984data kb, in 1720usr/1750sys/3531real ms. +Pass 3: translated to C into "/tmp/stapzXlpka/stap_c98d0598383a49c9b0a715336e876a54_18911_src.c" using 202308virt/178492res/19416shr/159000data kb, in 160usr/720sys/899real ms. +In file included from /usr/share/systemtap/runtime/linux/../regs.c:16, + from /usr/share/systemtap/runtime/linux/runtime.h:270, + from /usr/share/systemtap/runtime/runtime.h:26, + from /tmp/stapzXlpka/stap_c98d0598383a49c9b0a715336e876a54_18911_src.c:21: +/tmp/stapzXlpka/stap_c98d0598383a49c9b0a715336e876a54_18911_src.c: In function ‘enter_kretprobe_common’: +/tmp/stapzXlpka/stap_c98d0598383a49c9b0a715336e876a54_18911_src.c:2190:45: error: ‘struct kretprobe_instance’ has no member named ‘ret_addr’ + 2190 | SET_REG_IP(regs, (unsigned long)inst->ret_addr); + | ^~ +/usr/share/systemtap/runtime/linux/../regs.h:85:44: note: in definition of macro ‘SET_REG_IP’ + 85 | #define SET_REG_IP(regs, x) REG_IP(regs) = x + | ^ +make[1]: *** [scripts/Makefile.build:288: /tmp/stapzXlpka/stap_c98d0598383a49c9b0a715336e876a54_18911_src.o] Error 1 +make: *** [Makefile:1844: /tmp/stapzXlpka] Error 2 +WARNING: kbuild exited with status: 2 +Pass 4: compiled C into "stap_c98d0598383a49c9b0a715336e876a54_18911.ko" in 1250usr/1900sys/2762real ms. +Pass 4: compilation failed. [man error::pass4] +:: [ 09:23:28 ] :: [ FAIL ] :: Command 'stap -P -vp4 tcp.sendmsg.stp' (Expected 0, got 1) +:: [ 09:23:28 ] :: [ BEGIN ] :: Running 'stap -P -vp4 bdflush.stp' +Pass 1: parsed user script and 484 library scripts using 122428virt/94968res/15468shr/79120data kb, in 180usr/130sys/317real ms. +Pass 2: analyzed script: 3 probes, 5 functions, 98 embeds, 4 globals using 198116virt/174376res/18956shr/154808data kb, in 1930usr/2660sys/4689real ms. +/root/.systemtap/cache/87/stap_8728db2fdfe761c96d8963fd0c4fffd2_71969.ko +Pass 3: using cached /root/.systemtap/cache/87/stap_8728db2fdfe761c96d8963fd0c4fffd2_71969.c +Pass 4: using cached /root/.systemtap/cache/87/stap_8728db2fdfe761c96d8963fd0c4fffd2_71969.ko +:: [ 09:23:33 ] :: [ PASS ] :: Command 'stap -P -vp4 bdflush.stp' (Expected 0, got 0) + diff --git a/tests/Regression/bz544960-no-cfa_ops-supplied/bdflush.stp b/tests/Regression/bz544960-no-cfa_ops-supplied/bdflush.stp new file mode 100644 index 0000000..e38c685 --- /dev/null +++ b/tests/Regression/bz544960-no-cfa_ops-supplied/bdflush.stp @@ -0,0 +1,8 @@ +probe syscall.bdflush { + printf("%s\n", name) + printf("%s\n", argstr) +} + +probe syscall.bdflush.return { + printf("%s\n", name) +} diff --git a/tests/Regression/bz544960-no-cfa_ops-supplied/main.fmf b/tests/Regression/bz544960-no-cfa_ops-supplied/main.fmf new file mode 100644 index 0000000..bab475f --- /dev/null +++ b/tests/Regression/bz544960-no-cfa_ops-supplied/main.fmf @@ -0,0 +1,14 @@ +summary: bz544960-no-cfa_ops-supplied +description: '' +contact: Martin Hatina +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap +duration: 30m +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=544960 +extra-summary: /tools/systemtap/Regression/bz544960-no-cfa_ops-supplied +extra-task: /tools/systemtap/Regression/bz544960-no-cfa_ops-supplied diff --git a/tests/Regression/bz544960-no-cfa_ops-supplied/readpages.stp b/tests/Regression/bz544960-no-cfa_ops-supplied/readpages.stp new file mode 100644 index 0000000..7ff57b4 --- /dev/null +++ b/tests/Regression/bz544960-no-cfa_ops-supplied/readpages.stp @@ -0,0 +1,19 @@ +probe nfs.aop.readpages !, nfs.aop.readpage { + log(name); + printf("dev=%d\n", dev); + printf("ino=%d\n", ino); + printf("nr_pages=%d\n", nr_pages); + printf("file=%d\n", file); + printf("rpages=%d\n", rpages); + printf("rsize=%d\n", rsize); + printf("argstr=%s\n", argstr); + printf("size=%d\n", size); + printf("units=%s\n", units); +} + +probe nfs.aop.readpages.return !, nfs.aop.readpage.return { + log(name); + printf("retstr=%s\n", retstr); + printf("size=%d\n", size); + printf("units=%s\n", units); +} diff --git a/tests/Regression/bz544960-no-cfa_ops-supplied/runtest.sh b/tests/Regression/bz544960-no-cfa_ops-supplied/runtest.sh new file mode 100755 index 0000000..4be6581 --- /dev/null +++ b/tests/Regression/bz544960-no-cfa_ops-supplied/runtest.sh @@ -0,0 +1,48 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/bz544960-no-cfa_ops-supplied +# Description: What the test does +# Author: Martin Hatina +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2013 Red Hat, Inc. All rights reserved. +# +# This copyrighted material is made available to anyone wishing +# to use, modify, copy, or redistribute it subject to the terms +# and conditions of the GNU General Public License version 2. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public +# License along with this program; if not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +# Boston, MA 02110-1301, USA. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +PACKAGE="systemtap" +_SCRIPTS="readpages.stp tcp.sendmsg.stp bdflush.stp" + +rlJournalStart + rlPhaseStartTest + rlLogInfo "Checking whether we might want to try prologue search." + p="" + for s in $_SCRIPTS; do + stap -vp4 $s >& /dev/null || p="-P" + done + + for s in $_SCRIPTS; do + rlRun "stap $p -vp4 $s" + done + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/bz544960-no-cfa_ops-supplied/tcp.sendmsg.stp b/tests/Regression/bz544960-no-cfa_ops-supplied/tcp.sendmsg.stp new file mode 100644 index 0000000..1cb95b3 --- /dev/null +++ b/tests/Regression/bz544960-no-cfa_ops-supplied/tcp.sendmsg.stp @@ -0,0 +1,7 @@ +probe tcp.sendmsg { + printf("%d\n", size) +} + +probe tcp.sendmsg.return { + printf("%d\n", size) +} diff --git a/tests/Regression/bz706185-various-build-and-run/main.fmf b/tests/Regression/bz706185-various-build-and-run/main.fmf new file mode 100644 index 0000000..3d6770a --- /dev/null +++ b/tests/Regression/bz706185-various-build-and-run/main.fmf @@ -0,0 +1,15 @@ +summary: bz706185-various-build-and-run +description: bz706185-various-build-and-run +contact: Petr Muller +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +require: +recommend: + - systemtap +duration: 20m +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=706185 +extra-summary: /tools/systemtap/Regression/bz706185-various-build-and-run +extra-task: /tools/systemtap/Regression/bz706185-various-build-and-run diff --git a/tests/Regression/bz706185-various-build-and-run/runtest.sh b/tests/Regression/bz706185-various-build-and-run/runtest.sh new file mode 100755 index 0000000..447c049 --- /dev/null +++ b/tests/Regression/bz706185-various-build-and-run/runtest.sh @@ -0,0 +1,87 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/bz706185-various-build-and-run +# Description: Test containing several build and run testcases. +# Author: Petr Muller +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2011 Red Hat, Inc. All rights reserved. +# +# This copyrighted material is made available to anyone wishing +# to use, modify, copy, or redistribute it subject to the terms +# and conditions of the GNU General Public License version 2. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public +# License along with this program; if not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +# Boston, MA 02110-1301, USA. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh + +PACKAGE="systemtap" + +rlJournalStart +rlPhaseStartSetup + rlRun "rpm -qf $(which stap)" + rlRun "uname -r" +rlPhaseEnd + +rlPhaseStartTest "Build testcases" + export STAPOUT=`mktemp` + export TRACOUT=`mktemp` + for testcase in *.stp + do + rlLog "Testcase: $testcase" + rlRun "stap -v -p4 $testcase -m testcase --poison-cache &>$STAPOUT" 0 "Building testcase: $testcase" + if [ $? -ne 0 ] + then + rlLog "=== systemtap output start" + while read line + do + rlLog "$line" + done < $STAPOUT + rlLog "=== systemtap output end" + fi + rm -f testcase.ko + rm -f $STAPOUT + done +rlPhaseEnd + +rlPhaseStartTest "Run testcases" + for testcase in *.run + do + rlLog "Testcase: $testcase" + COMMAND="`cat $testcase`" + COMMAND="$COMMAND -o $TRACOUT $testcase --poison-cache &>$STAPOUT" + rlLog "Assembled command: [$COMMAND]" + rlRun "$COMMAND" 0 "Running testcase: $testcase" + if [ $? -ne 0 ] + then + rlLog "=== systemtap output start" + while read line; do rlLog "$line"; done < $STAPOUT + rlLog "=== systemtap output end" + rlLog "" + rlLog "=== tracing output start" + while read line; do rlLog "$line"; done < $TRACOUT + rlLog "=== tracing output end" + fi + rm -f $STAPOUT $TRACOUT + done +rlPhaseEnd + +rlPhaseStartCleanup + rlRun "rm -f $STAPOUT $TRACOUT" +rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/bz706185-various-build-and-run/softirq.run b/tests/Regression/bz706185-various-build-and-run/softirq.run new file mode 100644 index 0000000..e609cd5 --- /dev/null +++ b/tests/Regression/bz706185-various-build-and-run/softirq.run @@ -0,0 +1 @@ +stap -v softirq.stp diff --git a/tests/Regression/bz706185-various-build-and-run/softirq.stp b/tests/Regression/bz706185-various-build-and-run/softirq.stp new file mode 100644 index 0000000..347b840 --- /dev/null +++ b/tests/Regression/bz706185-various-build-and-run/softirq.stp @@ -0,0 +1,3 @@ +probe softirq.entry { println(">>> softirq") } +probe softirq.exit { println("<<< softirq")} +probe timer.ms(5000) { exit() } diff --git a/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/main.fmf b/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/main.fmf new file mode 100644 index 0000000..05c4212 --- /dev/null +++ b/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/main.fmf @@ -0,0 +1,15 @@ +summary: dtrace-create-Wall-Wextra-pedantic-clean-code +description: dtrace-create-Wall-Wextra-pedantic-clean-code +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap + - systemtap-sdt-devel +duration: 5m +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=902739 +extra-summary: /tools/systemtap/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code +extra-task: /tools/systemtap/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code diff --git a/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/runtest.sh b/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/runtest.sh new file mode 100755 index 0000000..d76f4c5 --- /dev/null +++ b/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/runtest.sh @@ -0,0 +1,57 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code +# Description: dtrace-create-Wall-Wextra-pedantic-clean-code +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2013 Red Hat, Inc. All rights reserved. +# +# This copyrighted material is made available to anyone wishing +# to use, modify, copy, or redistribute it subject to the terms +# and conditions of the GNU General Public License version 2. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public +# License along with this program; if not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +# Boston, MA 02110-1301, USA. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +rlJournalStart + rlPhaseStartSetup + rlRun "TMPDIR=$(mktemp -d)" + rlRun "pushd $TMPDIR" + rlPhaseEnd + + rlPhaseStart WARN "Info" + rlRun "which dtrace" + rlPhaseEnd + + rlPhaseStartTest + rlRun "printf \"provider xxx { probe xxx(); };\n\" > xxx" + rlRun "dtrace -G -k -s xxx &> dtrace.out" + rlRun "cat dtrace.out" + rlRun "CF=$( awk '/^source:/ {print $2}' dtrace.out )" + rlRun "gcc -c -Wall -Wextra -pedantic $CF 2>&1 | tee gcc.out" + rlRun "grep -i warning gcc.out" 1 + rlRun "grep -i error gcc.out" 1 + rlPhaseEnd + + rlPhaseStartCleanup + rlRun "popd" + rlRun "rm -r $TMPDIR" + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/elfutils-debuginfod-client-not-being-called/dotest.sh b/tests/Regression/elfutils-debuginfod-client-not-being-called/dotest.sh new file mode 100644 index 0000000..02970b4 --- /dev/null +++ b/tests/Regression/elfutils-debuginfod-client-not-being-called/dotest.sh @@ -0,0 +1,28 @@ +#!/bin/bash + +set -xe + +rm -rf ~/.debuginfod_client_cache ~/.systemtap ||: + +debuginfod -p 8008 -d $(mktemp) -vvvvv >& debuginfod.log & +PID=$! + +sleep 5 + +export SYSTEMTAP_DEBUGINFO_PATH=/tmp +export DEBUGINFOD_URLS="http://127.0.0.1:8008" + +# The following doesn't work on aarch64 and s390x because of: +# https://sourceware.org/bugzilla/show_bug.cgi?id=25498 +# stap -p2 -e 'probe kernel.function("vfs_read") {println(pp())}' ||: + +stap -p2 -e 'probe process("/bin/true").function("main") {println(pp())}' -c /bin/true ||: + +sleep 5 + +kill -9 $PID + +grep 'started http server on' debuginfod.log +grep 'searching for buildid=[a-z0-9]* artifacttype=debuginfo' debuginfod.log + + diff --git a/tests/Regression/elfutils-debuginfod-client-not-being-called/main.fmf b/tests/Regression/elfutils-debuginfod-client-not-being-called/main.fmf new file mode 100644 index 0000000..2ae6333 --- /dev/null +++ b/tests/Regression/elfutils-debuginfod-client-not-being-called/main.fmf @@ -0,0 +1,14 @@ +summary: elfutils-debuginfod-client-not-being-called +description: '' +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - elfutils-debuginfod +duration: 48h +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1778921 +extra-summary: /tools/systemtap/Regression/elfutils-debuginfod-client-not-being-called +extra-task: /tools/systemtap/Regression/elfutils-debuginfod-client-not-being-called diff --git a/tests/Regression/elfutils-debuginfod-client-not-being-called/runtest.sh b/tests/Regression/elfutils-debuginfod-client-not-being-called/runtest.sh new file mode 100755 index 0000000..79d9197 --- /dev/null +++ b/tests/Regression/elfutils-debuginfod-client-not-being-called/runtest.sh @@ -0,0 +1,52 @@ +#!/bin/bash +# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/elfutils-debuginfod-client-not-being-called +# Description: elfutils-debuginfod-client-not-being-called +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2020 Red Hat, Inc. +# +# This program is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation, either version 2 of +# the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see http://www.gnu.org/licenses/. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +PACKAGE="systemtap" + +rlJournalStart + rlPhaseStartSetup + rlAssertRpm $PACKAGE + rlRun "TMP=$(mktemp -d)" + rlRun "cp dotest.sh $TMP/" + rlRun "pushd $TMP" + rlPhaseEnd + + rlPhaseStartTest + rlRun "bash dotest.sh" || + rlRun "cat debuginfod.log" + rlFileSubmit debuginfod.log + rlPhaseEnd + + rlPhaseStartCleanup + rlRun "popd" + rlRun "rm -r $TMP" + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/hellotrace.stp b/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/hellotrace.stp new file mode 100644 index 0000000..e390200 --- /dev/null +++ b/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/hellotrace.stp @@ -0,0 +1,8 @@ +probe begin +{ + printf ( "hello trace : printf\n") + printk (20,"hello trace : printk") + ftrace ( "hello trace : ftrace\n") + exit () +} + diff --git a/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/main.fmf b/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/main.fmf new file mode 100644 index 0000000..96bcab2 --- /dev/null +++ b/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/main.fmf @@ -0,0 +1,14 @@ +summary: ftrace-logging-tapset-not-working-as-expected-in +description: ftrace-logging-tapset-not-working-as-expected-in +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap +duration: 48h +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1810216 +extra-summary: /tools/systemtap/Regression/ftrace-logging-tapset-not-working-as-expected-in +extra-task: /tools/systemtap/Regression/ftrace-logging-tapset-not-working-as-expected-in diff --git a/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/runtest.sh b/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/runtest.sh new file mode 100755 index 0000000..4d3a759 --- /dev/null +++ b/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/runtest.sh @@ -0,0 +1,47 @@ +#!/bin/bash +# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/ftrace-logging-tapset-not-working-as-expected-in +# Description: ftrace-logging-tapset-not-working-as-expected-in +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2020 Red Hat, Inc. +# +# This program is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation, either version 2 of +# the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see http://www.gnu.org/licenses/. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +PACKAGE="systemtap" + +LOG1=$(mktemp) +LOG2=$(mktemp) + +rlJournalStart + rlPhaseStartTest + rlRun "mount | fgrep -i 'debugfs on'" + rlRun "cat /sys/kernel/debug/tracing/tracing_on | grep '^1$'" + rlRun "journalctl > $LOG1" + rlRun "stap -g -k -v hellotrace.stp" + rlRun "journalctl > $LOG2" + rlRun "diff $LOG1 $LOG2 | grep '^>.*hello trace : printk'" + rlRun "rm $LOG1 $LOG2" + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/ipv6-tapset-support/main.fmf b/tests/Regression/ipv6-tapset-support/main.fmf new file mode 100644 index 0000000..9d08d89 --- /dev/null +++ b/tests/Regression/ipv6-tapset-support/main.fmf @@ -0,0 +1,16 @@ +summary: Test for BZ#822503 (ipv6 tapset support) +description: ipv6 tapset support +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap + - nfs-utils + - setup +duration: 50m +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=822503 +extra-summary: /tools/systemtap/Regression/ipv6-tapset-support +extra-task: /tools/systemtap/Regression/ipv6-tapset-support diff --git a/tests/Regression/ipv6-tapset-support/nfsd.proc.lookup.stp b/tests/Regression/ipv6-tapset-support/nfsd.proc.lookup.stp new file mode 100755 index 0000000..86db264 --- /dev/null +++ b/tests/Regression/ipv6-tapset-support/nfsd.proc.lookup.stp @@ -0,0 +1,12 @@ +#!/usr/bin/stap + +# http://sourceware.org/systemtap/examples/network/nfsdtop.stp + +probe nfsd.proc.lookup { + printf("%s %s\n", client_ip, filename); +} + +probe timer.ms(100000) { + exit (); +} + diff --git a/tests/Regression/ipv6-tapset-support/runtest.sh b/tests/Regression/ipv6-tapset-support/runtest.sh new file mode 100755 index 0000000..62fa775 --- /dev/null +++ b/tests/Regression/ipv6-tapset-support/runtest.sh @@ -0,0 +1,76 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/ipv6-tapset-support +# Description: Test for BZ#822503 (ipv6 tapset support) +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2013 Red Hat, Inc. All rights reserved. +# +# This copyrighted material is made available to anyone wishing +# to use, modify, copy, or redistribute it subject to the terms +# and conditions of the GNU General Public License version 2. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public +# License along with this program; if not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +# Boston, MA 02110-1301, USA. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +rlJournalStart + rlPhaseStartSetup + rlAssertRpm nfs-utils + rlRun "uname -r" + rlRun "which stap" + + rlRun "TMPD=$(mktemp -d --tmpdir=$HOME tmp.XXXXXXX)" + rlRun "mkdir $TMPD/{A,B}" + rlRun "chmod --recursive 0777 $TMPD" + rlRun "STAPLOG=$(mktemp)" + + rlServiceStart rpcbind + sleep 5 + NFS_SERVICE=nfs + rlIsRHEL '>=8' && NFS_SERVICE=nfs-server + rlServiceStart $NFS_SERVICE + sleep 10 + rlRun "exportfs -ua" + rlRun "exportfs -i -o 'rw,no_root_squash' *:$TMPD/A" + rlPhaseEnd + + rlPhaseStartTest + # ======= work around bz1605574 + rlLogInfo "Let's check if we can compile the module." + rlLogInfo "In case we can't, we'll go ahead with prologue searching." + set -x + EXTRA_SWITCHES='' + stap -p4 nfsd.proc.lookup.stp || EXTRA_SWITCHES="-P" + set +x + # ============================= + + # mount is sufficient to invoke nfsd.proc.lookup + rlRun "stap $EXTRA_SWITCHES -v -c 'mount -t nfs -v [::1]:$TMPD/A $TMPD/B' nfsd.proc.lookup.stp |& tee $STAPLOG" + rlRun "umount $TMPD/B" + rlRun "grep 'Unsupported Address Family' $STAPLOG" 1 + rlRun "egrep '^\[0000:0000:0000:0000:0000:0000:0000:0001\]:[0-9]+.*$(basename $TMPD)' $STAPLOG" + rlPhaseEnd + + rlPhaseStartCleanup + rlServiceRestore $NFS_SERVICE + rlServiceRestore rpcbind + rlRun "rm -rf $TMPD $STAPLOG" + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/irq-vector-tracepoints/main.fmf b/tests/Regression/irq-vector-tracepoints/main.fmf new file mode 100644 index 0000000..c9ec663 --- /dev/null +++ b/tests/Regression/irq-vector-tracepoints/main.fmf @@ -0,0 +1,15 @@ +summary: irq-vector-tracepoints +description: irq-vector-tracepoints +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap-devel + - kernel-debuginfo +duration: 15m +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1020437 +extra-summary: /tools/systemtap/Regression/irq-vector-tracepoints +extra-task: /tools/systemtap/Regression/irq-vector-tracepoints diff --git a/tests/Regression/irq-vector-tracepoints/runtest.sh b/tests/Regression/irq-vector-tracepoints/runtest.sh new file mode 100755 index 0000000..9b88712 --- /dev/null +++ b/tests/Regression/irq-vector-tracepoints/runtest.sh @@ -0,0 +1,74 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/irq-vector-tracepoints +# Description: irq-vector-tracepoints +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2013 Red Hat, Inc. All rights reserved. +# +# This copyrighted material is made available to anyone wishing +# to use, modify, copy, or redistribute it subject to the terms +# and conditions of the GNU General Public License version 2. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public +# License along with this program; if not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +# Boston, MA 02110-1301, USA. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +rlJournalStart + rlPhaseStartSetup + rlRun "TMPDIR=$(mktemp -d)" + rlRun "pushd $TMPDIR" + rlRun "mount -t debugfs /dev/null /sys/kernel/debug" 0-255 + rlRun "test -d /sys/kernel/debug/tracing/events" + rlPhaseEnd + + rlPhaseStart FAIL "Systemtap sanity check" + rlRun "stap --version" + rlRun "stap -v -e 'probe kernel.function(\"vfs_read\"){ exit() }'" + rlPhaseEnd + + rlPhaseStart FAIL "Create list of all kernel tracepoints known to stap" + rlRun "stap -l 'kernel.trace(\"*\")' > tracepoints" + rlFileSubmit tracepoints + rlPhaseEnd + + rlPhaseStart FAIL "Check irq_vectors" + dir='/sys/kernel/debug/tracing/events/irq_vectors' + if test -d $dir; then + for p in $( find $dir -mindepth 1 -type d | awk -F\/ '{print $NF}' ); do + rlLogInfo "Checking $p" + rlRun "grep -q $p tracepoints" + done + # additional checks + rlRun "stap -vp4 -e 'probe kernel.trace(\"local_timer_entry\") {println(pp())}'" + rlRun "stap -vp4 -e 'probe kernel.trace(\"reschedule_entry\") {println(pp())}'" + else + if arch | egrep 'x86_64|i[36]86'; then + rlLogError "$dir does not exist" + else + rlLogInfo "$dir does not exist" + fi + fi + rlPhaseEnd + + rlPhaseStartCleanup + rlRun "popd" + rlRun "rm -r $TMPDIR" + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/netdev-receive/main.fmf b/tests/Regression/netdev-receive/main.fmf new file mode 100644 index 0000000..78ec038 --- /dev/null +++ b/tests/Regression/netdev-receive/main.fmf @@ -0,0 +1,14 @@ +summary: netdev.receive +description: bz1518462 netdev.receive +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap +duration: 15m +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1518462 +extra-summary: /tools/systemtap/Regression/netdev-receive +extra-task: /tools/systemtap/Regression/netdev-receive diff --git a/tests/Regression/netdev-receive/runtest.sh b/tests/Regression/netdev-receive/runtest.sh new file mode 100755 index 0000000..b184941 --- /dev/null +++ b/tests/Regression/netdev-receive/runtest.sh @@ -0,0 +1,44 @@ +#!/bin/bash +# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/netdev-receive +# Description: netdev.receive +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2017 Red Hat, Inc. +# +# This program is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation, either version 2 of +# the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see http://www.gnu.org/licenses/. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +PACKAGE="systemtap" +TMPFILE=$(mktemp) + +rlJournalStart + rlPhaseStartTest + # Here we rely on that netdev.receive gets hit immediately without us explicitly triggering it. + # Not all rhel-7 stap versions have -T already, so we use -E instead. + rlRun "stap -o $TMPFILE -ve 'probe netdev.receive{log(\"HIT\") exit()}' -E 'probe timer.s(10) {log(\"TIMEOUT\") exit()}'" + rlRun "cat $TMPFILE" + rlRun "grep HIT $TMPFILE" + rlRun "grep TIMEOUT $TMPFILE" 1 + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/pass-4-failure-netfilter-examples/main.fmf b/tests/Regression/pass-4-failure-netfilter-examples/main.fmf new file mode 100644 index 0000000..5244e99 --- /dev/null +++ b/tests/Regression/pass-4-failure-netfilter-examples/main.fmf @@ -0,0 +1,16 @@ +summary: Test for BZ#1055778 (Pass 4 failure on RHEL7 for examples) +description: Test for BZ#1055778 (Pass 4 failure on RHEL7 for examples) +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - valgrind + - systemtap + - systemtap-testsuite +duration: 30m +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1055778 +extra-summary: /tools/systemtap/Regression/pass-4-failure-netfilter-examples +extra-task: /tools/systemtap/Regression/pass-4-failure-netfilter-examples diff --git a/tests/Regression/pass-4-failure-netfilter-examples/runtest.sh b/tests/Regression/pass-4-failure-netfilter-examples/runtest.sh new file mode 100755 index 0000000..2eed9af --- /dev/null +++ b/tests/Regression/pass-4-failure-netfilter-examples/runtest.sh @@ -0,0 +1,55 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/pass-4-failure-netfilter-examples +# Description: Test for BZ#1055778 (Pass 4 failure on RHEL7 for examples) +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2014 Red Hat, Inc. +# +# This copyrighted material is made available to anyone wishing +# to use, modify, copy, or redistribute it subject to the terms +# and conditions of the GNU General Public License version 2. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public +# License along with this program; if not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +# Boston, MA 02110-1301, USA. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +PACKAGE="systemtap" + +rlJournalStart + rlPhaseStartSetup + TESTS=$(mktemp) + rlRun "rpm -qa | fgrep systemtap-testsuite" + rlPhaseEnd + + rpm -qa | grep systemtap-testsuite | xargs rpm -ql \ + | egrep 'netfilter_drop.stp|netfilter_summary.stp' \ + | while read line; do + rlPhaseStart FAIL "Testing $line" + rlRun "stap -p4 $line -v -g TCP 1" && \ + echo $line >> $TESTS + rlPhaseEnd + done + + rlPhaseStart FAIL "Check what was tested" + rlRun "grep netfilter_drop.stp $TESTS" + rlRun "grep netfilter_summary.stp $TESTS" + rm -f $TESTS + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/python-probing/main.fmf b/tests/Regression/python-probing/main.fmf index 1a5ec22..55b3281 100644 --- a/tests/Regression/python-probing/main.fmf +++ b/tests/Regression/python-probing/main.fmf @@ -1,10 +1,5 @@ summary: Systemtap static probes test -description: | - This test checks basic functionality of Python's systemtap static - probes. It runs list & top systemtap scripts (examples from the - python rpm) and then a python script using the "random" module. - Finally it checks that the "random" module is correctly listed in - the output of both systemtap scripts. +description: Systemtap static probes test contact: Petr Splichal component: - python @@ -21,3 +16,4 @@ recommend: duration: 15m extra-summary: /CoreOS/python/Sanity/systemtap extra-task: /CoreOS/python/Sanity/systemtap +tier: 1 diff --git a/tests/Regression/second-command-not-captured/main.fmf b/tests/Regression/second-command-not-captured/main.fmf new file mode 100644 index 0000000..7b88ecc --- /dev/null +++ b/tests/Regression/second-command-not-captured/main.fmf @@ -0,0 +1,16 @@ +summary: second-command-not-captured +description: second-command-not-captured +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap + - ruby + - ruby-libs +duration: 48h +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1857749 +extra-summary: /tools/systemtap/Regression/second-command-not-captured +extra-task: /tools/systemtap/Regression/second-command-not-captured diff --git a/tests/Regression/second-command-not-captured/ruby-exercise.stp b/tests/Regression/second-command-not-captured/ruby-exercise.stp new file mode 100644 index 0000000..404fdd1 --- /dev/null +++ b/tests/Regression/second-command-not-captured/ruby-exercise.stp @@ -0,0 +1,7 @@ +probe ruby.method.entry, ruby.cmethod.entry { + printf("%d -> %s::%s %s:%d\n", tid(), classname, methodname, file, line); +} + +probe ruby.method.return, ruby.cmethod.return { + printf("%d <- %s::%s %s:%d\n", tid(), classname, methodname, file, line); +} diff --git a/tests/Regression/second-command-not-captured/runtest.sh b/tests/Regression/second-command-not-captured/runtest.sh new file mode 100755 index 0000000..fddabd1 --- /dev/null +++ b/tests/Regression/second-command-not-captured/runtest.sh @@ -0,0 +1,42 @@ +#!/bin/bash +# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/second-command-not-captured +# Description: second-command-not-captured +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2020 Red Hat, Inc. +# +# This program is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation, either version 2 of +# the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see http://www.gnu.org/licenses/. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +PACKAGE="systemtap" + +rlJournalStart + rlPhaseStartTest + rlLog "`which stap`" + rlLog "`stap -V`" + rlRun "stap -s 100 -v ./ruby-exercise.stp -c ./test.sh -o stap.log" + rlRun "grep 'Array::push' stap.log" || + rlFileSubmit "stap.log" + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/second-command-not-captured/test.sh b/tests/Regression/second-command-not-captured/test.sh new file mode 100755 index 0000000..d308ba2 --- /dev/null +++ b/tests/Regression/second-command-not-captured/test.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +set -e + +ruby -e 'puts "ABC"' +ruby -e '[1, 2, 3].push(4)' +sleep 10 diff --git a/tests/Regression/selected-parts-of-upstream-testsuite/main.fmf b/tests/Regression/selected-parts-of-upstream-testsuite/main.fmf new file mode 100644 index 0000000..a1d57ec --- /dev/null +++ b/tests/Regression/selected-parts-of-upstream-testsuite/main.fmf @@ -0,0 +1,23 @@ +summary: selected-parts-of-upstream-testsuite +description: '' +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap + - libstdc++ + - dejagnu + - elfutils-devel + - gettext + - libgcc + - glibc-devel + - gcc-c++ + - libstdc++-devel + - dyninst + - dyninst-devel + - systemtap-testsuite +duration: 48h +extra-summary: /tools/systemtap/Regression/selected-parts-of-upstream-testsuite +extra-task: /tools/systemtap/Regression/selected-parts-of-upstream-testsuite diff --git a/tests/Regression/selected-parts-of-upstream-testsuite/runtest.sh b/tests/Regression/selected-parts-of-upstream-testsuite/runtest.sh new file mode 100755 index 0000000..7c2882b --- /dev/null +++ b/tests/Regression/selected-parts-of-upstream-testsuite/runtest.sh @@ -0,0 +1,184 @@ +#!/bin/bash +# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/selected-parts-of-upstream-testsuite +# Description: selected-parts-of-upstream-testsuite +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2017 Red Hat, Inc. +# +# This program is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation, either version 2 of +# the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see http://www.gnu.org/licenses/. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Be tolerant about selinux +export AVC_ERROR='+no_avc_check' + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +DMESG1=$(mktemp) +DMESG2=$(mktemp) + +PACKAGE="systemtap" + +SUBTESTS="\ +attach_detach.exp \ +bz1126645.exp \ +bz1214176.exp \ +bz1252436.exp \ +exelib.exp \ +pr22005.exp \ +server.exp \ +systemtap-service.exp \ +task_dentry_path.exp \ +task_paths.exp \ +tracepoints.exp \ +" + +blacklist_subtest() +{ + token=${1/\//\\/} + SUBTESTS=${SUBTESTS/$token/} +} + +P4TESTS="\ +buildok/nfs-all-probes.stp \ +buildok/nfs-detailed.stp \ +buildok/nfs-fop.check_flags.stp \ +buildok/nfs_proc-detailed.stp \ +buildok/nfsd-all-probes.stp \ +buildok/nfsd-detailed.stp \ +systemtap.examples/io/nfs_func_users.stp \ +systemtap.examples/network/nfsdtop.stp \ +" + +blacklist_p4() +{ + token=${1/\//\\/} + P4TESTS=${P4TESTS/$token/} +} + +if [[ $(rpm --eval '%{rhel}') -ge 8 ]]; then + # mjw authored that testcase - had been notified + arch | fgrep 'x86_64' && blacklist_subtest 'exelib.exp' + + blacklist_p4 'buildok/nfs-fop.check_flags.stp' + blacklist_p4 'buildok/nfs_proc-detailed.stp' + blacklist_p4 'buildok/nfsd-detailed.stp' + # bz1709831 + blacklist_p4 'buildok/nfs-detailed.stp' + arch | fgrep -q ppc64le && blacklist_p4 'buildok/nfs-all-probes.stp' +elif [[ $(rpm --eval '%{rhel}') -eq 7 ]]; then + # RHEL-ALT + if rpm -qi kernel | fgrep -q kernel-alt; then + # at_var.exp is expected to fail on Pegas - https://bugzilla.redhat.com/show_bug.cgi?id=1165848#c7 + blacklist_subtest 'at_var.exp' + fi + + # bz1107616, bz1698737 + blacklist_p4 'buildok/nfsd-detailed.stp' + if arch | fgrep -q ppc64le; then + blacklist_p4 'buildok/nfs-all-probes.stp' + blacklist_p4 'buildok/nfs-detailed.stp' + blacklist_p4 'buildok/nfsd-all-probes.stp' + fi +elif [[ $(rpm --eval '%{rhel}') -le 6 ]]; then + true +fi + +which stap | fgrep -q toolset && blacklist_subtest 'modules_out_of_tree.exp' + +rlJournalStart + rlPhaseStartSetup + TESTSUITERPM="$(rpm --queryformat='%{name}\n' -qf $(which stap) | head -1 | grep -o '.*systemtap')-testsuite" + rlLogInfo "$(rpm -q $TESTSUITERPM)" + TESTSUITEDIR="$(rpm -ql $TESTSUITERPM | grep -o '.*share/systemtap/testsuite/' | head -1)" + rlLogInfo "$TESTSUITEDIR" + + # For devtoolset, compat arch support was dropped for non-x86_64 arches. Ref: bz1493500 + if echo $TESTSUITEDIR | grep -q toolset && arch | egrep -q '^(ppc64|s390x)$'; then + sed -i '/^proc arch_compile_flags/,/^}/d' $TESTSUITEDIR/lib/compile_flags.exp + echo 'proc arch_compile_flags {} { return 1 }' >> $TESTSUITEDIR/lib/compile_flags.exp + fi + + # Need to suppress warnings so that task_dentry_path.exp can pass + # And --skip-badvars to let task_paths.exp pass + rlRun "sed -i 's/--rlimit-cpu=850/-w --skip-badvars \0/' $TESTSUITEDIR/lib/systemtap.exp" + + rlServiceStop firewalld + rlServiceStop iptables + rlServiceStop ip6tables + rlServiceStart avahi-daemon + rlRun "rpm -qa | grep ^kernel | grep -v `uname -r` | xargs rpm -e" 0-255 + rlRun "stap-prep" 0,127 + PKGMGR="yum --skip-broken --nogpgcheck" + rpm -q dnf && PKGMGR="dnf --setopt=strict=0 --nogpgcheck" + rlRun "$PKGMGR -y install --setopt=multilib_policy=all libstdc++ dejagnu elfutils-devel gettext libgcc glibc-devel gcc-c++ libstdc++-devel dyninst dyninst-devel" + rlRun "sysctl -w kernel.panic=1" + rlRun "sysctl -w kernel.panic_on_oops=1" + rlPhaseEnd + + rlPhaseStartTest + rlRun "cd $TESTSUITEDIR" + rlRun "make clean" + rlRun "dmesg > $DMESG1" + rlRun "make installcheck RUNTESTFLAGS=\"${RUNTESTFLAGS:-$SUBTESTS}\"" + rlRun "dmesg > $DMESG2" + rlLogInfo "$SUBTESTS" + rlDejaSum "systemtap.sum" + rlFileSubmit "systemtap.log" + rlFileSubmit "systemtap.sum" + rlPhaseEnd + + rlPhaseStart FAIL "Run selected -p4 tests" + for t in $P4TESTS; do + rlLogInfo "Trying to compile $t without prologue search ..." + ADDSWITCHES='' + stap $ADDSWITCHES -w -o /dev/null -p4 $t || ADDSWITCHES='-P' + rlRun "stap $ADDSWITCHES -w -p4 $t" + done + rlPhaseEnd + + rlPhaseStart FAIL "Check for BUG: in dmesg" + rlRun "diff $DMESG1 $DMESG2" 0-255 + rlRun "diff $DMESG1 $DMESG2 | grep 'BUG:'" 1 + rlPhaseEnd + + rlPhaseStart FAIL "Evaluate test results" + TEMPLOG=$(mktemp) + rlRun "cp systemtap.sum $TEMPLOG" + # BLACKLIST + if which stap | grep -q toolset; then + rlLogInfo "Ignore boot time probing subtest FAILures per bz1121363#c20 for devtoolset" + sed -i '/^FAIL: stap-service::boot probing - install script/d' $TEMPLOG + sed -i '/^FAIL: stap-service::boot probing - check script/d' $TEMPLOG + fi + # check for failures + rlRun "grep ^PASS $TEMPLOG" 0 "Assert a/some PASS" + rlRun "grep ^FAIL $TEMPLOG" 1 "Assert no FAIL" + rm -f $TEMPLOG + rlPhaseEnd + + rlPhaseStartCleanup + rlServiceRestore firewalld + rlServiceRestore iptables + rlServiceRestore ip6tables + rlServiceRestore avahi-daemon + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/semantic-error-nfs-proc-read_setup/main.fmf b/tests/Regression/semantic-error-nfs-proc-read_setup/main.fmf new file mode 100644 index 0000000..72489b4 --- /dev/null +++ b/tests/Regression/semantic-error-nfs-proc-read_setup/main.fmf @@ -0,0 +1,14 @@ +summary: semantic-error-nfs-proc-read_setup +description: semantic-error-nfs-proc-read_setup +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap +duration: 5m +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=884951 +extra-summary: /tools/systemtap/Regression/semantic-error-nfs-proc-read_setup +extra-task: /tools/systemtap/Regression/semantic-error-nfs-proc-read_setup diff --git a/tests/Regression/semantic-error-nfs-proc-read_setup/nfs.proc.read_setup.stp b/tests/Regression/semantic-error-nfs-proc-read_setup/nfs.proc.read_setup.stp new file mode 100644 index 0000000..c6974c7 --- /dev/null +++ b/tests/Regression/semantic-error-nfs-proc-read_setup/nfs.proc.read_setup.stp @@ -0,0 +1,5 @@ +probe nfs.proc.read_setup{ + println("nfs.proc.read_setup server_ip: ", server_ip); + println("nfs.proc.read_setup prot: ", prot); +} + diff --git a/tests/Regression/semantic-error-nfs-proc-read_setup/runtest.sh b/tests/Regression/semantic-error-nfs-proc-read_setup/runtest.sh new file mode 100755 index 0000000..d14e39b --- /dev/null +++ b/tests/Regression/semantic-error-nfs-proc-read_setup/runtest.sh @@ -0,0 +1,45 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/semantic-error-nfs-proc-read_setup +# Description: semantic-error-nfs-proc-read_setup +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2013 Red Hat, Inc. All rights reserved. +# +# This copyrighted material is made available to anyone wishing +# to use, modify, copy, or redistribute it subject to the terms +# and conditions of the GNU General Public License version 2. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public +# License along with this program; if not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +# Boston, MA 02110-1301, USA. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +rlJournalStart + rlPhaseStartSetup + rlRun "uname -r" + rlRun "rpm -qa | grep ^kernel | sort" + rlRun "rpm -qa | grep systemtap | sort" + rlRun "which stap" + rlPhaseEnd + + rlPhaseStartTest + rlRun "stap -v -p 2 nfs.proc.read_setup.stp" + rlPhaseEnd + +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/semantic-errors-bz1062076/main.fmf b/tests/Regression/semantic-errors-bz1062076/main.fmf new file mode 100644 index 0000000..ca70df0 --- /dev/null +++ b/tests/Regression/semantic-errors-bz1062076/main.fmf @@ -0,0 +1,14 @@ +summary: semantic-errors-bz1062076 +description: '' +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap +duration: 30m +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1062076 +extra-summary: /tools/systemtap/Regression/semantic-errors-bz1062076 +extra-task: /tools/systemtap/Regression/semantic-errors-bz1062076 diff --git a/tests/Regression/semantic-errors-bz1062076/runtest.sh b/tests/Regression/semantic-errors-bz1062076/runtest.sh new file mode 100755 index 0000000..3f53859 --- /dev/null +++ b/tests/Regression/semantic-errors-bz1062076/runtest.sh @@ -0,0 +1,40 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/semantic-errors-bz1062076 +# Description: semantic-errors-bz1062076 +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2014 Red Hat, Inc. +# +# This copyrighted material is made available to anyone wishing +# to use, modify, copy, or redistribute it subject to the terms +# and conditions of the GNU General Public License version 2. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public +# License along with this program; if not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +# Boston, MA 02110-1301, USA. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +rlJournalStart + rlPhaseStartTest + rlLogInfo "Check if we might want to try out prologue search" + p="" + stap -vp4 sript.stp >& /dev/null || p="-P" + rlRun "stap $p -vp4 script.stp" + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/semantic-errors-bz1062076/script.stp b/tests/Regression/semantic-errors-bz1062076/script.stp new file mode 100644 index 0000000..7527474 --- /dev/null +++ b/tests/Regression/semantic-errors-bz1062076/script.stp @@ -0,0 +1,3 @@ +probe nfsd.close? { printf("%s\n", filename) } probe never { exit() } +probe sunrpc.clnt.clone_client { print(progname) } +probe scsi.iodone { printf("%d, %d, %d, %d, %d, %d, %d, %d\n", host_no, channel, lun, dev_id, device_state, data_direction, req_addr, scsi_timer_pending ) } diff --git a/tests/Regression/semantic-errors-bz953776/main.fmf b/tests/Regression/semantic-errors-bz953776/main.fmf new file mode 100644 index 0000000..c95eaee --- /dev/null +++ b/tests/Regression/semantic-errors-bz953776/main.fmf @@ -0,0 +1,17 @@ +summary: semantic-errors-bz953776 +description: '' +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +require: +recommend: + - systemtap + - perf + - gcc +duration: 60m +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=953776 +extra-summary: /tools/systemtap/Regression/semantic-errors-bz953776 +extra-task: /tools/systemtap/Regression/semantic-errors-bz953776 diff --git a/tests/Regression/semantic-errors-bz953776/runtest.sh b/tests/Regression/semantic-errors-bz953776/runtest.sh new file mode 100755 index 0000000..28e9359 --- /dev/null +++ b/tests/Regression/semantic-errors-bz953776/runtest.sh @@ -0,0 +1,161 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/semantic-errors-bz953776 +# Description: semantic-errors-bz953776 +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2014 Red Hat, Inc. +# +# This copyrighted material is made available to anyone wishing +# to use, modify, copy, or redistribute it subject to the terms +# and conditions of the GNU General Public License version 2. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public +# License along with this program; if not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +# Boston, MA 02110-1301, USA. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +_rhelmajor=$(rpm --eval '%{rhel}') +_arch=$(arch) + +function perf_probe_failed () +{ + probe=$1 + perf probe -d $probe ||: + perf probe --add $probe + retval=$? + test $retval -eq 0 && \ + rlLogInfo "Running perf probe --add $probe PASSED" || \ + rlLogInfo "Running perf probe --add $probe FAILED" + perf probe -d $probe ||: + if test $retval -eq 0; then + return 1 + else + return 0 + fi +} + +function perf_found_none_of () +{ + ret=0 + for f in "$@"; do + perf_probe_failed $f || ret=1 + done + return $ret +} + +rlJournalStart + # CHECK FOR PERF ---------------------------------------------- + rlPhaseStart FAIL "CHECK FOR PERF" + rlRun "perf --version" + rlPhaseEnd + + rlPhaseStartSetup + rlRun "TMPDIR=$(mktemp -d)" + rlRun "pushd $TMPDIR" + + # prepare sigaltstack for case-5 + cat > sigaltstack.c < +#include +void handler(int sig) +{ + write(2, "stack overflow\n", 15); + _exit(1); +} +unsigned infinite_recursion(unsigned x) { + return infinite_recursion(x)+1; +} +int main() +{ + static char stack[SIGSTKSZ]; + stack_t ss = { + .ss_size = SIGSTKSZ, + .ss_sp = stack, + }; + struct sigaction sa = { + .sa_handler = handler, + .sa_flags = SA_ONSTACK + }; + sigaltstack(&ss, 0); + sigfillset(&sa.sa_mask); + sigaction(SIGSEGV, &sa, 0); + infinite_recursion(0); +} +EOF + rlRun "gcc -o sigaltstack sigaltstack.c" + rlPhaseEnd + + p="" + uname -m | grep -q ^ppc && p="-P" + p="$p -E 'probe timer.s(900){error(\"probe timeout after 15 minutes\")}'" + + export p + + rlPhaseStart FAIL 'case-1' + rlRun "stap $p -v -e 'probe syscall.close { println(fd); exit(); }'" + rlPhaseEnd + + # After fixing bz1657681, this constraint can be removed + if [[ $(rpm --eval %rhel) -le 7 ]]; then + if arch | grep -vq ppc; then + rlPhaseStart FAIL 'case-2' + # https://bugzilla.redhat.com/show_bug.cgi?id=1657681 + rlRun "stap $p -v -e 'probe socket.close { print(protocol); print(family); print(state); print(flags); print(type); exit() }'" + rlPhaseEnd + fi + fi + + ( + test $_rhelmajor -le 8 && exit + perf_found_none_of "sys_read" "__arm64_sys_read" "do_syscall_64" && exit + test $_rhelmajor -ge 9 && test $_arch = ppc64le -o $_arch = aarch64 && p="$p -p4" # no hits + rlPhaseStart FAIL 'case-3' + rlRun "stap $p -v -e 'probe kernel.function(\"sys_read\").return!, kernel.function(\"__arm64_sys_read\").return!, kernel.function(\"do_syscall_64\").return { println(probefunc()) exit()}'" + rlPhaseEnd + ) + + rlPhaseStart FAIL 'case-4' + rlRun "stap $p -v -e 'probe syscall.open, syscall.openat { if (\"open\" == execname()) println(argstr); exit() }'" + rlPhaseEnd + + rlPhaseStart FAIL 'case-5' + rlRun "stap $p -ve 'probe syscall.sigaltstack { println(name); exit() }' -c './sigaltstack || true'" + rlPhaseEnd + + # gcc 8.2.1->8.3.1 change related to systemtap debuginfo regression in rhel-8.1.0, kernel -84 -> -85 + # https://bugzilla.redhat.com/show_bug.cgi?id=1709831#c17 + # ( fgrep RESULT: /tmp/typescript | sort -u ) + rlPhaseStart FAIL 'case-6' + rlRun "stap $p -vp4 -e 'probe sunrpc.clnt.shutdown_client { println(servername) }'" + rlPhaseEnd + + rlPhaseStart FAIL 'case-7' + rlRun "stap $p -vp4 -e 'probe sunrpc.clnt.bind_new_program { println(servername) }'" + rlPhaseEnd + + rlPhaseStart FAIL 'case-8' + rlRun "stap $p -vp4 -e 'probe sunrpc.clnt.bind_new_program { println(servername, vers) }'" + rlPhaseEnd + + rlPhaseStartCleanup + rlRun "popd" + rlRun "rm -r $TMPDIR" + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/small-tests/main.fmf b/tests/Regression/small-tests/main.fmf index d659ce8..caa5060 100644 --- a/tests/Regression/small-tests/main.fmf +++ b/tests/Regression/small-tests/main.fmf @@ -1,4 +1,4 @@ -summary: suns small tests +summary: Small tests description: '' contact: Martin Cermak component: @@ -12,3 +12,4 @@ recommend: duration: 10m extra-summary: /tools/systemtap/Regression/small-tests extra-task: /tools/systemtap/Regression/small-tests +tier: 1 diff --git a/tests/Regression/small-tests/runtest.sh b/tests/Regression/small-tests/runtest.sh index 6f3e1c2..3b89566 100755 --- a/tests/Regression/small-tests/runtest.sh +++ b/tests/Regression/small-tests/runtest.sh @@ -179,5 +179,44 @@ rlJournalStart rlPhaseStart FAIL "test 12 bz1940761" rlRun "stap -v /usr/share/systemtap/examples/process/strace.stp -w -c \"echo hello world\"" rlPhaseEnd + + # broken-tapset-print-ubacktrace ------------------------------ + rlPhaseStart FAIL "test 13 broken-tapset-print-ubacktrace" + rlRun "stap -p4 -e 'probe begin { print_ubacktrace() }'" + rlPhaseEnd + + # Protected from elision -------------------------------------- + rlPhaseStart FAIL "test 14 protected from elision" + rlRun "stap -v -e 'probe nfs.fop.fsync {} probe begin {print(\"Protected from elision\")}' -c true |\ + fgrep 'Protected from elision'" + rlPhaseEnd + + # bz544207 ---------------------------------------------------- + rlPhaseStart FAIL "test 15 bz544207" + extra_opts="" + stap -vp4 -e 'probe nfs.proc.write_setup{ println(how) }' || extra_opts="-P" + rlRun "stap $extra_opts -vp4 -e 'probe nfs.proc.write_setup{ println(how) }'" + rlPhaseEnd + + # bz544209 ---------------------------------------------------- + rlPhaseStart FAIL "test 16 bz544209" + rlRun "stap -vp2 -e 'probe sunrpc.clnt.create_client.return {}'" + rlPhaseEnd + + # bz592830 ---------------------------------------------------- + rlPhaseStart FAIL "test 17 bz592830" + rlRun "stap -vp2 -e 'probe signal.check_ignored.return {println(1)}'" + rlPhaseEnd + + # caller-does-not-work ---------------------------------------- + rlPhaseStart FAIL "test 18 caller-does-not-work" + rlRun "stap -ve 'probe kernel.function(\"vfs_read\") \ + { printf(\"%s\n\", caller()); exit() }' 2>&1 | tee strace.log" + rlPhaseEnd + + # missing-rpc-tracepoints ------------------------------------- + rlPhaseStart FAIL "test 19 missing-rpc-tracepoints" + rlRun "stap -L 'kernel.trace(\"rpc*\")'" + rlPhaseEnd rlJournalPrintText rlJournalEnd diff --git a/tests/Regression/stap-ERROR-Build-id-mismatch-with/main.fmf b/tests/Regression/stap-ERROR-Build-id-mismatch-with/main.fmf new file mode 100644 index 0000000..6744a8d --- /dev/null +++ b/tests/Regression/stap-ERROR-Build-id-mismatch-with/main.fmf @@ -0,0 +1,14 @@ +summary: Test for BZ#1566422 (stap ERROR Build-id mismatch with) +description: '' +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap +duration: 48h +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1566422 +extra-summary: /tools/systemtap/Regression/stap-ERROR-Build-id-mismatch-with +extra-task: /tools/systemtap/Regression/stap-ERROR-Build-id-mismatch-with diff --git a/tests/Regression/stap-ERROR-Build-id-mismatch-with/runtest.sh b/tests/Regression/stap-ERROR-Build-id-mismatch-with/runtest.sh new file mode 100755 index 0000000..f026393 --- /dev/null +++ b/tests/Regression/stap-ERROR-Build-id-mismatch-with/runtest.sh @@ -0,0 +1,43 @@ +#!/bin/bash +# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/stap-ERROR-Build-id-mismatch-with +# Description: Test for BZ#1566422 (stap ERROR Build-id mismatch with) +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2018 Red Hat, Inc. +# +# This program is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation, either version 2 of +# the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see http://www.gnu.org/licenses/. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +PACKAGE="systemtap" + +rlJournalStart + rlPhaseStartTest + if arch | grep -q s390x; then + rlLogWarning "Test not relevant" + else + rlRun "sudo modprobe igb" + rlRun "stap -e 'probe module(\"igb\").function(\"igb_*_module\") { printf(\"%s: %s.\n\", ctime(gettimeofday_s()), ppfunc()); }' -c \"bash -c 'sudo rmmod igb; sudo modprobe igb'\"" + fi + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/stapio-possible-circular-locking-dependency/main.fmf b/tests/Regression/stapio-possible-circular-locking-dependency/main.fmf new file mode 100644 index 0000000..c1bafab --- /dev/null +++ b/tests/Regression/stapio-possible-circular-locking-dependency/main.fmf @@ -0,0 +1,15 @@ +summary: Test for BZ#1020207 (stapio possible circular locking dependency) +description: '' +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +require: +recommend: + - systemtap +duration: 4h +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1020207 +extra-summary: /tools/systemtap/Regression/stapio-possible-circular-locking-dependency +extra-task: /tools/systemtap/Regression/stapio-possible-circular-locking-dependency diff --git a/tests/Regression/stapio-possible-circular-locking-dependency/runtest.sh b/tests/Regression/stapio-possible-circular-locking-dependency/runtest.sh new file mode 100755 index 0000000..856197c --- /dev/null +++ b/tests/Regression/stapio-possible-circular-locking-dependency/runtest.sh @@ -0,0 +1,74 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/stapio-possible-circular-locking-dependency +# Description: Test for BZ#1020207 (stapio possible circular locking dependency) +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2014 Red Hat, Inc. +# +# This copyrighted material is made available to anyone wishing +# to use, modify, copy, or redistribute it subject to the terms +# and conditions of the GNU General Public License version 2. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public +# License along with this program; if not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +# Boston, MA 02110-1301, USA. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +rlJournalStart + rlPhaseStartSetup + rlRun "TMPDIR=\$(mktemp -d)" + rlRun "pushd $TMPDIR" + cat > test5.stap < reproduce.sh < /proc/sys/vm/drop_caches + stap test5.stap -c "sleep 2" + if dmesg 2>&1 | grep "possible circular locking dependency detected"; then + dmesg + exit 1 + fi +done +exit 0 +EOF + + rlRun "chmod +x reproduce.sh" + rlPhaseEnd + + rlPhaseStartTest + TO=180 # timeout seconds + # when timeout TO is hit, exitcode 124 is returned + rlRun "timeout $TO ./reproduce.sh" 0,124 + # if issue doesn't get reproduced within TO, the test will pass + rlPhaseEnd + + rlPhaseStartCleanup + rlRun "popd" + rlRun "rm -r $TMPDIR" + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/suspicious-RCU-usage/main.fmf b/tests/Regression/suspicious-RCU-usage/main.fmf new file mode 100644 index 0000000..5e9c792 --- /dev/null +++ b/tests/Regression/suspicious-RCU-usage/main.fmf @@ -0,0 +1,14 @@ +summary: suspicious-RCU-usage +description: '' +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap +duration: 48h +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1788662 +extra-summary: /tools/systemtap/Regression/suspicious-RCU-usage +extra-task: /tools/systemtap/Regression/suspicious-RCU-usage diff --git a/tests/Regression/suspicious-RCU-usage/runtest.sh b/tests/Regression/suspicious-RCU-usage/runtest.sh new file mode 100755 index 0000000..bd11b63 --- /dev/null +++ b/tests/Regression/suspicious-RCU-usage/runtest.sh @@ -0,0 +1,49 @@ +#!/bin/bash +# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/suspicious-RCU-usage +# Description: suspicious-RCU-usage +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2020 Red Hat, Inc. +# +# This program is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation, either version 2 of +# the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see http://www.gnu.org/licenses/. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +PACKAGE="systemtap" + +rlJournalStart + rlPhaseStartTest + dmesg1=$(mktemp) + dmesg2=$(mktemp) + diff=$(mktemp) + dmesg > $dmesg1 + rlRun "stap -e 'probe kernel.trace(\"*\"){}' -t -u -v -c '/bin/true'" + sleep 10 + dmesg > $dmesg2 + rlRun "diff $dmesg1 $dmesg2 |& tee $diff" + # Reproduced on hpe-moonshot-02-c02.hpe1.lab.eng.bos.redhat.com + # using kernel-4.18.0-167.el8.aarch64+debug and systemtap-4.2-1.el8.aarch64. + rlRun "fgrep -i rcu $diff" 1 + rm $dmesg{1,2} $diff + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/syscall-get-arguments-returning-wrong-value/main.fmf b/tests/Regression/syscall-get-arguments-returning-wrong-value/main.fmf new file mode 100644 index 0000000..da42eb6 --- /dev/null +++ b/tests/Regression/syscall-get-arguments-returning-wrong-value/main.fmf @@ -0,0 +1,15 @@ +summary: Test for BZ#1004059 (syscall_get_arguments() returning wrong value) +description: '' +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap + - perf +duration: 30m +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1004059 +extra-summary: /tools/systemtap/Regression/syscall-get-arguments-returning-wrong-value +extra-task: /tools/systemtap/Regression/syscall-get-arguments-returning-wrong-value diff --git a/tests/Regression/syscall-get-arguments-returning-wrong-value/runtest.sh b/tests/Regression/syscall-get-arguments-returning-wrong-value/runtest.sh new file mode 100755 index 0000000..182d69c --- /dev/null +++ b/tests/Regression/syscall-get-arguments-returning-wrong-value/runtest.sh @@ -0,0 +1,76 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/syscall-get-arguments-returning-wrong-value +# Description: Test for BZ#1004059 (syscall_get_arguments() returning wrong value) +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2014 Red Hat, Inc. +# +# This copyrighted material is made available to anyone wishing +# to use, modify, copy, or redistribute it subject to the terms +# and conditions of the GNU General Public License version 2. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public +# License along with this program; if not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +# Boston, MA 02110-1301, USA. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + + +ASMLINKAGE=''; +uname -m | egrep 'i[36]86' && \ + ASMLINKAGE='asmlinkage();' + +SCRIPT=$( mktemp ) +cat > $SCRIPT <<-EOF +probe kernel.function("sys_open") { + $ASMLINKAGE + if (\$filename == pointer_arg(1)) { + exit(); + } else { + error("Possible manifestation of rhbz1004059."); + } +} +EOF + +function perf_probe_failed () +{ + probe=$1 + perf probe -d $probe ||: + perf probe --add $probe + retval=$? + test $retval -eq 0 && \ + rlLogInfo "Running perf probe --add $probe PASSED" || \ + rlLogInfo "Running perf probe --add $probe FAILED" + perf probe -d $probe ||: + if test $retval -eq 0; then + return 1 + else + return 0 + fi +} + +rlJournalStart + rlPhaseStartTest + ( + perf_probe_failed "sys_open" && exit + stap -p4 $SCRIPT >&/dev/null && p="" || p='-P' + rlRun "stap $p -v $SCRIPT -c 'cat /dev/null'" + ) + rm $SCRIPT + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/main.fmf b/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/main.fmf new file mode 100644 index 0000000..97ec25b --- /dev/null +++ b/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/main.fmf @@ -0,0 +1,14 @@ +summary: task-cwd-path-results-in-an-in-kernel-memory-leak +description: '' +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap +duration: 48h +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1412691 +extra-summary: /tools/systemtap/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak +extra-task: /tools/systemtap/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak diff --git a/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/reproducer.stp b/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/reproducer.stp new file mode 100644 index 0000000..ff15bbb --- /dev/null +++ b/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/reproducer.stp @@ -0,0 +1,10 @@ +probe kprocess.exit +{ + path=fullpath_struct_path(task_cwd_path(task_current())) + printf("%s\n", path) +} + +#probe timer.s(240) +#{ +# exit() +#} diff --git a/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/runtest.sh b/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/runtest.sh new file mode 100755 index 0000000..aa64f4e --- /dev/null +++ b/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/runtest.sh @@ -0,0 +1,46 @@ +#!/bin/bash +# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak +# Description: task-cwd-path-results-in-an-in-kernel-memory-leak +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2017 Red Hat, Inc. +# +# This program is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation, either version 2 of +# the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see http://www.gnu.org/licenses/. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +PACKAGE="systemtap" + +rlJournalStart + rlPhaseStartTest + EXTRA="" + arch | fgrep ppc64le && EXTRA='-P' + + # We rely on (and check for) units to be kB + rlRun "test \"$( awk '/KernelStack/ {print $3}' /proc/meminfo )\" == \"kB\"" + rlRun "STACK1=$(awk '/KernelStack/ {print $2}' /proc/meminfo)" + rlRun "stap $EXTRA -w reproducer.stp -c 'bash ./trigger.sh' -o /dev/null" + rlRun "STACK2=$(awk '/KernelStack/ {print $2}' /proc/meminfo)" + rlRun "test $((STACK2 - 1000)) -le $STACK1" + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/trigger.sh b/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/trigger.sh new file mode 100755 index 0000000..165bd9a --- /dev/null +++ b/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/trigger.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +for i in `seq 1 2000`; do + ls / > /dev/null +done + + diff --git a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/main.fmf b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/main.fmf new file mode 100644 index 0000000..547e173 --- /dev/null +++ b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/main.fmf @@ -0,0 +1,14 @@ +summary: task-exe-file-results-in-an-file-struct-leak +description: '' +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap +duration: 48h +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1430861 +extra-summary: /tools/systemtap/Regression/task-exe-file-results-in-an-file-struct-leak +extra-task: /tools/systemtap/Regression/task-exe-file-results-in-an-file-struct-leak diff --git a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/reproducer.stp b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/reproducer.stp new file mode 100644 index 0000000..2dd39bb --- /dev/null +++ b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/reproducer.stp @@ -0,0 +1,6 @@ +probe kprocess.exit +{ + t=task_current() + path=fullpath_struct_file(t, task_exe_file(t)) + printf("%s\n", path) +} diff --git a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/reproducer2.stp b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/reproducer2.stp new file mode 100644 index 0000000..f26764a --- /dev/null +++ b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/reproducer2.stp @@ -0,0 +1,5 @@ +probe kprocess.exit +{ + path=fullpath_struct_path(task_cwd_path(task_current())) + printf("%s\n", path) +} diff --git a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/runtest.sh b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/runtest.sh new file mode 100755 index 0000000..0c4e643 --- /dev/null +++ b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/runtest.sh @@ -0,0 +1,45 @@ +#!/bin/bash +# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/task-exe-file-results-in-an-file-struct-leak +# Description: task-exe-file-results-in-an-file-struct-leak +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2017 Red Hat, Inc. +# +# This program is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation, either version 2 of +# the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see http://www.gnu.org/licenses/. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +PACKAGE="systemtap" + +rlJournalStart + rlPhaseStartTest + EXTRA='' + arch | fgrep ppc64le && EXTRA="-P" + rlRun "FILE_NR1=$(awk '{print $1}' /proc/sys/fs/file-nr)" + REPRODUCER=reproducer.stp + rlRun "stap -g -w $EXTRA --dump-functions | fgrep task_exe_file || REPRODUCER=reproducer2.stp" + rlRun "stap -w $EXTRA $REPRODUCER -c 'bash ./trigger.sh' -o /dev/null" + rlRun "FILE_NR2=$(awk '{print $1}' /proc/sys/fs/file-nr)" + rlRun "test $((FILE_NR2 - 1000)) -le $FILE_NR1" + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/trigger.sh b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/trigger.sh new file mode 100755 index 0000000..31ee2bb --- /dev/null +++ b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/trigger.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +for i in `seq 1 100000`; do + /bin/true +done + + diff --git a/tests/Regression/testsuite-upstream-raw/check_BPF.sh b/tests/Regression/testsuite-upstream-raw/check_BPF.sh new file mode 100755 index 0000000..325b894 --- /dev/null +++ b/tests/Regression/testsuite-upstream-raw/check_BPF.sh @@ -0,0 +1,158 @@ +#!/bin/bash + +# Show the testcase list on demand. +if [[ "$1" == "TCLIST" ]]; then + if [[ "$(arch)" == "s390x" ]]; then + # Save the s390x machine time (regardless the rhel major): + # Almost all the testcases are failing there, and those, that + # do not, are flaky. + echo -n "notest.exp" + else + echo -n "bpf-asm.exp bpf.exp" + fi + exit 0 +fi + +_LOG=systemtap.check +cp systemtap.sum $_LOG + +_cleanup() +{ + rm $_LOG +} +trap _cleanup EXIT + +set -xe + +EXPECTED_PASSES_TRESHOLD=-1 + +if test $(rpm --eval '0%{rhel}') -eq 8; then + # systemtap-4.0-7.el8, kernel-4.18.0-64.el8 + case `arch` in + x86_64) + EXPECTED_PASSES_TRESHOLD=55 + sed -i '/FAIL: bigmap1.stp/d' $_LOG || : + sed -i '/FAIL: cast_op_tracepoint.stp/d' $_LOG || : + sed -i '/FAIL: logging1.stp/d' $_LOG || : + sed -i '/FAIL: perf1.stp/d' $_LOG || : + sed -i '/FAIL: pr23875_loop.stp/d' $_LOG || : + sed -i '/FAIL: pr23875_smash.stp/d' $_LOG || : + sed -i '/FAIL: reg_alloc3.stp/d' $_LOG || : + sed -i '/FAIL: string3.stp/d' $_LOG || : + sed -i '/FAIL: timer1.stp/d' $_LOG || : + sed -i '/FAIL: timer2.stp/d' $_LOG || : + sed -i '/FAIL: tracepoint1.stp/d' $_LOG || : + sed -i '/FAIL: tracepoint1.stp/d' $_LOG || : + ;; + aarch64) + EXPECTED_PASSES_TRESHOLD=58 + sed -i '/FAIL: bigmap1.stp/d' $_LOG || : + sed -i '/FAIL: logging1.stp/d' $_LOG || : + sed -i '/FAIL: perf1.stp/d' $_LOG || : + sed -i '/FAIL: perf2.stp/d' $_LOG || : + sed -i '/FAIL: pr23875_loop.stp/d' $_LOG || : + sed -i '/FAIL: pr23875_smash.stp/d' $_LOG || : + sed -i '/FAIL: reg_alloc3.stp/d' $_LOG || : + sed -i '/FAIL: string3.stp/d' $_LOG || : + sed -i '/FAIL: timer2.stp/d' $_LOG || : + sed -i '/FAIL: tracepoint1.stp/d' $_LOG || : + ;; + ppc64le) + EXPECTED_PASSES_TRESHOLD=53 + sed -i '/FAIL: array.stp/d' $_LOG || : + sed -i '/FAIL: array_preinit.stp/d' $_LOG || : + sed -i '/FAIL: context_vars1.stp/d' $_LOG || : + sed -i '/FAIL: context_vars2.stp/d' $_LOG || : + sed -i '/FAIL: context_vars2.stp/d' $_LOG || : + sed -i '/FAIL: context_vars3.stp/d' $_LOG || : + sed -i '/FAIL: globals2.stp/d' $_LOG || : + sed -i '/FAIL: globals3.stp/d' $_LOG || : + sed -i '/FAIL: kprobes.stp/d' $_LOG || : + sed -i '/FAIL: logging1.stp/d' $_LOG || : + sed -i '/FAIL: perf1.stp/d' $_LOG || : + sed -i '/FAIL: perf2.stp/d' $_LOG || : + sed -i '/FAIL: pr23875_loop.stp/d' $_LOG || : + sed -i '/FAIL: pr23875_loop.stp/d' $_LOG || : + sed -i '/FAIL: pr23875_smash.stp/d' $_LOG || : + sed -i '/FAIL: reg_alloc3.stp/d' $_LOG || : + sed -i '/FAIL: string3.stp/d' $_LOG || : + sed -i '/FAIL: timer2.stp/d' $_LOG || : + sed -i '/FAIL: tracepoint1.stp/d' $_LOG || : + ;; + s390x) + # Many testcases fail for s390x, many of them are flaky + # Not worth testing at all at this stage at all probably. + echo "INFO: UNSUPPORTED RHEL7 ARCHITECTIRE ($(arch))" + exit 0 + ;; + *) + echo "ERROR: UNSUPPORTED RHEL8 ARCHITECTIRE" + exit 1 + ;; + esac +elif test $(rpm --eval '0%{rhel}') -eq 7; then + case `arch` in + x86_64) + # (rhel7) systemtap-3.3-3.el7.x86_64, kernel-3.10.0-993.el7.x86_64 + if test $(rpm -q --queryformat='%{version}\n' kernel | awk -F. '{print $1}') -eq 3; then + EXPECTED_PASSES_TRESHOLD=32 + sed -i '/FAIL: cast_op_tracepoint.stp/d' $_LOG || : + sed -i '/FAIL: perf2.stp/d' $_LOG || : + sed -i '/FAIL: reg_alloc3.stp/d' $_LOG || : + sed -i '/FAIL: tracepoint1.stp/d' $_LOG || : + elif test $(rpm -q --queryformat='%{version}\n' kernel | awk -F. '{print $1}') -eq 4; then + # (rhel-alt-7) systemtap-3.3-3.el7.x86_64, kernel-4.14.0-115.el7a.x86_64 + echo "ERROR: known bug on rhel-alt ('map entry 0: Function not implemented')" + echo "<@fche> # CONFIG_BPF_SYSCALL is not set" + exit 0 + else + echo "ERROR: UNSUPPORTED RHEL7 KERNEL VERSION" + exit 1 + fi + ;; + *) + echo "INFO: UNSUPPORTED RHEL7 ARCHITECTIRE ($(arch))" + exit 0 + ;; + esac +elif test $(rpm --eval '0%{fedora}') -eq 29; then + case `arch` in + x86_64) + EXPECTED_PASSES_TRESHOLD=33 + sed -i '/FAIL: array.stp/d' $_LOG || : + sed -i '/FAIL: bigmap1.stp/d' $_LOG || : + sed -i '/FAIL: cast_op_tracepoint.stp/d' $_LOG || : + sed -i '/FAIL: no_end.stp/d' $_LOG || : + sed -i '/FAIL: printf.stp/d' $_LOG || : + sed -i '/FAIL: reg_alloc3.stp/d' $_LOG || : + sed -i '/FAIL: string1.stp/d' $_LOG || : + sed -i '/FAIL: timer2.stp/d' $_LOG || : + sed -i '/FAIL: tracepoint1.stp/d' $_LOG || : + ;; + *) + # No test results for other arches yet + true; + ;; + esac +else + echo "ERROR: UNSUPPORTED RHELMAJOR" + exit 1 +fi + +true _v_v_v_v_v_v_v_v_v_v_v_ UNEXPECTED FAILURES: _v_v_v_v_v_v_v_v_v_v_v_v_v_v_ +fgrep 'FAIL: ' $_LOG || : +true -^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^- + + +EXPECTED_PASSES=$(grep -a '^PASS: ' $_LOG | wc -l) +UNEXPECTED_FAILURES=$(grep -a '^FAIL: ' $_LOG | wc -l) + +test ${EXPECTED_PASSES_TRESHOLD} -gt 1 +test 0${EXPECTED_PASSES} -ge 0${EXPECTED_PASSES_TRESHOLD} +test 0${UNEXPECTED_FAILURES} -eq 0 + +rm $_LOG + +set +xe + + diff --git a/tests/Regression/testsuite-upstream-raw/check_DEFAULT.sh b/tests/Regression/testsuite-upstream-raw/check_DEFAULT.sh new file mode 100755 index 0000000..ed0eea8 --- /dev/null +++ b/tests/Regression/testsuite-upstream-raw/check_DEFAULT.sh @@ -0,0 +1,55 @@ +#!/bin/bash + +if [[ "$1" == "TCLIST" ]]; then + # Empty list means to run all the testcases: + exit 0 +fi + +set -xe + +# It turns out that dg-extract-results.sh relies on the logfiles +# summary (# of expected passes, # of unexpected failures, etc.) and +# counts the summary values based on that. This is is okay for the +# normal dg-extract-results.sh use-case where it combines together +# correct (per single testcase) logs coming from parallel GDB testcase +# runs, where each of the input logfiles has such summary. +# +# But in our case we are combining incomplete log snippets coming from +# various terminated/incomplete/partial testsuite runs (kernel +# stall/crash, watchdog termination etc), where the log snippets do not +# have that summary (with an exception of the very last one). The +# result is that only the last of the log snippets gets properly +# counted, and the results from the other log snippets are ignored. +# +# rlRun "EXPECTED_PASSES=$(awk '/^# of expected passes/ {print $NF}' systemtap.sum)" +# rlRun "UNEXPECTED_FAILURES=$(awk '/^# of unexpected failures/ {print $NF}' systemtap.sum)" +# +# So we really need to count the PASSes and FAILs on our own: +# + +EXPECTED_PASSES=$(grep -a '^PASS: ' systemtap.sum | wc -l) +UNEXPECTED_FAILURES=$(grep -a '^FAIL: ' systemtap.sum | wc -l) + +# +# For this rough check, ignoring other states such as KFAIL and others +# should be good enough. + +case `arch` in + x86_64) + EXPECTED_PASSES_TRESHOLD=9000 + UNEXPECTED_FAILURES_TRESHOLD=800 + ;; + ppc64*) + EXPECTED_PASSES_TRESHOLD=8000 + UNEXPECTED_FAILURES_TRESHOLD=750 + ;; + *) + EXPECTED_PASSES_TRESHOLD=8000 + UNEXPECTED_FAILURES_TRESHOLD=500 + ;; +esac + +test 0${EXPECTED_PASSES} -ge 0${EXPECTED_PASSES_TRESHOLD} +test 0${UNEXPECTED_FAILURES} -le 0${UNEXPECTED_FAILURES_TRESHOLD} + +set +xe diff --git a/tests/Regression/testsuite-upstream-raw/dg-extract-results.sh b/tests/Regression/testsuite-upstream-raw/dg-extract-results.sh new file mode 100755 index 0000000..ffea0a3 --- /dev/null +++ b/tests/Regression/testsuite-upstream-raw/dg-extract-results.sh @@ -0,0 +1,453 @@ +#! /bin/sh + +# For a specified tool and optional list of test variants, extract +# test results from one or more test summary (.sum) files and combine +# the results into a new test summary file, sent to the standard output. +# The resulting file can be used with test result comparison scripts for +# results from tests that were run in parallel. See usage() below. + +# Copyright (C) 2008-2016 Free Software Foundation, Inc. +# Contributed by Janis Johnson +# +# This file is part of GCC. +# +# GCC is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3, or (at your option) +# any later version. +# +# GCC is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + +PROGNAME=dg-extract-results.sh + +# Try to use the python version if possible, since it tends to be faster. +PYTHON_VER=`echo "$0" | sed 's/sh$/py/'` +if test "$PYTHON_VER" != "$0" && + test -f "$PYTHON_VER" && + python -c 'import sys; sys.exit (0 if sys.version_info >= (2, 6) else 1)' \ + > /dev/null 2> /dev/null; then + exec python $PYTHON_VER "$@" +fi + +usage() { + cat <&2 +Usage: $PROGNAME [-t tool] [-l variant-list] [-L] sum-file ... + + tool The tool (e.g. g++, libffi) for which to create a + new test summary file. If not specified then all + specified sum files must be for the same tool. + variant-list One or more test variant names. If the list is + not specified then one is constructed from all + variants in the files for . + sum-file A test summary file with the format of those + created by runtest from DejaGnu. + If -L is used, merge *.log files instead of *.sum. In this + mode the exact order of lines may not be preserved, just different + Running *.exp chunks should be in correct order. +EOF +} + +# Write a message to the standard error. + +msg() { + echo "$@" >&2 +} + +# Parse the command-line options. + +VARIANTS="" +TOOL="" +MODE="sum" + +while getopts "l:t:L" ARG; do + case $ARG in + l) VARIANTS="${VARIANTS} ${OPTARG}";; + t) test -z "$TOOL" || (msg "${PROGNAME}: only one tool can be specified"; exit 1); + TOOL="${OPTARG}";; + L) MODE="log";; + \?) usage; exit 0;; + esac +done +shift `expr ${OPTIND} - 1` + +if test $# -lt 1 ; then + usage + exit 1 +fi + +TMPDIR=${TMPDIR-/tmp} +SUM_FILES="$@" +FIRST_SUM=$1 +TMP= +trap 'EXIT_STATUS=$?; rm -rf $TMP && exit $EXIT_STATUS' 0 +# Create a (secure) tmp directory for tmp files. +{ + TMP=`(umask 077 && mktemp -d -q "${TMPDIR}/dg-combine-results-$$-XXXXXX") 2>/dev/null` && + test -n "$TMP" && test -d "$TMP" +} || +{ + TMP=${TMPDIR}/dg-combine-results-$$-$RANDOM + (umask 077 && mkdir $TMP) +} || +{ + msg "${PROGNAME}: cannot create a temporary directory" + { (exit 1); exit 1; } +} + +# Find a good awk. + +if test -z "$AWK" ; then + for AWK in gawk nawk awk + do + if type $AWK 2>&1 | grep 'not found' > /dev/null 2>&1 ; then + : + else + break + fi + done +fi + +# Verify that the specified summary files exist. + +ERROR=0 +for FILE in $SUM_FILES +do + if ! test -f $FILE ; then + msg "${PROGNAME}: file $FILE does not exist." + ERROR=1 + fi +done +test $ERROR -eq 0 || exit 1 + +# Test if grep supports the '--text' option + +GREP=grep + +if echo -e '\x00foo\x00' | $GREP --text foo > /dev/null 2>&1 ; then + GREP="grep --text" +else + # Our grep does not recognize the '--text' option. We have to + # treat our files in order to remove any non-printable character. + for file in $SUM_FILES ; do + mv $file ${file}.orig + cat -v ${file}.orig > $file + done +fi + +if [ -z "$TOOL" ]; then + # If no tool was specified, all specified summary files must be for + # the same tool. + + CNT=`$GREP '=== .* tests ===' $SUM_FILES | $AWK '{ print $3 }' | sort -u | wc -l` + if [ $CNT -eq 1 ]; then + TOOL=`$GREP '=== .* tests ===' $FIRST_SUM | $AWK '{ print $2 }'` + else + msg "${PROGNAME}: sum files are for multiple tools, specify a tool" + msg "" + usage + exit 1 + fi +else + # Ignore the specified summary files that are not for this tool. This + # should keep the relevant files in the same order. + + SUM_FILES=`$GREP -l "=== $TOOL" $SUM_FILES` + if test -z "$SUM_FILES" ; then + msg "${PROGNAME}: none of the specified files are results for $TOOL" + exit 1 + fi +fi + +if [ "$TOOL" = acats ]; then + # Acats *.sum or *.log files aren't dejagnu generated, and they have + # somewhat different format. + ACATS_AWK=${TMP}/acats.awk + cat < $ACATS_AWK +BEGIN { + print_prologue=1; curfile=""; insummary=0 + passcnt=0; failcnt=0; unsupcnt=0; failures="" +} +/^[ \t]*=== acats configuration ===/ { + insummary=0 + if (print_prologue) print + next +} +/^[ \t]*=== acats tests ===/ { + if (print_prologue) print + print_prologue=0 + next +} +/^Running chapter / { + if (curfile) close (curfile) + curfile="${TMP}/chapter-"\$3 + print >> curfile + next +} +/^[ \t]*=== acats Summary ===/ { + if (curfile) close (curfile) + curfile="" + insummary=1 + next +} +/^# of expected passes/ { if (insummary == 1) passcnt += \$5; next; } +/^# of unexpected failures/ { if (insummary == 1) failcnt += \$5; next; } +/^# of unsupported tests/ { if (insummary == 1) unsupcnt += \$5; next; } +/^\*\*\* FAILURES: / { + if (insummary == 1) { + if (failures) sub(/^\*\*\* FAILURES:/,"") + failures=failures""\$0 + } +} +{ + if (print_prologue) { print; next } + if (curfile) print >> curfile +} +END { + system ("cat ${TMP}/chapter-*") + print " === acats Summary ===" + print "# of expected passes " passcnt + print "# of unexpected failures " failcnt + if (unsupcnt) print "# of unsupported tests " unsupcnt + if (failures) print failures +} +EOF + + rm -f ${TMP}/chapter-* + $AWK -f $ACATS_AWK $SUM_FILES + exit 0 +fi + +# If no variants were specified, find all variants in the remaining +# summary files. Otherwise, ignore specified variants that aren't in +# any of those summary files. + +if test -z "$VARIANTS" ; then + VAR_AWK=${TMP}/variants.awk + cat < $VAR_AWK +/^Schedule of variations:/ { in_vars=1; next } +/^$/ { in_vars=0 } +/^Running target/ { exit } +{ if (in_vars==1) print \$1; else next } +EOF + + touch ${TMP}/varlist + for FILE in $SUM_FILES; do + $AWK -f $VAR_AWK $FILE >> ${TMP}/varlist + done + VARIANTS="`sort -u ${TMP}/varlist`" +else + VARS="$VARIANTS" + VARIANTS="" + for VAR in $VARS + do + $GREP "Running target $VAR" $SUM_FILES > /dev/null && VARIANTS="$VARIANTS $VAR" + done +fi + +# Find out if we have more than one variant, or any at all. + +VARIANT_COUNT=0 +for VAR in $VARIANTS +do + VARIANT_COUNT=`expr $VARIANT_COUNT + 1` +done + +if test $VARIANT_COUNT -eq 0 ; then + msg "${PROGNAME}: no file for $TOOL has results for the specified variants" + exit 1 +fi + +cat $SUM_FILES \ + | $AWK '/^Running/ { if ($2 != "target" && $3 == "...") print "EXPFILE: "$2 } ' \ + | sort -u > ${TMP}/expfiles + +# Write the begining of the combined summary file. + +head -n 2 $FIRST_SUM +echo +echo " === $TOOL tests ===" +echo +echo "Schedule of variations:" +for VAR in $VARIANTS +do + echo " $VAR" +done +echo + +# For each test variant for the tool, copy test reports from each of the +# summary files. Set up two awk scripts from within the loop to +# initialize VAR and TOOL with the script, rather than assuming that the +# available version of awk can pass variables from the command line. + +for VAR in $VARIANTS +do + GUTS_AWK=${TMP}/guts.awk + cat << EOF > $GUTS_AWK +BEGIN { + variant="$VAR" + firstvar=1 + expfileno=1 + cnt=0 + print_using=0 + need_close=0 +} +/^EXPFILE: / { + expfiles[expfileno] = \$2 + expfilesr[\$2] = expfileno + expfileno = expfileno + 1 +} +/^Running target / { + curvar = \$3 + if (variant == curvar && firstvar == 1) { print; print_using=1; firstvar = 0 } + next +} +/^Using / { + if (variant == curvar && print_using) { print; next } +} +/^Running .*\\.exp \\.\\.\\./ { + print_using=0 + if (variant == curvar) { + if (need_close) close(curfile) + curfile="${TMP}/list"expfilesr[\$2] + expfileseen[\$2]=expfileseen[\$2] + 1 + need_close=0 + testname="00" + next + } +} +/^\t\t=== .* ===$/ { curvar = ""; next } +/^(PASS|XPASS|FAIL|XFAIL|UNRESOLVED|WARNING|ERROR|UNSUPPORTED|UNTESTED|KFAIL):/ { + testname=\$2 + # Ugly hack for gfortran.dg/dg.exp + if ("$TOOL" == "gfortran" && testname ~ /^gfortran.dg\/g77\//) + testname="h"testname +} +/^$/ { if ("$MODE" == "sum") next } +{ if (variant == curvar && curfile) { + if ("$MODE" == "sum") { + printf "%s %08d|", testname, cnt >> curfile + cnt = cnt + 1 + } + filewritten[curfile]=1 + need_close=1 + print >> curfile + } else + next +} +END { + n=1 + while (n < expfileno) { + if (expfileseen[expfiles[n]]) { + print "Running "expfiles[n]" ..." + if (filewritten["${TMP}/list"n]) { + if (expfileseen[expfiles[n]] == 1) + cmd="cat" + else + cmd="LC_ALL=C sort" + if ("$MODE" == "sum") + system (cmd" ${TMP}/list"n" | sed -n 's/^[^ ]* [^ |]*|//p'") + else + system ("cat ${TMP}/list"n) + } + } + n = n + 1 + } +} +EOF + + SUMS_AWK=${TMP}/sums.awk + rm -f $SUMS_AWK + cat << EOF > $SUMS_AWK +BEGIN { + variant="$VAR" + tool="$TOOL" + passcnt=0; failcnt=0; untstcnt=0; xpasscnt=0; xfailcnt=0; kpasscnt=0; kfailcnt=0; unsupcnt=0; unrescnt=0; + curvar=""; insummary=0 +} +/^Running target / { curvar = \$3; next } +/^# of / { if (variant == curvar) insummary = 1 } +/^# of expected passes/ { if (insummary == 1) passcnt += \$5; next; } +/^# of unexpected successes/ { if (insummary == 1) xpasscnt += \$5; next; } +/^# of unexpected failures/ { if (insummary == 1) failcnt += \$5; next; } +/^# of expected failures/ { if (insummary == 1) xfailcnt += \$5; next; } +/^# of unknown successes/ { if (insummary == 1) kpasscnt += \$5; next; } +/^# of known failures/ { if (insummary == 1) kfailcnt += \$5; next; } +/^# of untested testcases/ { if (insummary == 1) untstcnt += \$5; next; } +/^# of unresolved testcases/ { if (insummary == 1) unrescnt += \$5; next; } +/^# of unsupported tests/ { if (insummary == 1) unsupcnt += \$5; next; } +/^$/ { if (insummary == 1) + { insummary = 0; curvar = "" } + next + } +{ next } +END { + printf ("\t\t=== %s Summary for %s ===\n\n", tool, variant) + if (passcnt != 0) printf ("# of expected passes\t\t%d\n", passcnt) + if (failcnt != 0) printf ("# of unexpected failures\t%d\n", failcnt) + if (xpasscnt != 0) printf ("# of unexpected successes\t%d\n", xpasscnt) + if (xfailcnt != 0) printf ("# of expected failures\t\t%d\n", xfailcnt) + if (kpasscnt != 0) printf ("# of unknown successes\t\t%d\n", kpasscnt) + if (kfailcnt != 0) printf ("# of known failures\t\t%d\n", kfailcnt) + if (untstcnt != 0) printf ("# of untested testcases\t\t%d\n", untstcnt) + if (unrescnt != 0) printf ("# of unresolved testcases\t%d\n", unrescnt) + if (unsupcnt != 0) printf ("# of unsupported tests\t\t%d\n", unsupcnt) +} +EOF + + PVAR=`echo $VAR | sed 's,/,.,g'` + TMPFILE=${TMP}/var-$PVAR + rm -f $TMPFILE + rm -f ${TMP}/list* + cat ${TMP}/expfiles $SUM_FILES | $AWK -f $GUTS_AWK + cat $SUM_FILES | $AWK -f $SUMS_AWK > $TMPFILE + # If there are multiple variants, output the counts for this one; + # otherwise there will just be the final counts at the end. + test $VARIANT_COUNT -eq 1 || cat $TMPFILE +done + +# Set up an awk script to get the combined summary counts for the tool. + +TOTAL_AWK=${TMP}/total.awk +cat << EOF > $TOTAL_AWK +BEGIN { + tool="$TOOL" + passcnt=0; failcnt=0; untstcnt=0; xpasscnt=0; xfailcnt=0; kfailcnt=0; unsupcnt=0; unrescnt=0 +} +/^# of expected passes/ { passcnt += \$5 } +/^# of unexpected failures/ { failcnt += \$5 } +/^# of unexpected successes/ { xpasscnt += \$5 } +/^# of expected failures/ { xfailcnt += \$5 } +/^# of unknown successes/ { kpasscnt += \$5 } +/^# of known failures/ { kfailcnt += \$5 } +/^# of untested testcases/ { untstcnt += \$5 } +/^# of unresolved testcases/ { unrescnt += \$5 } +/^# of unsupported tests/ { unsupcnt += \$5 } +END { + printf ("\n\t\t=== %s Summary ===\n\n", tool) + if (passcnt != 0) printf ("# of expected passes\t\t%d\n", passcnt) + if (failcnt != 0) printf ("# of unexpected failures\t%d\n", failcnt) + if (xpasscnt != 0) printf ("# of unexpected successes\t%d\n", xpasscnt) + if (xfailcnt != 0) printf ("# of expected failures\t\t%d\n", xfailcnt) + if (kpasscnt != 0) printf ("# of unknown successes\t\t%d\n", kpasscnt) + if (kfailcnt != 0) printf ("# of known failures\t\t%d\n", kfailcnt) + if (untstcnt != 0) printf ("# of untested testcases\t\t%d\n", untstcnt) + if (unrescnt != 0) printf ("# of unresolved testcases\t%d\n", unrescnt) + if (unsupcnt != 0) printf ("# of unsupported tests\t\t%d\n", unsupcnt) +} +EOF + +# Find the total summaries for the tool and add to the end of the output. +cat ${TMP}/var-* | $AWK -f $TOTAL_AWK + +# This is ugly, but if there's version output from the compiler under test +# at the end of the file, we want it. The other thing that might be there +# is the final summary counts. +tail -2 $FIRST_SUM | $GREP '^#' > /dev/null || tail -2 $FIRST_SUM + +exit 0 diff --git a/tests/Regression/testsuite-upstream-raw/helpers/createreport.sh b/tests/Regression/testsuite-upstream-raw/helpers/createreport.sh new file mode 100755 index 0000000..49180ac --- /dev/null +++ b/tests/Regression/testsuite-upstream-raw/helpers/createreport.sh @@ -0,0 +1,49 @@ +#!/bin/bash + +TEMPDIR=$( mktemp -d ) +ORIGPWD=$( pwd ) + +cp /mnt/scratch/mcermak/testlogs/systemtap.upstream/*tar.xz $TEMPDIR/ + + +pushd $TEMPDIR || exit 1 + +# rename files so that identical commit hashes get identical (lowest possible) timestamp for sorting purposes +HASHES=$(ls systemtap*mcermak*tar.xz | awk -F\. '{print $4}' | sort -u) +for h in $HASHES; do + echo Processing hash $h + MINSTAMP4HASH=$( ls *$h* | tr '-' '.' | awk -F\. '{print $9}' | sort -n | grep '[0-9]\+' | head -n 1 ) + echo Min stamp for hash is: $MINSTAMP4HASH + PKG4HASH=$( ls *$h* ) + for p in $PKG4HASH; do + echo Processing pkg $p + PKGSTAMP=$( echo $p | tr '-' '.' | awk -F\. '{print $9}' ) + rename 'systemtap' "$MINSTAMP4HASH" $p + done +done + +# extract systemtap.sum files and rename them +for f in $( ls *tar.xz ); do + tar xJf $f systemtap.sum + mv systemtap.sum $f.sum + rename 'tar.xz.sum' 'log' $f.sum +done + +sh $ORIGPWD/report-helper.sh | tee wiki.out + +sed -i 's/UNKNOWN/?/g' wiki.out +sed -i 's/UNTESTED/-/g' wiki.out +sed -i 's/PASS/P/g' wiki.out +sed -i 's/FAIL/F/g' wiki.out +sed -i 's/ERROR/E/g' wiki.out + + +echo uploading logs to scratch... +OUT=/mnt/scratch/mcermak/testlogs/out +rm -rf $OUT && mkdir -p $OUT && chmod a+rwx $OUT && cp -v *tar.xz $OUT/ + +echo uploading to wiki... +cat wiki.out | $ORIGPWD/wikiup 'mcermak/systemtap.upstream' + +popd # $TEMPDIR +rm -rf $TEMPDIR diff --git a/tests/Regression/testsuite-upstream-raw/helpers/report-helper.sh b/tests/Regression/testsuite-upstream-raw/helpers/report-helper.sh new file mode 100755 index 0000000..1297045 --- /dev/null +++ b/tests/Regression/testsuite-upstream-raw/helpers/report-helper.sh @@ -0,0 +1,130 @@ +#!/bin/bash + +HASHES=$( ls | awk -F\. '{print $4}' | sort -u ) +ARCHES=$( ls *log | awk -F- '{print $(NF-1) }' | awk -F. '{print $NF}' | sort -u ) + +declare -A MAXTESTS + +for p in $HASHES; do + MAXTESTS[$p]=0 + for a in $ARCHES; do + c=$( ls *log | grep $p | grep $a | wc -l ) + test $c -gt ${MAXTESTS[$p]} && MAXTESTS[$p]=$c + done +done + +TESTCASES=$( cat *log | awk '/^Running\ \.\/systemtap/ {print $2}' | sort -u ) + +TEMPFILE=$( mktemp ) + +function getCaseResults() { + casename=$1 + logfile=$2 + casename=$( echo $casename | tr "/" "." ) + cmd="cat $logfile | sed -e '/$casename/,/^Running/ !d'" + eval "$cmd" | head -n -1 +} + +function getWorstResult() { + results="$1" + retval='UNKNOWN' + echo "$results" | grep -q '^PASS' && retval='PASS' + echo "$results" | grep -q '^KPASS' && retval='KPASS' + echo "$results" | grep -q '^XPASS' && retval='XPASS' + echo "$results" | grep -q '^UNTESTED' && retval='UNTESTED' + echo "$results" | grep -q '^KFAIL' && retval='KFAIL' + echo "$results" | grep -q '^XFAIL' && retval='XFAIL' + echo "$results" | grep -q '^FAIL' && retval='FAIL' + echo "$results" | grep -q '^ERROR' && retval='ERROR' + echo $retval +} + +function getResult() { + casename=$1 + logfile=$2 + worstResult=$( getWorstResult "$( getCaseResults "$casename" "$logfile" )" ) + if test -s $logfile; then + loglink="http://nfs.englab.brq.redhat.com/scratch/mcermak/testlogs/out/$( echo $logfile | sed 's/log/tar\.xz/' )" + echo "[[$loglink|$worstResult]]" + else + echo $worstResult + fi +} + +function getLogs() { + package=$1 + arch=$2 + logcnt=$3 + availogcont=$( ls *log | grep $package | grep $arch | wc -l ) + remainlogcnt=$(( $logcnt - $availogcont )) + logs=$( ls *log | grep $package | grep $arch ) + for i in $( seq 1 $remainlogcnt ); do + logs="$logs $TEMPFILE" + done + echo $logs +} + +function colorizeResult() { + result=$1 + if echo $result | egrep -q '(KFAIL|XFAIL)'; then + echo "<#a2eea2> $result" + elif echo $result | egrep -q '(FAIL|ERROR)'; then + echo "<#f30000> $result" + elif echo $result | egrep -q '(UNKNOWN)'; then + echo "<#ffffff> $result" + else + echo "<#a2eea2> $result" + fi +} + +function getResultSet() { + package=$1 + arch=$2 + testcase=$3 + #echo -n "|| $package ($arch) " + echo -n "|| '''$arch''' " + for logfile in $( getLogs "$package" "$arch" ${MAXTESTS[$package]} ); do + result=$( getResult "$testcase" "$logfile" ) + echo -n "||$( colorizeResult "$result" ) " + done +} + +function getBugsForTestcase() { + testcase=$1 + testcase=$( echo $testcase | sed 's/^\.\///' | tr "/" "." ) + cmd="awk '/$testcase/ {print \$2}' bugs.txt" + eval "$cmd" +} + +function getBugLinksForTestcase() { + bznos="$1" + if ! test -z "$bznos"; then + echo + for bzno in $bznos; do + echo -e "[[https://bugzilla.redhat.com/show_bug.cgi?id=$bzno|bz$bzno]]" + done + echo + fi +} + +echo -n "== " +first=1 +for package in $HASHES; do + test $first -eq 0 && echo -n "<-> " + echo -n "$package " + first=0 +done +echo " ==" + +for testcase in $TESTCASES; do + echo -e "\n=== $testcase ===\n" + getBugLinksForTestcase "$( getBugsForTestcase "$testcase" )" + for arch in $ARCHES; do + for __hash in $HASHES; do + getResultSet $__hash $arch $testcase + done + echo " ||" + done +done + + diff --git a/tests/Regression/testsuite-upstream-raw/helpers/wikiup b/tests/Regression/testsuite-upstream-raw/helpers/wikiup new file mode 100755 index 0000000..f703910 --- /dev/null +++ b/tests/Regression/testsuite-upstream-raw/helpers/wikiup @@ -0,0 +1,22 @@ +#!/usr/bin/python + +import sys +import xmlrpclib + +wikilocation = sys.argv[1] +wikicontent = sys.stdin.read() + +if not wikilocation.startswith("mcermak/"): + print "wiki location must start with mcermak/" + sys.exit(1) + +user = 'xmlrpc2' +password = 'fo0m4nchU+' +url='http://wiki.test.redhat.com/' +wiki = xmlrpclib.ServerProxy(url + '?action=xmlrpc2', allow_none=False) +auth_token = wiki.getAuthToken(user, password) +mc = xmlrpclib.MultiCall(wiki) +mc.applyAuthToken(auth_token) +mc.putPage(wikilocation, wikicontent) +result = mc() + diff --git a/tests/Regression/testsuite-upstream-raw/internal-watchdog.sh b/tests/Regression/testsuite-upstream-raw/internal-watchdog.sh new file mode 100755 index 0000000..f977337 --- /dev/null +++ b/tests/Regression/testsuite-upstream-raw/internal-watchdog.sh @@ -0,0 +1,21 @@ +#/bin/bash + +test -x +__TRESHOLD=$(( 240 * 60 )) +__SLEEP=$(( 15 * 60 )) +__LOG="$1" +test -z $__LOG && exit 1 +test +x + +echo "`date` internal watchdog $$ starting." >> $__LOG +while true; do + sleep $__SLEEP + __DELTA=$(( `date +'%s'` - `stat -c '%Y' $__LOG` )) + if [[ $__DELTA -gt $__TRESHOLD ]]; then + echo "`date` internal watchdog $$ rebooting due to inactivity." >> $__LOG + sync + sleep 1m + reboot -f + sleep 5m + fi +done diff --git a/tests/Regression/testsuite-upstream-raw/main.fmf b/tests/Regression/testsuite-upstream-raw/main.fmf new file mode 100644 index 0000000..883d060 --- /dev/null +++ b/tests/Regression/testsuite-upstream-raw/main.fmf @@ -0,0 +1,50 @@ +summary: testsuite-upstream-raw +description: '' +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +# test: /bin/true +framework: beakerlib +recommend: + - avahi-debuginfo + - avahi-devel + - boost-devel + - byteman + - coreutils + - coreutils-debuginfo + - crash-devel + - dejagnu + - '@development' + - '@development-tools' + - dyninst-devel + - elfutils-devel + - gcc-c++ + - gettext-devel + - git + - glibc-debuginfo + - glibc-devel + - libselinux-devel + - libstdc++-devel + - m4 + - nss-devel + - pkgconfig + - postgresql-debuginfo + - postgresql-server + - python + - python3-debuginfo + - python-debuginfo + - python-libs-debuginfo + - rpm-devel + - sqlite-devel + - systemtap + - systemtap-testsuite + - tcl + - xz + - zlib-devel + - sqlite + - systemtap-debuginfo + - kernel-headers +duration: 72h +extra-summary: /tools/systemtap/Regression/testsuite-upstream-raw +extra-task: /tools/systemtap/Regression/testsuite-upstream-raw diff --git a/tests/Regression/testsuite-upstream-raw/runtest.sh b/tests/Regression/testsuite-upstream-raw/runtest.sh new file mode 100755 index 0000000..6b9a1b0 --- /dev/null +++ b/tests/Regression/testsuite-upstream-raw/runtest.sh @@ -0,0 +1,282 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/testsuite-upstream-raw +# Description: testsuite-upstream-raw +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2014 Red Hat, Inc. +# +# This program is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation, either version 2 of +# the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see http://www.gnu.org/licenses/. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +# What part of the testsuite should we run (and then check for errors)? +_WHAT=${_WHAT:-DEFAULT} + +export AVC_ERROR='+no_avc_check' +touch /tmp/disable-qe-abrt + +unset DEBUGINFOD_PROGRESS +if test $(rpm --eval "0%{rhel}") -ge 9; then + # Allow use of debuginfod + export DEBUGINFOD_URLS=http://debuginfod.usersys.redhat.com:3632/ + # export DEBUGINFOD_PROGRESS=1 +else + unset DEBUGINFOD_URLS +fi + +trap '' SIGHUP SIGINT SIGQUIT SIGABRT + +ORIGPWD=$( pwd ) + +PKGMGR="yum --skip-broken --nogpgcheck" +rpm -q dnf && PKGMGR="dnf --setopt=strict=0 --nogpgcheck" + +STARTDATE=$(date +%Y-%m-%d-%H-%M-%S) +STAPSRPM=$(rpm -qif `which stap` | awk '/Source RPM/ {print $NF}' | sort -u | sed 's/\.src\.rpm//') +SUITERPM=$(rpm --queryformat '%{name}\n' -qf `which stap` | grep -o '.*systemtap' | sort -u)-testsuite +SUITELOC=$(rpm -ql $SUITERPM | grep -o '.*systemtap\/testsuite/' | sort -u) + +test_primary_arch_only () +{ + echo "=== TESTING PRIMARY ARCH ONLY ===" + sed -i '/^proc arch_compile_flags/,/^}/d' $SUITELOC/lib/compile_flags.exp + echo 'proc arch_compile_flags {} { return 1 }' >> $SUITELOC/lib/compile_flags.exp +} + +# For devtoolset, compat arch support was dropped for non-x86_64 arches. Ref: bz1493500 +if echo $SUITELOC | grep -q toolset && arch | egrep -q '^(ppc64|s390x)$'; then + test_primary_arch_only +elif test $(rpm -E '0%{rhel}') -ge 8 -a "$(arch)" != "x86_64"; then + test_primary_arch_only +fi + +# Currently the Makefile overrides what was set in the env via +# http://pkgs.devel.redhat.com/cgit/rpms/devtoolset-7/commit/?h=devtoolset-7.1-rhel-7&id=e305f5912a13bd2ca04ac319afca50bfab6f4aea +# And actually if the base rhel dyninst is installed, the dts testsuite runs against it rather than agains +# the dts-stap - producing irrelevant test results. +# +# A real fix on the stap side might be: +# -LD_LIBRARY_PATH=$(DESTDIR)$(libdir)/systemtap +# +LD_LIBRARY_PATH=$(DESTDIR)$(libdir)/systemtap:$(DESTDIR)$(libdir)/dyninst +# in the Makefile.am etc, but let's work this around for now in a way that we simply use the +# LD_LIBRARY_PATH taken directly from the env: +if echo $SUITELOC | grep -q toolset; then + sed -i 's/^LD_LIBRARY_PATH/# LD_LIBRARY_PATH/' $SUITELOC/Makefile +fi + +rlJournalStart + rlPhaseStartSetup + rlLogInfo "SUITERPM=$SUITERPM" + rlLogInfo "SUITELOC=$SUITELOC" + rlRun "pushd $SUITELOC" + rlServiceStop firewalld + rlServiceStop iptables + rlServiceStop ip6tables + rlServiceStart avahi-daemon + rlRun "rpm -qa | grep ^kernel | grep -v `uname -r` | xargs rpm -e --nodeps" 0-255 + # if ! (uname -r | fgrep -q '.rt'); then + # rlRun "$ORIGPWD/stap-prep" 0,127 || \ + # rlRun "stap-prep" 0,127 + # fi + rlRun "sysctl -w kernel.panic=1" + rlRun "sysctl -w kernel.panic_on_oops=1" + rlRun "$PKGMGR -y install --setopt=multilib_policy=all libstdc++ dejagnu elfutils-devel gettext libgcc glibc-devel gcc-c++ libstdc++-devel dyninst dyninst-devel" + rlPhaseEnd + + + MYDMESGDIR=/root/mydmesg + mkdir -p $MYDMESGDIR + if strings $(which dmesg) | fgrep -q -- '-w'; then + rlPhaseStart FAIL "Run dmesg recorder." + MYTIMESTAMP=$(date +%s) + dmesg -wH > $MYDMESGDIR/dmesg$MYTIMESTAMP & + MYDMESGPID=$! + rlLogInfo "Dmesg recorder file: $MYDMESGDIR/dmesg$MYTIMESTAMP" + rlLogInfo "Dmesg PID: $MYDMESGPID" + rlPhaseEnd + fi + + rlPhaseStart FAIL "sanity check" + rlRun "stap -vve 'probe kernel.function(\"vfs_read\"){ log(\"hey!\"); exit() } probe timer.s(60){log(\"timeout\"); exit()}'" + rlRun "stap -vvl 'process(\"/usr/sbin/fdisk\").function(\"main\")'" 0-255 + rlPhaseEnd + + if ! test -f $SUITELOC/systemtap.log; then + rlPhaseStart WARN "Apply blacklist" + # === RHEL7 === + if rlIsRHEL 7; then + if arch | grep -q s390; then + true + # PR17270 + #rlRun "rm -f systemtap.onthefly/hrtimer_onthefly.exp" + #rlRun "rm -f systemtap.onthefly/uprobes_onthefly.exp" + #rlRun "rm -f systemtap.onthefly/kprobes_onthefly.exp" + # PR17140 + #rlRun "rm -f systemtap.examples/profiling/functioncallcount.stp" + elif arch | grep -q ppc; then + true + # PR17270 + #rlRun "rm -f systemtap.onthefly/hrtimer_onthefly.exp" + #rlRun "rm -f systemtap.onthefly/uprobes_onthefly.exp" + #rlRun "rm -f systemtap.onthefly/kprobes_onthefly.exp" + # PR17126 + #rlRun "rm -f systemtap.base/tracepoints.exp" + # BZ1153082 + #rlRun "rm -f systemtap.clone/main_quiesce.exp" + #elif rpm -q systemtap | grep -q '2.4-16.el7_0'; then + # BZ1145958 + #rlRun "rm -f systemtap.base/process_resume.exp" + fi + # === FEDORA === + elif grep -qi fedora /etc/redhat-release; then + # BZ1153082 + rlRun "rm -f systemtap.clone/main_quiesce.exp" + fi + + # Work around problem fixed in https://sourceware.org/git/gitweb.cgi?p=systemtap.git;a=commitdiff;h=a9b0aa4dbd1aa7a1c36eba8102e1445e8f2eb8b8 + rlRun "sed -i 's/exit\ 0/return/' $(fgrep -ril 'exit 0' $(find . -type f -name '*.exp')) ||:" + rlPhaseEnd + else + rlPhaseStart FAIL "Post-process anticipated reboot" + # Sometimes the testsuite crashes the kernel or causes stall. + # In case --ignore-panic is set, the box gets rebooted (bz1155644). + # This shouldn't happen. It'd be nice to report it as FAIL, but that + # appears to be too pedantic. We'll need this bell to ring when + # too many unexpected failures get reported by the upstream test driver. + # rlRun "false" + + # Remove testcases that have already been run + for tc in $( awk '/^Running.*exp\ \.\.\.$/ {print $2}' *systemtap.log ); do + echo $tc | grep -q 'systemtap/notest.exp' && continue + test -f $tc && rm -f $tc && rlLog "Removed $tc" + done + + #generate random hash + HASH=$(date | md5sum | cut -c 1-32 -) + + # save existing logs before creating new ones + rlRun "mv systemtap.log ${HASH}-systemtap.log" + rlRun "mv systemtap.sum ${HASH}-systemtap.sum" + + # clean up garbage incl. systemtap.log + rlRun "make clean" + rlPhaseEnd + fi + + rlPhaseStartTest + # Start internal watchdog if running in beaker + if test -n $JOBID; then + rlLogInfo "Starting internal watchdog ..." + $ORIGPWD/internal-watchdog.sh "$SUITELOC/systemtap.sum" & + __WATCHDOG_PID=$! + sleep 3 + if ps -p $__WATCHDOG_PID; then + rlLogInfo "Internal watchdog running (pid $__WATCHDOG_PID)." + else + rlFail "Problem starting the internal watchdog." + fi + fi + + # The _WHAT env var allows the test to only run selected subset of all + # the tests and perform specific checks on the resulting logs. + # + # Accepted values: BPF + + # run the testsuite (grab the list of testcases from the respective check* file) + TESTCASES=$(bash ${ORIGPWD}/check_${_WHAT}.sh TCLIST) + rlRun "make RUNTESTFLAGS='$TESTCASES' installcheck 2>&1" + + # Kill internal watchdog if running in beaker + if ! test -z $JOBID; then + rlLogInfo "Killing internal watchdog ..." + kill -s TERM $__WATCHDOG_PID + fi + rlPhaseEnd + + rlPhaseStart FAIL "Put all the log fragments together" + rlRun "$ORIGPWD/dg-extract-results.sh *systemtap.sum > big-systemtap.sum" + rlRun "$ORIGPWD/dg-extract-results.sh -L *systemtap.log > big-systemtap.log" + rlRun "mv --force big-systemtap.sum systemtap.sum" + rlRun "mv --force big-systemtap.log systemtap.log" + # remove the hash-prefixed fragments + # these are needed for the resume mode, but since we got to this point, + # we most likely processed all the testcases somehow, put all the pieces + # together and can start cleaning up and reporting + rlRun "rm -f *-systemtap.{log,sum}" + rlPhaseEnd + + rlPhaseStart FAIL "rlFileSubmit logs" + rlRun "xz --keep --force systemtap.log" + rlFileSubmit "systemtap.log.xz" + rlRun "xz --keep --force systemtap.sum" + rlFileSubmit "systemtap.sum.xz" + rlRun "rm systemtap.log.xz systemtap.sum.xz" + rlPhaseEnd + + if [[ "$_WHAT" == "DEFAULT" ]]; then + rlPhaseStart FAIL "save logs to /mnt/scratch" + MP=$( mktemp -d ) + # Refer to /tools/systemtap/Install/upstream-head + SD=rhpkg; rpm -q systemtap | grep -q mcermak && SD=upstream + rlRun "echo ${BEAKER}jobs/${JOBID} > job.txt" + rlRun "tar cf mydmesg.tar $MYDMESGDIR" + rlRun "xz mydmesg.tar" + rlRun "mount -o rw,nolock nfs.englab.brq.redhat.com:/scratch/mcermak $MP" + if test $(rpm --eval '0%{rhel}') -eq 8 && (! echo ${STAPSRPM} | grep '\.el8'); then + rlRun "LOGNAME=${MP}/testlogs/systemtap.${SD}/${STAPSRPM}.el8.$(uname -m)-${STARTDATE}" + else + rlRun "LOGNAME=${MP}/testlogs/systemtap.${SD}/${STAPSRPM}.$(uname -m)-${STARTDATE}" + fi + rlRun "mkdir -p $( dirname $LOGNAME )" + rlRun "tar cJf ${LOGNAME}.tar.xz systemtap.log systemtap.sum job.txt mydmesg.tar.xz" + + # Upload logs to bunsen instance on tofan if running in beaker + if ! test -z $JOBID; then + LOGFULLNAME="${LOGNAME}.tar.xz" + LOGBASENAME="$(basename $LOGFULLNAME)" + rlLogInfo "Uploading test log to bunsen..." + rlRun "cat $LOGFULLNAME | \ + curl -X POST -F project=systemtap-qe \ + -F tarballname=$LOGBASENAME \ + -F 'tar=@-' \ + http://tofan.yyz.redhat.com:8013/bunsen-upload.py" + fi + rlRun "umount -l $MP && sleep 3 && rm -rf $MP" + rlPhaseEnd + fi + + rlPhaseStart FAIL "Log checks ($_WHAT)" + rlRun "bash ${ORIGPWD}/check_${_WHAT}.sh" + rlPhaseEnd + + rlPhaseStartCleanup + rlServiceRestore firewalld + rlServiceRestore iptables + rlServiceRestore ip6tables + rlServiceRestore avahi-daemon + rlRun popd + kill -9 $MYDMESGPID ||: + rlPhaseEnd +rlJournalPrintText +rlJournalEnd + +rm -f /tmp/disable-qe-abrt diff --git a/tests/Regression/testsuite-upstream-raw/stap-prep b/tests/Regression/testsuite-upstream-raw/stap-prep new file mode 100755 index 0000000..89b7c3c --- /dev/null +++ b/tests/Regression/testsuite-upstream-raw/stap-prep @@ -0,0 +1,150 @@ +#! /bin/bash +LANG=C; export LANG +PATH=/usr/sbin:/sbin:/usr/bin:/bin:$PATH; export PATH + +check_error() { if test $1 != 0; then printf "\n$2\n"; exit $1; fi } + +prep_rpm_based() { +# uname -r can produce different kinds of output: +# 2.6.32-30.el6.x86_64 (no variant, but including ".arch") +# 2.6.18-194.3.1.el5debug ("variant", without dot, no arch) +# 2.6.33.4-95.fc13.i686.PAE (".arch.variant", two dots) +# 3.18.6-100.fc20.i686+PAE (".arch+variant", dot, plus) +if [ "$#" -lt 1 ]; then + UNAME=`uname -r` # determine the kernel running on the machine +else + UNAME=$1 #user passed in uname value +fi +UNAME=`echo $UNAME | sed "s/ //"` #strip out any whitespace +KERNEL="kernel" +for VARIANT in debug kdump PAE xen; do + # strip out ".variant" or else "+variant" or else "variant" at end. + TMP=`echo $UNAME | sed "s/[\.\+]\?$VARIANT\$//"` + if [ "$TMP" != "$UNAME" ]; then + UNAME=$TMP; KERNEL="kernel-$VARIANT" + fi +done +KERN_ARCH=`uname -m` +KERN_REV=`echo $UNAME | sed s/.$KERN_ARCH//` # strip arch from uname +if [ -x /usr/bin/dnf ]; then + DI="dnf debuginfo-install" + DI_DEPS="" + D="dnf" +else + DI="debuginfo-install" + DI_DEPS="yum-utils" + D="yum" +fi +CANDIDATES="$KERNEL-$KERN_REV.$KERN_ARCH \ + $KERNEL-devel-$KERN_REV.$KERN_ARCH \ + $DI_DEPS" + +# Can't simply work with /boot/vmlinuz-* below because of +# https://sourceware.org/bugzilla/show_bug.cgi?id=26599 +_debuginfod_file=$(rpm -ql kernel-core | fgrep $(uname -r) | grep '\.so$' | tail -1) +# Now let's assume following to come from outside env... +# export DEBUGINFOD_URLS=http://debuginfod.usersys.redhat.com:3632/ +# export DEBUGINFOD_PROGRESS=1 +debuginfod-find debuginfo $(rpm -ql kernel-core | fgrep $(uname -r) | grep '\.so$' | tail -1) || \ + CANDIDATES="$CANDIDATES $KERNEL-debuginfo-$KERN_REV.$KERN_ARCH" + +NEEDED=`rpm --qf "%{name}-%{version}-%{release}.%{arch}\n" \ + -q $CANDIDATES | grep "is not installed" | awk '{print $2}'` +if [ "$NEEDED" != "" ]; then + echo -e "Need to install the following packages:\n$NEEDED" + if [ `id -u` = "0" ]; then #attempt to install + $D install -y --enablerepo=\* $NEEDED + if expr "$NEEDED" : ".*debuginfo.*" >/dev/null; + then + $DI -y $KERNEL-$KERN_REV.$KERN_ARCH; + fi + rpm -q $NEEDED + rc=$? + check_error $rc "problem installing rpm(s) $NEEDED\nin case of file conflicts, try again after # $D erase $KERNEL-debuginfo" + fi +fi +} + +prep_deb_based() { +if [ $# -ne 0 ]; then + echo "Specifying kernel version is not yet support on deb based systems." 1>&2 + exit 1 +fi + +# 2.6.32-5-amd64 +# 2.6.32-37-generic +ABINAME="$(cut -d " " -f 3 /proc/version)" + +# 2.6.32 +BASEVERSION="$(echo "$ABINAME" | cut -d "-" -f 1)" +DEBIAN_FRONTEND=noninteractive # don't confirm or chat +export DEBIAN_FRONTEND + +case "$DISTRO" in + Debian) # 2.6.32-39 + if uname -v | grep -q Debian; then + VERSION="$(uname -v | cut -d " " -f 4)" + else + VERSION="$(cut -d " " -f 3 /proc/version)" + fi + ;; + Ubuntu) + # 2.6.32-37.81 + if [ -f /proc/version_signature ]; then + VERSION="$(cut -d " " -f 2 /proc/version_signature | cut -d "-" -f 1-2)" + else # 4.18 + VERSION="$(cut -d " " -f 3 /proc/version)" + fi + ;; +esac + +( + echo "make >= 0" + echo "linux-image-$ABINAME = $VERSION" + echo "linux-headers-$ABINAME = $VERSION" + echo "linux-image-$ABINAME-dbgsym = $VERSION" +) | while read package relation requiredversion; do + installedversion="$(dpkg-query -W "$package" 2> /dev/null | cut -f 2)" + if [ "$installedversion" = "" ]; then + availableversion="$(apt-cache show $package 2> /dev/null | grep ^Version: | cut -d " " -f 2)" + if [ "$availableversion" = "" -a "$(echo $package | grep dbgsym$)" ]; then + echo "You need package $package but it does not seem to be available" + if [ "$DISTRO" = "Ubuntu" ]; then + echo " Ubuntu -dbgsym packages are typically in a separate repository" + echo " Follow https://wiki.ubuntu.com/DebuggingProgramCrash to add this repository" + elif [ "$DISTRO" = "Debian" ]; then + echo " Debian -dbgsym packages are typically in a separate repository" + echo " Follow https://wiki.debian.org/AutomaticDebugPackages to add this repository" + fi + else + echo "Need to install $package" + if [ `id -u` = "0" ]; then #attempt to install + apt-get -y install $package + fi + fi + elif ! dpkg --compare-versions $installedversion $relation $requiredversion; then + echo "Package $package version $installedversion does not match version of currently running kernel: $requiredversion" + echo " Consider apt-get upgrade && reboot" + fi +done + +user="$(id --user --name)" +if [ "$user" != "root" ]; then + groups="$(id --groups --name)" + for i in stapusr stapdev; do + if [ "$(echo $groups | grep $i)" = "" ]; then + echo "Be root or adduser $user $i" + fi + done +fi +} + +DISTRO="$(lsb_release --id --short 2> /dev/null)" +case "$DISTRO" in +Debian|Ubuntu) + prep_deb_based "$@" + ;; +*) + prep_rpm_based "$@" + ;; +esac diff --git a/tests/Regression/utrace-taskfinder-misses-events/main.fmf b/tests/Regression/utrace-taskfinder-misses-events/main.fmf new file mode 100644 index 0000000..b5af125 --- /dev/null +++ b/tests/Regression/utrace-taskfinder-misses-events/main.fmf @@ -0,0 +1,16 @@ +summary: Test for BZ#876848 (utrace taskfinder misses events when main thread) +description: '' +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap + - gcc-c++ + - kernel-debuginfo +duration: 15m +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=876848 +extra-summary: /tools/systemtap/Regression/utrace-taskfinder-misses-events +extra-task: /tools/systemtap/Regression/utrace-taskfinder-misses-events diff --git a/tests/Regression/utrace-taskfinder-misses-events/pthreadtestcase.cpp b/tests/Regression/utrace-taskfinder-misses-events/pthreadtestcase.cpp new file mode 100644 index 0000000..30a8215 --- /dev/null +++ b/tests/Regression/utrace-taskfinder-misses-events/pthreadtestcase.cpp @@ -0,0 +1,35 @@ +#include +#include +#include + +int square (int x) +{ + return (x * x); +} + +void *my_thread(void *arg) +{ + int x = 0; + int sqr; + + while (true) { + sqr = square(5); + sleep(1); + } + return NULL; +} + +int main() +{ + pthread_t thread_id; + if (pthread_create(&thread_id, NULL, my_thread, NULL)) { + fprintf(stderr, "Error creating thread\n"); + return 1; + } + if (pthread_join(thread_id, NULL)) { + fprintf(stderr, "Error joining thread\n"); + return 2; + } + return 0; +} + diff --git a/tests/Regression/utrace-taskfinder-misses-events/pthreadtestcase.stp b/tests/Regression/utrace-taskfinder-misses-events/pthreadtestcase.stp new file mode 100644 index 0000000..d6ab354 --- /dev/null +++ b/tests/Regression/utrace-taskfinder-misses-events/pthreadtestcase.stp @@ -0,0 +1,28 @@ +#! /usr/bin/env stap + +probe timer.sec(180) +{ + printf("EXITONTIMEOUT\n"); + exit() +} + +probe process("./pthreadtestcase").function("square") +{ + printf("USERSPACEFUNCTIONENTER\n") + printf("=> %s(%s)\n", probefunc(), $$parms) +} + +probe process("./pthreadtestcase").function("square").return +{ + printf("USERSPACEFUNCTIONLEAVE\n") + printf("<= %s\n", probefunc()) + exit() +} + +probe process("./pthreadtestcase").statement("*@pthreadtestcase.cpp:7") +{ + printf("USERSPACEREACHEDLINE\n") + #printf(" x=%d, sqr=%d\n\n", $x, $sqr) + printf(" x=%d\n\n", $x) +} + diff --git a/tests/Regression/utrace-taskfinder-misses-events/runtest.sh b/tests/Regression/utrace-taskfinder-misses-events/runtest.sh new file mode 100755 index 0000000..c20788c --- /dev/null +++ b/tests/Regression/utrace-taskfinder-misses-events/runtest.sh @@ -0,0 +1,77 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/utrace-taskfinder-misses-events +# Description: Test for BZ#876848 (utrace taskfinder misses events when main thread) +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2013 Red Hat, Inc. All rights reserved. +# +# This copyrighted material is made available to anyone wishing +# to use, modify, copy, or redistribute it subject to the terms +# and conditions of the GNU General Public License version 2. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public +# License along with this program; if not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +# Boston, MA 02110-1301, USA. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +# if this testcase caused kernel crash and reboot, don't try to rerun it +[[ $REBOOTCOUNT -gt 0 ]] && exit 1 + +rlJournalStart + rlPhaseStartSetup + rlRun "TMPDIR=\$(mktemp -d)" + rlRun "cp pthreadtestcase.cpp pthreadtestcase.stp $TMPDIR" + rlRun "pushd $TMPDIR" + rlPhaseEnd + + rlPhaseStart FAIL "Systemtap sanity check" + rlRun "stap --version" + rlRun "stap -v -e 'probe kernel.function(\"vfs_read\"){ exit() }'" + rlPhaseEnd + + rlPhaseStart FAIL "Prepare pthreadtestcase, run it" + rlRun "g++ -g -o pthreadtestcase pthreadtestcase.cpp -lpthread" + killall -9 pthreadtestcase &> /dev/null + ./pthreadtestcase & + MYPID=$! + sleep 3 + rlRun "ps | grep '$MYPID.*pthreadtestcase$'" + rlPhaseEnd + + rlPhaseStartTest + rlRun "stap -v pthreadtestcase.stp 2>&1 | tee mylog.txt" + rlRun "grep EXITONTIMEOUT mylog.txt" 1 + for token in USERSPACEFUNCTIONENTER \ + USERSPACEREACHEDLINE \ + USERSPACEFUNCTIONLEAVE + do + rlRun "grep ^$token$ mylog.txt" 0 + done + rlPhaseEnd + + rlPhaseStart FAIL "Shut pthreadtestcase down" + # pthreadtestcase should still be running + # so killing it should certsinly succeed + rlRun "kill $MYPID" + rlPhaseEnd + + rlPhaseStartCleanup + rlRun "popd" + rlRun "rm -r $TMPDIR" + rlPhaseEnd +rlJournalEnd diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/main.fmf b/tests/Regression/wrong-data-returned-by-nfs-commit-done/main.fmf new file mode 100644 index 0000000..c4d5b52 --- /dev/null +++ b/tests/Regression/wrong-data-returned-by-nfs-commit-done/main.fmf @@ -0,0 +1,14 @@ +summary: wrong-data-returned-by-nfs-commit-done +description: '' +contact: Martin Cermak +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - systemtap +duration: 2h +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=920444 +extra-summary: /tools/systemtap/Regression/wrong-data-returned-by-nfs-commit-done +extra-task: /tools/systemtap/Regression/wrong-data-returned-by-nfs-commit-done diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/runtest.sh b/tests/Regression/wrong-data-returned-by-nfs-commit-done/runtest.sh new file mode 100755 index 0000000..105b8b7 --- /dev/null +++ b/tests/Regression/wrong-data-returned-by-nfs-commit-done/runtest.sh @@ -0,0 +1,73 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/wrong-data-returned-by-nfs-commit-done +# Description: wrong-data-returned-by-nfs-commit-done +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2013 Red Hat, Inc. All rights reserved. +# +# This copyrighted material is made available to anyone wishing +# to use, modify, copy, or redistribute it subject to the terms +# and conditions of the GNU General Public License version 2. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public +# License along with this program; if not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +# Boston, MA 02110-1301, USA. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +PACKAGE="systemtap" + +rlJournalStart + rlPhaseStartSetup + rlRun "rpm -qf $(which --skip-alias stap)" + rlRun "TMPDIR=$(mktemp -d)" + rlRun "cp -r testpro $TMPDIR" + rlRun "pushd $TMPDIR/testpro/" + rlPhaseEnd + + rlPhaseStart FAIL "Systemtap sanity check" + rlRun "stap --version" + rlRun "stap -v -e 'probe kernel.function(\"vfs_read\"){ exit() }'" + rlRun "uname -a" + rlPhaseEnd + + rlPhaseStart FAIL "Build testing binary, prepare nfs environment" + rlRun "make" + rlRun "rhelmajor=$(rpm --eval %{rhel})" + rlRun "chmod u+x test-for-nfs" + rlRun "./test-for-nfs RHEL${rhelmajor}" + rlPhaseEnd + + rlPhaseStartTest + if stap -p2 nfs.proc.commit_done.stp >&/dev/null; then + rlRun "stap --prologue-searching=never --poison-cache -vc './nfs.proc.commit_done' nfs.proc.commit_done.stp 2>&1 | tee testout.log" + else + rlRun "stap --prologue-searching=always --poison-cache -vc './nfs.proc.commit_done' nfs.proc.commit_done.stp 2>&1 | tee testout.log" + fi + rlRun "grep -qP 'nfs.proc.commit_done server_ip:\ \d+\.\d+\.\d+\.\d+' testout.log" + rlPhaseEnd + + rlPhaseStart WARN "Clean the nfs environment up" + rlRun "./test-for-nfs -c RHEL${rhelmajor}" + rlPhaseEnd + + rlPhaseStartCleanup + rlRun "popd" + rlRun "rm -r $TMPDIR" + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/Makefile b/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/Makefile new file mode 100644 index 0000000..021de18 --- /dev/null +++ b/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/Makefile @@ -0,0 +1,11 @@ +CFLAGS+= -Wall + +SRCS = $(wildcard *.c) +TARGETS = $(patsubst %.c,%,$(SRCS)) + +all: $(TARGETS) + +install: + +clean: + rm -f $(TARGETS) diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/nfs.proc.commit_done.c b/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/nfs.proc.commit_done.c new file mode 100644 index 0000000..0417d71 --- /dev/null +++ b/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/nfs.proc.commit_done.c @@ -0,0 +1,84 @@ +#include +#include +#include +#include +#include +#include +#include +#include + +#define TEST_DIR "/systemtap-sts-nfs-share-and-mount-tmpdir/sts_mount" + +static int create_and_write(char *file_name); +static int read_file(char *file_name); + +int main(int argc, char *argv[]) +{ + char tmp_path[1024]; + char tmp_file[1024]; + char new_file[1024]; + + strcpy(tmp_path, getenv("HOME")); + strcat(tmp_path, TEST_DIR); + strcat(tmp_path, "/sts_tmp"); + strcpy(tmp_file, tmp_path); + strcpy(new_file, tmp_path); + strcat(tmp_file, "/tmp.txt"); + strcat(new_file, "/tmp2.txt"); + + if (mkdir(tmp_path, 0777) == -1) { + fprintf(stderr, "Create tmp path failed! %d\n", errno); + return -1; + } + if (create_and_write(tmp_file)) + return -1; + + if (rename(tmp_file, new_file) == -1) { + fprintf(stderr, "Rename failed! %d\n", errno); + return -1; + } + read_file(new_file); + if (remove(new_file) == -1) { + fprintf(stderr, "Remove file failed! %d\n", errno); + return -1; + } + + remove(tmp_path); + + return 0; +} + +static int create_and_write(char *file_name) +{ + char buf[] = "abcdefg123"; + int i; + int fd; + + fd = open(file_name, O_RDWR | O_CREAT, 00777); + if (!fd) { + fprintf(stderr, "Create tmp file failed!\n"); + return -1; + } + + for (i = 0; i < 1024 * 1024; i++){ + if (write(fd, buf, 10) != 10) { + fprintf(stderr, "Write error!\n"); + return -1; + } + } + + close(fd); + return 0; +} + +static int read_file(char *file_name) +{ + char buf[1024]; + int fd; + + fd = open(file_name, O_RDONLY); + lseek(fd, 1024 * 10, SEEK_SET); + read(fd, buf, 1024); + close(fd); + return 0; +} diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/nfs.proc.commit_done.stp b/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/nfs.proc.commit_done.stp new file mode 100644 index 0000000..8de8be0 --- /dev/null +++ b/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/nfs.proc.commit_done.stp @@ -0,0 +1,3 @@ +probe nfs.proc.commit_done{ + printf("nfs.proc.commit_done server_ip: %s\n", %( systemtap_v >= "4.3" %? server_ip %: ip_ntop(server_ip) %)); +} diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/test-for-nfs b/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/test-for-nfs new file mode 100755 index 0000000..156831d --- /dev/null +++ b/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/test-for-nfs @@ -0,0 +1,111 @@ +#!/bin/bash + +export NFS_TMP="$HOME/systemtap-sts-nfs-share-and-mount-tmpdir" + +nfs_service() +{ + local ret + local status="$1" + local OS_VER="$2" + + if [[ "$OS_VER" != "RHEL9" && "$OS_VER" != "RHEL8" && "$OS_VER" != "RHEL7" && "$OS_VER" != "RHEL6" && "$OS_VER" != "RHEL5" ]]; then + echo "Error: $OS_VER not supported." + return 1 + fi + + case "$status" in + restart) + ps -ef | grep "nfsd" | grep -v grep > /dev/null 2>&1 + if [ $? -eq 0 ]; then + echo "nfsd already running!!" + return 0 + fi + + if [[ "$2" == "RHEL7" || "$2" == "RHEL8" || "$2" == "RHEL9" ]]; then + /bin/systemctl restart nfs-server.service + ret=$? + else + /etc/init.d/nfs restart + ret=$? + fi + ;; + stop) + if [[ "$2" == "RHEL7" || "$2" == "RHEL8" || "$2" == "RHEL9" ]]; then + /bin/systemctl stop nfs-server.service + ret=$? + else + /etc/init.d/nfs stop + ret=$? + fi + ;; + *) + echo "Error: nfs_service [stop|restart]" + ret=1 + ;; + esac + + return $ret +} + +clean_nfs_env() +{ + umount "$NFS_TMP"/sts_mount + /usr/sbin/exportfs -u 127.0.0.1:"$NFS_TMP"/sts_share + rm -rf "$NFS_TMP" + nfs_service stop $1 + if [ $? -ne 0 ]; then + return 1 + else + echo "Info: The nfs env for test clean successfully." + return 0 + fi +} + +create_nfs_env() +{ + nfs_service restart $1 + if [ $? -ne 0 ]; then + return 1 + fi + + sleep 1 + + mkdir -p "$NFS_TMP"/sts_share + mkdir -p "$NFS_TMP"/sts_mount + + /usr/sbin/exportfs -i -o 'rw,async,no_root_squash' 127.0.0.1:"$NFS_TMP"/sts_share + mount -t nfs 127.0.0.1:"$NFS_TMP"/sts_share "$NFS_TMP"/sts_mount + + return 0 +} + +if [ $# -gt 2 ]; then + echo "Usage: test-for-nfs [-c] OS_VERSION" + exit 1 +fi + +case "$1" in +-c) + clean_nfs_env $2 + ret=$? + if [ $ret -ne 0 ]; then + echo "Error: cleaning the nfs env for test failed." + fi + ;; +*) + if [ ! -z "$1" ]; then + create_nfs_env $1 + ret=$? + if [ $ret -eq 0 ]; then + echo "Info: The nfs env for test create successfully." + else + echo "Error: creating the nfs env for test failed." + fi + else + echo "Usage: test-for-nfs [-c] OS_VERSION" + ret=1 + fi + ;; +esac + +exit $ret From ca4fdbacfc1afb3168ed6ec109cab6b9d07c0cb9 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Wed, 11 May 2022 14:49:56 +0200 Subject: [PATCH 003/101] CI Tests: make Regression/second-command-not-captured less flaky Make Regression/second-command-not-captured less flaky by restricting the output flow, preventing the transport buffers flood (PR29108). --- .../second-command-not-captured/ruby-exercise.stp | 6 ++++-- tests/Regression/second-command-not-captured/runtest.sh | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/tests/Regression/second-command-not-captured/ruby-exercise.stp b/tests/Regression/second-command-not-captured/ruby-exercise.stp index 404fdd1..8c5f42b 100644 --- a/tests/Regression/second-command-not-captured/ruby-exercise.stp +++ b/tests/Regression/second-command-not-captured/ruby-exercise.stp @@ -1,7 +1,9 @@ probe ruby.method.entry, ruby.cmethod.entry { - printf("%d -> %s::%s %s:%d\n", tid(), classname, methodname, file, line); + if((classname =~ "Array") && (methodname =~ "push")) + printf("%d -> %s::%s %s:%d\n", tid(), classname, methodname, file, line); } probe ruby.method.return, ruby.cmethod.return { - printf("%d <- %s::%s %s:%d\n", tid(), classname, methodname, file, line); + if((classname =~ "Array") && (methodname =~ "push")) + printf("%d <- %s::%s %s:%d\n", tid(), classname, methodname, file, line); } diff --git a/tests/Regression/second-command-not-captured/runtest.sh b/tests/Regression/second-command-not-captured/runtest.sh index fddabd1..65a749f 100755 --- a/tests/Regression/second-command-not-captured/runtest.sh +++ b/tests/Regression/second-command-not-captured/runtest.sh @@ -34,7 +34,7 @@ rlJournalStart rlPhaseStartTest rlLog "`which stap`" rlLog "`stap -V`" - rlRun "stap -s 100 -v ./ruby-exercise.stp -c ./test.sh -o stap.log" + rlRun "stap -v ./ruby-exercise.stp -c ./test.sh -o stap.log" rlRun "grep 'Array::push' stap.log" || rlFileSubmit "stap.log" rlPhaseEnd From 5d247c72202e7b5c23cc291f1716984e0f92ff53 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Thu, 26 May 2022 11:05:48 +0200 Subject: [PATCH 004/101] CI Tests: make Regression/python-probing less flaky Make Regression/python-probing less flaky by restricting the output flow, preventing the transport buffers flood (PR29108). --- tests/Regression/python-probing/list.stp | 2 ++ tests/Regression/python-probing/runtest.sh | 7 ++----- tests/Regression/python-probing/top.stp | 4 +--- 3 files changed, 5 insertions(+), 8 deletions(-) diff --git a/tests/Regression/python-probing/list.stp b/tests/Regression/python-probing/list.stp index 357fef6..f68e700 100755 --- a/tests/Regression/python-probing/list.stp +++ b/tests/Regression/python-probing/list.stp @@ -11,10 +11,12 @@ */ probe python.function.entry { + if ( filename =~ "random" ) printf("%s => %s in %s:%d\n", thread_indent(1), funcname, filename, lineno); } probe python.function.return { + if ( filename =~ "random" ) printf("%s <= %s in %s:%d\n", thread_indent(-1), funcname, filename, lineno); } diff --git a/tests/Regression/python-probing/runtest.sh b/tests/Regression/python-probing/runtest.sh index 52c7091..5ead47e 100755 --- a/tests/Regression/python-probing/runtest.sh +++ b/tests/Regression/python-probing/runtest.sh @@ -65,11 +65,8 @@ rlJournalStart rlRun "stap $script.stp -v -c \"$PYTHON test.py\" > $script" \ 0 "Testing with $script.stp" rlRun "tail -100 $script | col -b" 0 "Inspecting output" - if ! rlRun "grep '/usr/lib.*python.*random.py' '$script'" \ - 0 "Checking for random in the $script output"; then - rlRun "stap $script.stp -vvv -c \"$PYTHON test.py\" > $script" \ - 0 "Running $script.stp once more in verbose mode" - fi + rlRun "grep '/usr/lib.*python.*random.py' '$script'" \ + 0 "Checking for random in the $script output" rlPhaseEnd done diff --git a/tests/Regression/python-probing/top.stp b/tests/Regression/python-probing/top.stp index b5645b2..f32fbf9 100755 --- a/tests/Regression/python-probing/top.stp +++ b/tests/Regression/python-probing/top.stp @@ -8,10 +8,8 @@ probe python.function.entry } probe timer.ms(1000) { - printf("\033[2J\033[1;1H") /* clear screen */ - printf("%6s %80s %6s %30s %6s\n", - "PID", "FILENAME", "LINE", "FUNCTION", "CALLS") foreach ([pid, filename, funcname, lineno] in fn_calls- limit 1000) { + if (filename =~ "random") printf("%6d %80s %6d %30s %6d\n", pid, filename, lineno, funcname, fn_calls[pid, filename, funcname, lineno]); From 19434e180992aab712ee482d571a7eeb4e440009 Mon Sep 17 00:00:00 2001 From: Python Maint Date: Mon, 13 Jun 2022 19:54:29 +0200 Subject: [PATCH 005/101] Rebuilt for Python 3.11 --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index c1b393f..035effb 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -118,7 +118,7 @@ m stapdev stapdev Name: systemtap Version: 4.7 -Release: 2%{?release_override}%{?dist} +Release: 3%{?release_override}%{?dist} # for version, see also configure.ac @@ -1275,6 +1275,9 @@ exit 0 # PRERELEASE %changelog +* Mon Jun 13 2022 Python Maint - 4.7-3 +- Rebuilt for Python 3.11 + * Wed May 04 2022 Thomas Rodgers - 4.7-2 - Rebuilt for Boost 1.78 From 613a6720d21fa88fb33d9db58d2c4d9765f603e5 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Mon, 20 Jun 2022 08:23:06 -0400 Subject: [PATCH 006/101] Automated weekly systemtap rawhide release: 4.8~pre16557277g2882dcc9 --- .gitignore | 1 + sources | 2 +- systemtap.spec | 17 ++++++++++++++--- 3 files changed, 16 insertions(+), 4 deletions(-) diff --git a/.gitignore b/.gitignore index 1442bfe..21fc05b 100644 --- a/.gitignore +++ b/.gitignore @@ -78,3 +78,4 @@ /systemtap-4.7~pre16433134g7d871ab5.tar.gz /systemtap-4.7~pre16468670g9f253544.tar.gz /systemtap-4.7.tar.gz +/systemtap-4.8~pre16557277g2882dcc9.tar.gz diff --git a/sources b/sources index b708a2e..a8f0989 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-4.7.tar.gz) = 7d7c213dc4f7c5430f81763668da21403fbc351d1701b1096eb1ad233e3f0325e35f01dfd0a33e75f277b26fdde88c46d42dd32e32e4d4f27a45d53e2dd0f831 +SHA512 (systemtap-4.8~pre16557277g2882dcc9.tar.gz) = f9bfe71ec381491c8af11fd7acf044d1190d9d4517cc7a2259119e7062aff3ca7156184d42bd31d934b04db125905d8292dcb3b5416b1c38b3255596fd6cf3f2 diff --git a/systemtap.spec b/systemtap.spec index 035effb..3a180e5 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -117,8 +117,8 @@ m stapdev stapdev Name: systemtap -Version: 4.7 -Release: 3%{?release_override}%{?dist} +Version: 4.8~pre16557277g2882dcc9 +Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -152,7 +152,7 @@ Release: 3%{?release_override}%{?dist} Summary: Programmable system-wide instrumentation system License: GPLv2+ URL: http://sourceware.org/systemtap/ -Source: ftp://sourceware.org/pub/systemtap/releases/systemtap-%{version}.tar.gz +Source: %{name}-%{version}.tar.gz # Build* BuildRequires: make @@ -676,6 +676,11 @@ make %{?_smp_mflags} V=1 %install make DESTDIR=$RPM_BUILD_ROOT install + +%if ! (%{with_python3}) +rm -v $RPM_BUILD_ROOT%{_bindir}/stap-profile-annotate +%endif + %find_lang %{name} for dir in $(ls -1d $RPM_BUILD_ROOT%{_mandir}/{??,??_??}) ; do dir=$(echo $dir | sed -e "s|^$RPM_BUILD_ROOT||") @@ -1078,7 +1083,9 @@ exit 0 %files devel -f systemtap.lang %{_bindir}/stap %{_bindir}/stap-prep +%if %{with_python3} %{_bindir}/stap-profile-annotate +%endif %{_bindir}/stap-report %dir %{_datadir}/systemtap %{_datadir}/systemtap/runtime @@ -1275,6 +1282,10 @@ exit 0 # PRERELEASE %changelog +* Mon Jun 20 2022 Frank Ch. Eigler - 4.8-16557277g2882dcc9 +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Mon Jun 13 2022 Python Maint - 4.7-3 - Rebuilt for Python 3.11 From d5dda0dab9f124d7e30562082305515bef18f3c2 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Thu, 14 Jul 2022 14:32:00 -0400 Subject: [PATCH 007/101] Automated weekly systemtap rawhide release: 4.8~pre16578235g069e109c --- .gitignore | 1 + sources | 2 +- systemtap.spec | 6 +++++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 21fc05b..dab4c49 100644 --- a/.gitignore +++ b/.gitignore @@ -79,3 +79,4 @@ /systemtap-4.7~pre16468670g9f253544.tar.gz /systemtap-4.7.tar.gz /systemtap-4.8~pre16557277g2882dcc9.tar.gz +/systemtap-4.8~pre16578235g069e109c.tar.gz diff --git a/sources b/sources index a8f0989..f0f9701 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-4.8~pre16557277g2882dcc9.tar.gz) = f9bfe71ec381491c8af11fd7acf044d1190d9d4517cc7a2259119e7062aff3ca7156184d42bd31d934b04db125905d8292dcb3b5416b1c38b3255596fd6cf3f2 +SHA512 (systemtap-4.8~pre16578235g069e109c.tar.gz) = 13fdce61b00da8708546ba3897027386aef8186414c382abec3b15bf88ea17b67145538f7038231de85f7576066118b19aed5665dc55b6f7a5f4991e64a00848 diff --git a/systemtap.spec b/systemtap.spec index 3a180e5..fd667a8 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -117,7 +117,7 @@ m stapdev stapdev Name: systemtap -Version: 4.8~pre16557277g2882dcc9 +Version: 4.8~pre16578235g069e109c Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -1282,6 +1282,10 @@ exit 0 # PRERELEASE %changelog +* Thu Jul 14 2022 Frank Ch. Eigler - 4.8-16578235g069e109c +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Mon Jun 20 2022 Frank Ch. Eigler - 4.8-16557277g2882dcc9 - Automated weekly rawhide release - Applied spec changes from upstream git From 460815a33beb6659a57b20dd9e2d2cb783844294 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Tue, 19 Jul 2022 11:12:36 +0200 Subject: [PATCH 008/101] Rebuilt for pyparsing-3.0.9 --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index fd667a8..710c975 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -118,7 +118,7 @@ m stapdev stapdev Name: systemtap Version: 4.8~pre16578235g069e109c -Release: 1%{?release_override}%{?dist} +Release: 2%{?release_override}%{?dist} # for version, see also configure.ac @@ -1282,6 +1282,9 @@ exit 0 # PRERELEASE %changelog +* Tue Jul 19 2022 Zbigniew Jędrzejewski-Szmek - 4.8~pre16578235g069e109c-2 +- Rebuilt for pyparsing-3.0.9 + * Thu Jul 14 2022 Frank Ch. Eigler - 4.8-16578235g069e109c - Automated weekly rawhide release - Applied spec changes from upstream git From 8efeb38c25b0cf65ff350f6064e2eada97497abe Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Sat, 23 Jul 2022 10:00:37 +0000 Subject: [PATCH 009/101] Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild Signed-off-by: Fedora Release Engineering --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index 710c975..cb10681 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -118,7 +118,7 @@ m stapdev stapdev Name: systemtap Version: 4.8~pre16578235g069e109c -Release: 2%{?release_override}%{?dist} +Release: 3%{?release_override}%{?dist} # for version, see also configure.ac @@ -1282,6 +1282,9 @@ exit 0 # PRERELEASE %changelog +* Sat Jul 23 2022 Fedora Release Engineering - 4.8~pre16578235g069e109c-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild + * Tue Jul 19 2022 Zbigniew Jędrzejewski-Szmek - 4.8~pre16578235g069e109c-2 - Rebuilt for pyparsing-3.0.9 From 648b6d77e56ff170a95a3ae9eda3acf038ce3d63 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Tue, 2 Aug 2022 16:38:53 -0400 Subject: [PATCH 010/101] Automated weekly systemtap rawhide release: 4.8~pre16594727g09f1b7bb --- .gitignore | 1 + sources | 2 +- systemtap.spec | 16 ++++++++++++++-- 3 files changed, 16 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index dab4c49..99896ac 100644 --- a/.gitignore +++ b/.gitignore @@ -80,3 +80,4 @@ /systemtap-4.7.tar.gz /systemtap-4.8~pre16557277g2882dcc9.tar.gz /systemtap-4.8~pre16578235g069e109c.tar.gz +/systemtap-4.8~pre16594727g09f1b7bb.tar.gz diff --git a/sources b/sources index f0f9701..fce8ca8 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-4.8~pre16578235g069e109c.tar.gz) = 13fdce61b00da8708546ba3897027386aef8186414c382abec3b15bf88ea17b67145538f7038231de85f7576066118b19aed5665dc55b6f7a5f4991e64a00848 +SHA512 (systemtap-4.8~pre16594727g09f1b7bb.tar.gz) = c6fc1b4d23f864ea5b1937ebc5120b46ad6d0e20a869f6191807c86922fe7e536d25515b732f4f6fc25d828097e96d95ddce5e8d71c9972a65e307fcc9d1f7c8 diff --git a/systemtap.spec b/systemtap.spec index cb10681..4f91c2c 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -117,8 +117,8 @@ m stapdev stapdev Name: systemtap -Version: 4.8~pre16578235g069e109c -Release: 3%{?release_override}%{?dist} +Version: 4.8~pre16594727g09f1b7bb +Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -206,8 +206,12 @@ BuildRequires: xmlto /usr/share/xmlto/format/fo/pdf BuildRequires: emacs %endif %if %{with_java} +%if 0%{?fedora} >= 36 +BuildRequires: java-latest-openjdk-devel +%else BuildRequires: java-devel %endif +%endif %if %{with_virthost} # BuildRequires: libvirt-devel >= 1.0.2 BuildRequires: pkgconfig(libvirt) @@ -484,7 +488,11 @@ Conflicts: systemtap-runtime = %{version}-%{release}.x86_64 %endif Requires: byteman > 2.0 Requires: iproute +%if 0%{?fedora} >= 36 +BuildRequires: java-latest-openjdk-devel +%else Requires: java-devel +%endif %description runtime-java This package includes support files needed to run systemtap scripts @@ -1282,6 +1290,10 @@ exit 0 # PRERELEASE %changelog +* Tue Aug 02 2022 Frank Ch. Eigler - 4.8-16594727g09f1b7bb +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Sat Jul 23 2022 Fedora Release Engineering - 4.8~pre16578235g069e109c-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild From 3138353e0edda2e33f8d23fd939398666d8a57c2 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Tue, 2 Aug 2022 17:03:09 -0400 Subject: [PATCH 011/101] Automated weekly systemtap rawhide release: 4.8~pre16594741g5bdc37b9 --- .gitignore | 1 + sources | 2 +- systemtap.spec | 18 +++++++++--------- 3 files changed, 11 insertions(+), 10 deletions(-) diff --git a/.gitignore b/.gitignore index 99896ac..75401da 100644 --- a/.gitignore +++ b/.gitignore @@ -81,3 +81,4 @@ /systemtap-4.8~pre16557277g2882dcc9.tar.gz /systemtap-4.8~pre16578235g069e109c.tar.gz /systemtap-4.8~pre16594727g09f1b7bb.tar.gz +/systemtap-4.8~pre16594741g5bdc37b9.tar.gz diff --git a/sources b/sources index fce8ca8..3a9887a 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-4.8~pre16594727g09f1b7bb.tar.gz) = c6fc1b4d23f864ea5b1937ebc5120b46ad6d0e20a869f6191807c86922fe7e536d25515b732f4f6fc25d828097e96d95ddce5e8d71c9972a65e307fcc9d1f7c8 +SHA512 (systemtap-4.8~pre16594741g5bdc37b9.tar.gz) = d47512e9bc09bb9b2babc08a66ad39004790e9903197aa595c0854737178e04b95fe577f391d4ab40bc36f2b968c7cb97d3a3d96334d09aa88b92719d8c122f3 diff --git a/systemtap.spec b/systemtap.spec index 4f91c2c..a595224 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -20,7 +20,11 @@ %{!?with_bpf: %global with_bpf 0%{?fedora} >= 22 || 0%{?rhel} >= 8} %{!?with_systemd: %global with_systemd 0%{?fedora} >= 19 || 0%{?rhel} >= 7} %{!?with_emacsvim: %global with_emacsvim 0%{?fedora} >= 19 || 0%{?rhel} >= 7} +%ifarch %{ix86} +%{!?with_java: %global with_java 0} +%else %{!?with_java: %global with_java 0%{?fedora} >= 19 || 0%{?rhel} >= 7} +%endif %{!?with_debuginfod: %global with_debuginfod 0%{?fedora} >= 25 || 0%{?rhel} >= 7} %{!?with_virthost: %global with_virthost 0%{?fedora} >= 19 || 0%{?rhel} >= 7} %{!?with_virtguest: %global with_virtguest 1} @@ -117,7 +121,7 @@ m stapdev stapdev Name: systemtap -Version: 4.8~pre16594727g09f1b7bb +Version: 4.8~pre16594741g5bdc37b9 Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -206,12 +210,8 @@ BuildRequires: xmlto /usr/share/xmlto/format/fo/pdf BuildRequires: emacs %endif %if %{with_java} -%if 0%{?fedora} >= 36 -BuildRequires: java-latest-openjdk-devel -%else BuildRequires: java-devel %endif -%endif %if %{with_virthost} # BuildRequires: libvirt-devel >= 1.0.2 BuildRequires: pkgconfig(libvirt) @@ -488,11 +488,7 @@ Conflicts: systemtap-runtime = %{version}-%{release}.x86_64 %endif Requires: byteman > 2.0 Requires: iproute -%if 0%{?fedora} >= 36 -BuildRequires: java-latest-openjdk-devel -%else Requires: java-devel -%endif %description runtime-java This package includes support files needed to run systemtap scripts @@ -1290,6 +1286,10 @@ exit 0 # PRERELEASE %changelog +* Tue Aug 02 2022 Frank Ch. Eigler - 4.8-16594741g5bdc37b9 +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Tue Aug 02 2022 Frank Ch. Eigler - 4.8-16594727g09f1b7bb - Automated weekly rawhide release - Applied spec changes from upstream git From 96a7f166701c3e33ec99c71e656dd20f617b59c1 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Wed, 10 Aug 2022 14:05:07 +0200 Subject: [PATCH 012/101] tests/Regression/elfutils-debuginfod-client-not-being-called: Debuginfod client cache location change Reflect elfutils upstream commit e939590219 (PR25502) changing the location of the client cache. Without this update the first run of the testcase works, but not the subsequent runs. --- .../elfutils-debuginfod-client-not-being-called/dotest.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/Regression/elfutils-debuginfod-client-not-being-called/dotest.sh b/tests/Regression/elfutils-debuginfod-client-not-being-called/dotest.sh index 02970b4..a1d48fb 100644 --- a/tests/Regression/elfutils-debuginfod-client-not-being-called/dotest.sh +++ b/tests/Regression/elfutils-debuginfod-client-not-being-called/dotest.sh @@ -2,7 +2,7 @@ set -xe -rm -rf ~/.debuginfod_client_cache ~/.systemtap ||: +rm -rf ~/.cache/debuginfod_client ~/.systemtap ||: debuginfod -p 8008 -d $(mktemp) -vvvvv >& debuginfod.log & PID=$! From 4da5c082d7c6bb2710f2b0338d92be73aa5434b4 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Thu, 6 Oct 2022 10:19:54 -0400 Subject: [PATCH 013/101] Automated weekly systemtap rawhide release: 4.8~pre16650659g6a096a7d --- .gitignore | 1 + sources | 2 +- systemtap.spec | 6 +++++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 75401da..ad4775b 100644 --- a/.gitignore +++ b/.gitignore @@ -82,3 +82,4 @@ /systemtap-4.8~pre16578235g069e109c.tar.gz /systemtap-4.8~pre16594727g09f1b7bb.tar.gz /systemtap-4.8~pre16594741g5bdc37b9.tar.gz +/systemtap-4.8~pre16650659g6a096a7d.tar.gz diff --git a/sources b/sources index 3a9887a..dc01216 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-4.8~pre16594741g5bdc37b9.tar.gz) = d47512e9bc09bb9b2babc08a66ad39004790e9903197aa595c0854737178e04b95fe577f391d4ab40bc36f2b968c7cb97d3a3d96334d09aa88b92719d8c122f3 +SHA512 (systemtap-4.8~pre16650659g6a096a7d.tar.gz) = d279a2138a215c69daad3d53303ed4fd7912eb5fd685a95538d2eeb6669edfb94136c34845004aa206151917a97b039d949696689d5149c6e979fd41d9d79e08 diff --git a/systemtap.spec b/systemtap.spec index a595224..4a80ea1 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -121,7 +121,7 @@ m stapdev stapdev Name: systemtap -Version: 4.8~pre16594741g5bdc37b9 +Version: 4.8~pre16650659g6a096a7d Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -1286,6 +1286,10 @@ exit 0 # PRERELEASE %changelog +* Thu Oct 06 2022 Frank Ch. Eigler - 4.8-16650659g6a096a7d +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Tue Aug 02 2022 Frank Ch. Eigler - 4.8-16594741g5bdc37b9 - Automated weekly rawhide release - Applied spec changes from upstream git From 359f52a3b01691750ab44431f35765e587fc14da Mon Sep 17 00:00:00 2001 From: Serhei Makarov Date: Thu, 3 Nov 2022 17:30:09 -0400 Subject: [PATCH 014/101] upstream release 4.8 --- .gitignore | 1 + sources | 2 +- systemtap.spec | 46 ++++++++-------------------------------------- 3 files changed, 10 insertions(+), 39 deletions(-) diff --git a/.gitignore b/.gitignore index ad4775b..511f7f4 100644 --- a/.gitignore +++ b/.gitignore @@ -83,3 +83,4 @@ /systemtap-4.8~pre16594727g09f1b7bb.tar.gz /systemtap-4.8~pre16594741g5bdc37b9.tar.gz /systemtap-4.8~pre16650659g6a096a7d.tar.gz +/systemtap-4.8.tar.gz diff --git a/sources b/sources index dc01216..9266c31 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-4.8~pre16650659g6a096a7d.tar.gz) = d279a2138a215c69daad3d53303ed4fd7912eb5fd685a95538d2eeb6669edfb94136c34845004aa206151917a97b039d949696689d5149c6e979fd41d9d79e08 +SHA512 (systemtap-4.8.tar.gz) = fdcbc48ba17b2155c1419d99147a4cfbee2e69db945bfd0e6881b71ab11165bd23ea7ce9456856ae36807fb18f9934880a6b7c44456b63833ea260038744d9f2 diff --git a/systemtap.spec b/systemtap.spec index 4a80ea1..fe70b7c 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -121,7 +121,7 @@ m stapdev stapdev Name: systemtap -Version: 4.8~pre16650659g6a096a7d +Version: 4.8 Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -156,7 +156,7 @@ Release: 1%{?release_override}%{?dist} Summary: Programmable system-wide instrumentation system License: GPLv2+ URL: http://sourceware.org/systemtap/ -Source: %{name}-%{version}.tar.gz +Source: ftp://sourceware.org/pub/systemtap/releases/systemtap-%{version}.tar.gz # Build* BuildRequires: make @@ -236,9 +236,6 @@ BuildRequires: python3 BuildRequires: python3-devel BuildRequires: python3-setuptools %endif -%if %{with_specific_python} -BuildRequires: /usr/bin/pathfix.py -%endif %if %{with_httpd} BuildRequires: libmicrohttpd-devel @@ -822,7 +819,7 @@ done %if %{with_specific_python} # Some files got ambiguous python shebangs, we fix them after everything else is done -pathfix.py -pni "%{__python3} %{py3_shbang_opts}" %{buildroot}%{python3_sitearch} %{buildroot}%{_bindir}/* +%py3_shebang_fix %{buildroot}%{python3_sitearch} %{buildroot}%{_bindir}/* %endif %pre runtime @@ -877,7 +874,8 @@ if [ ! -f ~stap-server/.systemtap/rc ]; then numcpu=`/usr/bin/getconf _NPROCESSORS_ONLN` if [ -z "$numcpu" -o "$numcpu" -lt 1 ]; then numcpu=1; fi nproc=`expr $numcpu \* 30` - echo "--rlimit-as=614400000 --rlimit-cpu=60 --rlimit-nproc=$nproc --rlimit-stack=1024000 --rlimit-fsize=51200000" > ~stap-server/.systemtap/rc + # PR29661 -> 4G + echo "--rlimit-as=4294967296 --rlimit-cpu=60 --rlimit-nproc=$nproc --rlimit-stack=1024000 --rlimit-fsize=51200000" > ~stap-server/.systemtap/rc chown stap-server:stap-server ~stap-server/.systemtap/rc fi @@ -1286,37 +1284,9 @@ exit 0 # PRERELEASE %changelog -* Thu Oct 06 2022 Frank Ch. Eigler - 4.8-16650659g6a096a7d -- Automated weekly rawhide release -- Applied spec changes from upstream git - -* Tue Aug 02 2022 Frank Ch. Eigler - 4.8-16594741g5bdc37b9 -- Automated weekly rawhide release -- Applied spec changes from upstream git - -* Tue Aug 02 2022 Frank Ch. Eigler - 4.8-16594727g09f1b7bb -- Automated weekly rawhide release -- Applied spec changes from upstream git - -* Sat Jul 23 2022 Fedora Release Engineering - 4.8~pre16578235g069e109c-3 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild - -* Tue Jul 19 2022 Zbigniew Jędrzejewski-Szmek - 4.8~pre16578235g069e109c-2 -- Rebuilt for pyparsing-3.0.9 - -* Thu Jul 14 2022 Frank Ch. Eigler - 4.8-16578235g069e109c -- Automated weekly rawhide release -- Applied spec changes from upstream git - -* Mon Jun 20 2022 Frank Ch. Eigler - 4.8-16557277g2882dcc9 -- Automated weekly rawhide release -- Applied spec changes from upstream git - -* Mon Jun 13 2022 Python Maint - 4.7-3 -- Rebuilt for Python 3.11 - -* Wed May 04 2022 Thomas Rodgers - 4.7-2 -- Rebuilt for Boost 1.78 +* Thu Nov 03 2022 Serhei Makarov - 4.8-1 +- Upstream release, see wiki page below for detailed notes. + https://sourceware.org/systemtap/wiki/SystemTapReleases * Mon May 02 2022 Frank Ch. Eigler - 4.7-1 - Upstream release, see wiki page below for detailed notes. From d5b191f9b041057d597b9da9730a2a8078b39866 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Mon, 12 Dec 2022 13:55:48 +0100 Subject: [PATCH 015/101] tests: Fix fmf plan deprecated attributes --- plans/ci.fmf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plans/ci.fmf b/plans/ci.fmf index a9301ab..95afd8d 100644 --- a/plans/ci.fmf +++ b/plans/ci.fmf @@ -9,4 +9,4 @@ prepare: - glibc-headers-x86 - glibc-headers-s390 execute: - how: beakerlib + how: tmt From 14dabc02a628adc8a22a645ea8e59c6d676fbc3b Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Sat, 21 Jan 2023 04:34:30 +0000 Subject: [PATCH 016/101] Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild Signed-off-by: Fedora Release Engineering --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index fe70b7c..e135459 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -122,7 +122,7 @@ m stapdev stapdev Name: systemtap Version: 4.8 -Release: 1%{?release_override}%{?dist} +Release: 2%{?release_override}%{?dist} # for version, see also configure.ac @@ -1284,6 +1284,9 @@ exit 0 # PRERELEASE %changelog +* Sat Jan 21 2023 Fedora Release Engineering - 4.8-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild + * Thu Nov 03 2022 Serhei Makarov - 4.8-1 - Upstream release, see wiki page below for detailed notes. https://sourceware.org/systemtap/wiki/SystemTapReleases From 6b7d1588abfa6c03afefcb0ee282d194accb6c99 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Wed, 8 Feb 2023 12:36:07 -0500 Subject: [PATCH 017/101] respin with important upstream fixes --- rhbz1997192.patch | 50 ++++++++++++++++++++++++++++++ rhbz2145242.patch | 30 ++++++++++++++++++ rhbz2149223.patch | 78 +++++++++++++++++++++++++++++++++++++++++++++++ rhbz2149666.patch | 73 ++++++++++++++++++++++++++++++++++++++++++++ rhbz2154430.patch | 72 +++++++++++++++++++++++++++++++++++++++++++ systemtap.spec | 19 +++++++++++- 6 files changed, 321 insertions(+), 1 deletion(-) create mode 100644 rhbz1997192.patch create mode 100644 rhbz2145242.patch create mode 100644 rhbz2149223.patch create mode 100644 rhbz2149666.patch create mode 100644 rhbz2154430.patch diff --git a/rhbz1997192.patch b/rhbz1997192.patch new file mode 100644 index 0000000..4500e85 --- /dev/null +++ b/rhbz1997192.patch @@ -0,0 +1,50 @@ +commit 47cab810bb7ea315a2dec23c2f61e7ba74515b82 +Author: Martin Cermak +Date: Fri Dec 16 16:08:20 2022 -0500 + + tapset: nfs.proc.commit_done compilation on some kernels + + Correct: + 9.0 Server x86_64 # stap -vp3 nfs.proc.commit_done.stp + + Pass 1: parsed user script and 482 library scripts using 108088virt/88468res/12460shr/75476data kb, in 190usr/60sys/501real ms. + semantic error: invalid access '->task' vs 'void*': operator '->' at /usr/share/systemtap/tapset/linux/nfs_proc.stpm:16:21 + source: ( get_ip(&@nfs_data->task) ) + ^ + in expansion of macro: operator '@_nfs_data_server_ip' at /usr/share/systemtap/tapset/linux/nfs_proc.stp:1421:15 + source: server_ip = @_nfs_data_server_ip($task->tk_calldata) + ^ + +diff --git a/tapset/linux/nfs_proc.stp b/tapset/linux/nfs_proc.stp +index 9b1f65f5f..4413384f9 100644 +--- a/tapset/linux/nfs_proc.stp ++++ b/tapset/linux/nfs_proc.stp +@@ -1442,10 +1442,11 @@ probe nfs.proc3.commit_done = kernel.function("nfs3_commit_done") !, + valid = @_nfs_data_valid($data) + } + else { +- server_ip = @_nfs_data_server_ip($task->tk_calldata) +- prot = @_nfs_data_prot($task->tk_calldata) +- count = @_nfs_data_res_count($task->tk_calldata) +- valid = @_nfs_data_valid($task->tk_calldata) ++ _tk_calldata=@choose_defined($task->tk_calldata, @cast($task, "rpc_task", "kernel:nfs")->tk_calldata) ++ server_ip = @_nfs_data_server_ip(_tk_calldata) ++ prot = @_nfs_data_prot(_tk_calldata) ++ count = @_nfs_data_res_count(_tk_calldata) ++ valid = @_nfs_data_valid(_tk_calldata) + } + timestamp = 0 + version = 3 +diff --git a/tapset/linux/nfs_proc.stpm b/tapset/linux/nfs_proc.stpm +index 8576c0f33..4fe40b2a5 100644 +--- a/tapset/linux/nfs_proc.stpm ++++ b/tapset/linux/nfs_proc.stpm +@@ -13,7 +13,7 @@ + + @define _nfs_data_server_ip(nfs_data) + %( +- ( get_ip(&@nfs_data->task) ) ++ ( get_ip(@choose_defined(&@nfs_data->task, &@cast(@nfs_data, "nfs_commit_data", "kernel:nfs")->task)) ) + %) + + @define _nfs_data_prot(nfs_data) diff --git a/rhbz2145242.patch b/rhbz2145242.patch new file mode 100644 index 0000000..1853a64 --- /dev/null +++ b/rhbz2145242.patch @@ -0,0 +1,30 @@ +commit 578e60102871d11ed8c18d36f6286f3a96258d8f +Author: Ryan Goldberg +Date: Thu Dec 1 16:15:44 2022 -0500 + + PR29676: Wildcard expansion fix for labels + + PR29676, introduced an bug where function symbols from the symbol + table were expanded in the function component resulting in wildcards + not being expanded in labels. This fix, removes the issue by restricting + the symbol table query to probes which don't need further debuginfo to + expand. + +diff --git a/tapsets.cxx b/tapsets.cxx +index 0ec71ebda..46b10f26e 100644 +--- a/tapsets.cxx ++++ b/tapsets.cxx +@@ -1256,7 +1256,11 @@ dwarf_query::handle_query_module() + // in the symbol table but not in dwarf and minidebuginfo is + // located in the gnu_debugdata section, alias_dupes checking + // is done before adding any probe points +- if(!pending_interrupts) ++ // PR29676. Some probes require additional debuginfo ++ // to expand wildcards (ex. .label, .callee). Since the debuginfo is ++ // not available, don't bother looking in the symbol table for these results. ++ // This can result in 0 results, if there is no dwarf info present ++ if(!pending_interrupts && !(has_label || has_callee || has_callees_num)) + query_module_symtab(); + } + + diff --git a/rhbz2149223.patch b/rhbz2149223.patch new file mode 100644 index 0000000..75ba486 --- /dev/null +++ b/rhbz2149223.patch @@ -0,0 +1,78 @@ +commit 05eb6742c169226ae09f1737aa8b9dc1dc12adb5 +Author: Mark Wielaard +Date: Tue Nov 29 18:50:58 2022 +0100 + + Handle DWARF5 DW_OP_implicit_pointer and DW_OP_entry_value + + These are the same as the GNU extensions for older DWARF, + DW_OP_GNU_implicit_pointer and DW_GNU_entry_value. + +diff --git a/loc2stap.cxx b/loc2stap.cxx +index efc78cc57..53316a480 100644 +--- a/loc2stap.cxx ++++ b/loc2stap.cxx +@@ -23,6 +23,11 @@ + #define DW_OP_GNU_entry_value 0xf3 + #endif + ++#if ! _ELFUTILS_PREREQ(0, 171) ++#define DW_OP_entry_value 0xa3 ++#define DW_OP_implicit_pointer 0xa0 ++#endif ++ + #define N_(x) x + + +@@ -372,7 +377,7 @@ location_context::translate (const Dwarf_Op *expr, const size_t len, + DIE ("operations follow DW_OP_implicit_value"); + + if (implicit_pointer != NULL) +- DIE ("operations follow DW_OP_GNU_implicit_pointer"); ++ DIE ("operations follow DW_OP implicit_pointer"); + } + + switch (expr[i].atom) +@@ -662,6 +667,7 @@ location_context::translate (const Dwarf_Op *expr, const size_t len, + + #if _ELFUTILS_PREREQ (0, 149) + case DW_OP_GNU_implicit_pointer: ++ case DW_OP_implicit_pointer: + implicit_pointer = &expr[i]; + /* Fake top of stack: implicit_pointer being set marks it. */ + PUSH(NULL); +@@ -684,10 +690,11 @@ location_context::translate (const Dwarf_Op *expr, const size_t len, + break; + + case DW_OP_GNU_entry_value: ++ case DW_OP_entry_value: + { + expression *result = handle_GNU_entry_value (expr[i]); + if (result == NULL) +- DIE("DW_OP_GNU_entry_value unable to resolve value"); ++ DIE("DW_OP entry_value unable to resolve value"); + PUSH(result); + } + break; +@@ -1248,7 +1255,8 @@ location_context::location_relative (const Dwarf_Op *expr, size_t len, + break; + + case DW_OP_GNU_entry_value: +- DIE ("unhandled DW_OP_GNU_entry_value"); ++ case DW_OP_entry_value: ++ DIE ("unhandled DW_OP entry_value"); + break; + + default: +diff --git a/testsuite/systemtap.base/dw_entry_value.exp b/testsuite/systemtap.base/dw_entry_value.exp +index 7339fc5fa..b728fa7ff 100644 +--- a/testsuite/systemtap.base/dw_entry_value.exp ++++ b/testsuite/systemtap.base/dw_entry_value.exp +@@ -10,7 +10,7 @@ if { $res != "" } { + pass "$test: compiled $test.c" + } + +-if { ![catch { exec eu-readelf -w $test | grep GNU_entry_value }] } { ++if { ![catch { exec eu-readelf -w $test | grep entry_value: }] } { + stap_run $test no_load $all_pass_string $srcdir/$subdir/$test.stp -c ./${test} -w + } else { + untested "$test: no DW_OP_GNU_entry_value found" diff --git a/rhbz2149666.patch b/rhbz2149666.patch new file mode 100644 index 0000000..74be846 --- /dev/null +++ b/rhbz2149666.patch @@ -0,0 +1,73 @@ +commit 7eed8d1fef36997b9e4c1d9cdb67643483a51e56 +Author: William Cohen +Date: Fri Nov 4 11:12:05 2022 -0400 + + Ensure that SystemTap runtime uses smp_processor_id() in proper context + + There were cases on Fedora 36 and Rawhide running kernels with + CONFIG_DEBUG_PREEMPT=y where systemtap scripts would trigger kernel + log messages like the following: + + [ 257.544406] check_preemption_disabled: 4 callbacks suppressed + [ 257.544409] BUG: using smp_processor_id() in preemptible [00000000] code: staprun/2106 + [ 257.544465] caller is _stp_runtime_context_trylock+0x12/0x70 [stap_e36600406768aeefd49daf9fc7a3d23c_2106] + [ 257.544507] CPU: 0 PID: 2106 Comm: staprun Tainted: G OE ------- --- 6.1.0-0.rc2.20221028git23758867219c.24.fc38.x86_64 #1 + [ 257.544544] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.0-1.fc36 04/01/2014 + [ 257.544571] Call Trace: + [ 257.544583] + [ 257.544593] dump_stack_lvl+0x5b/0x77 + [ 257.544620] check_preemption_disabled+0xe1/0xf0 + [ 257.544641] _stp_runtime_context_trylock+0x12/0x70 [stap_e36600406768aeefd49daf9fc7a3d23c_2106] + [ 257.544673] _stp_runtime_entryfn_get_context+0xb/0x70 [stap_e36600406768aeefd49daf9fc7a3d23c_2106] + [ 257.544705] _stp_ctl_send+0x76/0x1e0 [stap_e36600406768aeefd49daf9fc7a3d23c_2106] + [ 257.544735] _stp_transport_init+0x71a/0x860 [stap_e36600406768aeefd49daf9fc7a3d23c_2106] + [ 257.544771] ? kallsyms_on_each_symbol+0x30/0x30 [stap_e36600406768aeefd49daf9fc7a3d23c_2106] + [ 257.544803] do_one_initcall+0x6b/0x320 + [ 257.544827] do_init_module+0x4a/0x200 + [ 257.544844] __do_sys_init_module+0x16a/0x1a0 + [ 257.544870] do_syscall_64+0x58/0x80 + [ 257.544885] ? up_read+0x17/0x20 + [ 257.544902] ? lock_is_held_type+0xe8/0x140 + [ 257.544921] ? asm_exc_page_fault+0x22/0x30 + [ 257.544939] ? lockdep_hardirqs_on+0x7d/0x100 + [ 257.544956] entry_SYSCALL_64_after_hwframe+0x63/0xcd + [ 257.544975] RIP: 0033:0x7f3cde12f5de + [ 257.544992] Code: 48 8b 0d 35 68 0c 00 f7 d8 64 89 01 48 83 c8 ff c3 66 2e 0f 1f 84 00 00 00 00 00 90 f3 0f 1e fa 49 89 ca b8 af 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 8b 0d 02 68 0c 00 f7 d8 64 89 01 48 + [ 257.545010] RSP: 002b:00007ffc5170c418 EFLAGS: 00000246 ORIG_RAX: 00000000000000af + [ 257.545010] RAX: ffffffffffffffda RBX: 0000563620bd4020 RCX: 00007f3cde12f5de + [ 257.545010] RDX: 0000563620bd4020 RSI: 0000000000040ea0 RDI: 00007f3cde44a010 + [ 257.545010] RBP: 0000000000000003 R08: 0000000000000000 R09: 0000000000000000 + [ 257.545010] R10: 0000000000000053 R11: 0000000000000246 R12: 00007ffc5170c510 + [ 257.545010] R13: 00007f3cde44a010 R14: 00007ffc5170c440 R15: 00007f3cde4631e8 + [ 257.545010] + + This issue was introduced by git commit 1641b6e7ea which added a fast + path check that used smp_processor_id() without first having a + preempt_disable(). The code now ensures that preemption is disabled + before using the smp_processor_id(). + +diff --git a/runtime/linux/runtime_context.h b/runtime/linux/runtime_context.h +index 3ed3cbd22..ee3870f32 100644 +--- a/runtime/linux/runtime_context.h ++++ b/runtime/linux/runtime_context.h +@@ -49,13 +49,18 @@ static bool _stp_runtime_context_trylock(void) + { + bool locked; + ++ /* Need to disable preemption because of the smp_processor_id() call ++ in _stp_runtime_get_context(). */ ++ preempt_disable(); ++ + /* fast path to ignore new online CPUs without percpu context memory + * allocations. this also serves as an extra safe guard for NULL context + * pointers. */ +- if (unlikely(_stp_runtime_get_context() == NULL)) ++ if (unlikely(_stp_runtime_get_context() == NULL)) { ++ preempt_enable_no_resched(); + return false; ++ } + +- preempt_disable(); + locked = atomic_add_unless(&_stp_contexts_busy_ctr, 1, INT_MAX); + if (!locked) + preempt_enable_no_resched(); diff --git a/rhbz2154430.patch b/rhbz2154430.patch new file mode 100644 index 0000000..0e6a7c2 --- /dev/null +++ b/rhbz2154430.patch @@ -0,0 +1,72 @@ +commit 8f3498781413a710dc9e128f5a96891a6a18fc52 +Author: Martin Cermak +Date: Wed Dec 14 17:37:58 2022 +0100 + + PR29766: kernel.function("__set_page_dirty_buffers") not found in vfs.stp + + Updates needed for 6.1.0-65.fc38 compatibility. + +diff --git a/tapset/linux/vfs.stp b/tapset/linux/vfs.stp +index e3c1a3032..aebeb3fc0 100644 +--- a/tapset/linux/vfs.stp ++++ b/tapset/linux/vfs.stp +@@ -822,13 +822,15 @@ probe vfs.buffer_migrate_page.return = + } + + /* default if aop not set, __set_page_dirty_nobuffers usually used if set */ +-probe vfs.__set_page_dirty_buffers = kernel.function("__set_page_dirty_buffers") ++/* block_dirty_folio related to kernel commit e621900ad28b748e058b81d6078 */ ++probe vfs.__set_page_dirty_buffers = kernel.function("__set_page_dirty_buffers")!, ++ kernel.function("block_dirty_folio") + { +- dev = __page_dev($page) +- devname = __find_bdevname(dev, __page_bdev($page)) +- ino = __page_ino($page) ++ dev = __page_dev(@choose_defined($page, $folio)) ++ devname = __find_bdevname(dev, __page_bdev(@choose_defined($page, $folio))) ++ ino = __page_ino(@choose_defined($page, $folio)) + +- index = __page_index($page) ++ index = __page_index(@choose_defined($page, $folio)) + + name = "__set_page_dirty_buffers" + argstr = sprintf("%d", index) +@@ -837,7 +839,8 @@ probe vfs.__set_page_dirty_buffers = kernel.function("__set_page_dirty_buffers") + units = "pages" + } + probe vfs.__set_page_dirty_buffers.return = +- kernel.function("__set_page_dirty_buffers").return ++ kernel.function("__set_page_dirty_buffers").return!, ++ kernel.function("block_dirty_folio") + { + name = "__set_page_dirty_buffers" + retstr = sprintf("%d", $return) +@@ -914,8 +917,9 @@ probe __vfs.ext4_mpage_readpages.return = + + + /* newer style */ ++/* add_to_page_cache_locked removed per kernel commit f00654007fe1c15 */ + probe vfs.__add_to_page_cache = +- kernel.function("add_to_page_cache_locked"), ++ kernel.function("add_to_page_cache_locked") !, + kernel.function("add_to_page_cache_lru") + { } + +@@ -939,7 +943,7 @@ probe vfs.add_to_page_cache = + + /* newer style */ + probe vfs.__add_to_page_cache.return = +- kernel.function("add_to_page_cache_locked").return, ++ kernel.function("add_to_page_cache_locked").return !, + kernel.function("add_to_page_cache_lru").return + { } + +@@ -958,7 +962,7 @@ probe vfs.add_to_page_cache.return = + + probe vfs.remove_from_page_cache = + kernel.function("__delete_from_page_cache") !, +- kernel.function("__remove_from_page_cache") ++ kernel.function("__remove_from_page_cache") ? + { + dev = __page_dev($page) + devname = __find_bdevname(dev, __page_bdev($page)) diff --git a/systemtap.spec b/systemtap.spec index e135459..e17cf7a 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -122,7 +122,7 @@ m stapdev stapdev Name: systemtap Version: 4.8 -Release: 2%{?release_override}%{?dist} +Release: 3%{?release_override}%{?dist} # for version, see also configure.ac @@ -158,6 +158,14 @@ License: GPLv2+ URL: http://sourceware.org/systemtap/ Source: ftp://sourceware.org/pub/systemtap/releases/systemtap-%{version}.tar.gz +Patch1: rhbz1997192.patch +Patch2: rhbz2145242.patch +Patch3: rhbz2149223.patch +Patch4: rhbz2149666.patch +Patch5: rhbz2154430.patch + + + # Build* BuildRequires: make BuildRequires: gcc-c++ @@ -575,6 +583,12 @@ systemtap-runtime-virthost machine to execute systemtap scripts. %prep %setup -q +%patch1 -p1 +%patch2 -p1 +%patch3 -p1 +%patch4 -p1 +%patch5 -p1 + %build # Enable/disable the dyninst pure-userspace backend @@ -1284,6 +1298,9 @@ exit 0 # PRERELEASE %changelog +* Wed Feb 08 2023 Frank Ch. Eigler - 4.8-3 +- backport several RHEL/upstream patches + * Sat Jan 21 2023 Fedora Release Engineering - 4.8-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild From f407c7e3a199b6260cea8ee05b955a44be024240 Mon Sep 17 00:00:00 2001 From: Jonathan Wakely Date: Mon, 20 Feb 2023 22:18:20 +0000 Subject: [PATCH 018/101] Rebuilt for Boost 1.81 --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index e17cf7a..003149f 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -122,7 +122,7 @@ m stapdev stapdev Name: systemtap Version: 4.8 -Release: 3%{?release_override}%{?dist} +Release: 4%{?release_override}%{?dist} # for version, see also configure.ac @@ -1298,6 +1298,9 @@ exit 0 # PRERELEASE %changelog +* Mon Feb 20 2023 Jonathan Wakely - 4.8-4 +- Rebuilt for Boost 1.81 + * Wed Feb 08 2023 Frank Ch. Eigler - 4.8-3 - backport several RHEL/upstream patches From da710f5bb85735a82ef14f2582e0bc532614b553 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Tue, 21 Feb 2023 16:46:33 +0100 Subject: [PATCH 019/101] CI tests: On Fedora run Tier1 tests only. --- plans/ci.fmf | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/plans/ci.fmf b/plans/ci.fmf index 95afd8d..8987a77 100644 --- a/plans/ci.fmf +++ b/plans/ci.fmf @@ -1,8 +1,11 @@ summary: CI Gating Plan +adjust: + - when: distro == fedora + discover+: + filter: 'tier: 1' discover: how: fmf directory: tests - filter: 'tier: 1' prepare: how: install exclude: From 671f002697e467ceb14a52d9c6bf37723ab86fbf Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Tue, 21 Feb 2023 18:46:22 +0100 Subject: [PATCH 020/101] Make yamllint happier --- plans/ci.fmf | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/plans/ci.fmf b/plans/ci.fmf index 8987a77..6ef79f3 100644 --- a/plans/ci.fmf +++ b/plans/ci.fmf @@ -1,15 +1,15 @@ summary: CI Gating Plan adjust: - - when: distro == fedora - discover+: - filter: 'tier: 1' + - when: distro == fedora + discover+: + filter: 'tier: 1' discover: - how: fmf - directory: tests + how: fmf + directory: tests prepare: - how: install - exclude: - - glibc-headers-x86 - - glibc-headers-s390 + how: install + exclude: + - glibc-headers-x86 + - glibc-headers-s390 execute: - how: tmt + how: tmt From 6e2eede1a17074174912df668e4995f22f922fde Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Tue, 21 Feb 2023 20:41:54 +0100 Subject: [PATCH 021/101] CI tests: bz2152970 is a known issue --- tests/Regression/python-probing/runtest.sh | 4 +++- tests/Regression/small-tests/main.fmf | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/tests/Regression/python-probing/runtest.sh b/tests/Regression/python-probing/runtest.sh index 5ead47e..e8ce264 100755 --- a/tests/Regression/python-probing/runtest.sh +++ b/tests/Regression/python-probing/runtest.sh @@ -26,8 +26,8 @@ # # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# Include rhts environment . /usr/share/beakerlib/beakerlib.sh || exit 1 +. /etc/os-release || exit 1 # Packages to be tested PACKAGES="${PACKAGES:-python3}" @@ -60,6 +60,8 @@ rlJournalStart # Note that typically you need to be root to run "stap" (or be within # an appropriate group) for script in list top; do + # bz2152970 is a known probem + [ "$ID" == "fedora" ] && [ "$script" == "top" ] && continue rlPhaseStartTest "Test $script" rlRun "rm -rf ~/.systemtap/cache" 0 "Cleaning cache" rlRun "stap $script.stp -v -c \"$PYTHON test.py\" > $script" \ diff --git a/tests/Regression/small-tests/main.fmf b/tests/Regression/small-tests/main.fmf index caa5060..1cad44e 100644 --- a/tests/Regression/small-tests/main.fmf +++ b/tests/Regression/small-tests/main.fmf @@ -9,7 +9,7 @@ recommend: - systemtap - systemtap-testsuite - perf -duration: 10m +duration: 100m extra-summary: /tools/systemtap/Regression/small-tests extra-task: /tools/systemtap/Regression/small-tests tier: 1 From 1c8c98dbcded78fbf127032200d06604da47d632 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Wed, 22 Feb 2023 09:48:52 +0100 Subject: [PATCH 022/101] CI testing: Drop the Regression/testsuite-upstream-raw TC --- .../testsuite-upstream-raw/check_BPF.sh | 158 ------ .../testsuite-upstream-raw/check_DEFAULT.sh | 55 --- .../dg-extract-results.sh | 453 ------------------ .../helpers/createreport.sh | 49 -- .../helpers/report-helper.sh | 130 ----- .../testsuite-upstream-raw/helpers/wikiup | 22 - .../internal-watchdog.sh | 21 - .../testsuite-upstream-raw/main.fmf | 50 -- .../testsuite-upstream-raw/runtest.sh | 282 ----------- .../testsuite-upstream-raw/stap-prep | 150 ------ 10 files changed, 1370 deletions(-) delete mode 100755 tests/Regression/testsuite-upstream-raw/check_BPF.sh delete mode 100755 tests/Regression/testsuite-upstream-raw/check_DEFAULT.sh delete mode 100755 tests/Regression/testsuite-upstream-raw/dg-extract-results.sh delete mode 100755 tests/Regression/testsuite-upstream-raw/helpers/createreport.sh delete mode 100755 tests/Regression/testsuite-upstream-raw/helpers/report-helper.sh delete mode 100755 tests/Regression/testsuite-upstream-raw/helpers/wikiup delete mode 100755 tests/Regression/testsuite-upstream-raw/internal-watchdog.sh delete mode 100644 tests/Regression/testsuite-upstream-raw/main.fmf delete mode 100755 tests/Regression/testsuite-upstream-raw/runtest.sh delete mode 100755 tests/Regression/testsuite-upstream-raw/stap-prep diff --git a/tests/Regression/testsuite-upstream-raw/check_BPF.sh b/tests/Regression/testsuite-upstream-raw/check_BPF.sh deleted file mode 100755 index 325b894..0000000 --- a/tests/Regression/testsuite-upstream-raw/check_BPF.sh +++ /dev/null @@ -1,158 +0,0 @@ -#!/bin/bash - -# Show the testcase list on demand. -if [[ "$1" == "TCLIST" ]]; then - if [[ "$(arch)" == "s390x" ]]; then - # Save the s390x machine time (regardless the rhel major): - # Almost all the testcases are failing there, and those, that - # do not, are flaky. - echo -n "notest.exp" - else - echo -n "bpf-asm.exp bpf.exp" - fi - exit 0 -fi - -_LOG=systemtap.check -cp systemtap.sum $_LOG - -_cleanup() -{ - rm $_LOG -} -trap _cleanup EXIT - -set -xe - -EXPECTED_PASSES_TRESHOLD=-1 - -if test $(rpm --eval '0%{rhel}') -eq 8; then - # systemtap-4.0-7.el8, kernel-4.18.0-64.el8 - case `arch` in - x86_64) - EXPECTED_PASSES_TRESHOLD=55 - sed -i '/FAIL: bigmap1.stp/d' $_LOG || : - sed -i '/FAIL: cast_op_tracepoint.stp/d' $_LOG || : - sed -i '/FAIL: logging1.stp/d' $_LOG || : - sed -i '/FAIL: perf1.stp/d' $_LOG || : - sed -i '/FAIL: pr23875_loop.stp/d' $_LOG || : - sed -i '/FAIL: pr23875_smash.stp/d' $_LOG || : - sed -i '/FAIL: reg_alloc3.stp/d' $_LOG || : - sed -i '/FAIL: string3.stp/d' $_LOG || : - sed -i '/FAIL: timer1.stp/d' $_LOG || : - sed -i '/FAIL: timer2.stp/d' $_LOG || : - sed -i '/FAIL: tracepoint1.stp/d' $_LOG || : - sed -i '/FAIL: tracepoint1.stp/d' $_LOG || : - ;; - aarch64) - EXPECTED_PASSES_TRESHOLD=58 - sed -i '/FAIL: bigmap1.stp/d' $_LOG || : - sed -i '/FAIL: logging1.stp/d' $_LOG || : - sed -i '/FAIL: perf1.stp/d' $_LOG || : - sed -i '/FAIL: perf2.stp/d' $_LOG || : - sed -i '/FAIL: pr23875_loop.stp/d' $_LOG || : - sed -i '/FAIL: pr23875_smash.stp/d' $_LOG || : - sed -i '/FAIL: reg_alloc3.stp/d' $_LOG || : - sed -i '/FAIL: string3.stp/d' $_LOG || : - sed -i '/FAIL: timer2.stp/d' $_LOG || : - sed -i '/FAIL: tracepoint1.stp/d' $_LOG || : - ;; - ppc64le) - EXPECTED_PASSES_TRESHOLD=53 - sed -i '/FAIL: array.stp/d' $_LOG || : - sed -i '/FAIL: array_preinit.stp/d' $_LOG || : - sed -i '/FAIL: context_vars1.stp/d' $_LOG || : - sed -i '/FAIL: context_vars2.stp/d' $_LOG || : - sed -i '/FAIL: context_vars2.stp/d' $_LOG || : - sed -i '/FAIL: context_vars3.stp/d' $_LOG || : - sed -i '/FAIL: globals2.stp/d' $_LOG || : - sed -i '/FAIL: globals3.stp/d' $_LOG || : - sed -i '/FAIL: kprobes.stp/d' $_LOG || : - sed -i '/FAIL: logging1.stp/d' $_LOG || : - sed -i '/FAIL: perf1.stp/d' $_LOG || : - sed -i '/FAIL: perf2.stp/d' $_LOG || : - sed -i '/FAIL: pr23875_loop.stp/d' $_LOG || : - sed -i '/FAIL: pr23875_loop.stp/d' $_LOG || : - sed -i '/FAIL: pr23875_smash.stp/d' $_LOG || : - sed -i '/FAIL: reg_alloc3.stp/d' $_LOG || : - sed -i '/FAIL: string3.stp/d' $_LOG || : - sed -i '/FAIL: timer2.stp/d' $_LOG || : - sed -i '/FAIL: tracepoint1.stp/d' $_LOG || : - ;; - s390x) - # Many testcases fail for s390x, many of them are flaky - # Not worth testing at all at this stage at all probably. - echo "INFO: UNSUPPORTED RHEL7 ARCHITECTIRE ($(arch))" - exit 0 - ;; - *) - echo "ERROR: UNSUPPORTED RHEL8 ARCHITECTIRE" - exit 1 - ;; - esac -elif test $(rpm --eval '0%{rhel}') -eq 7; then - case `arch` in - x86_64) - # (rhel7) systemtap-3.3-3.el7.x86_64, kernel-3.10.0-993.el7.x86_64 - if test $(rpm -q --queryformat='%{version}\n' kernel | awk -F. '{print $1}') -eq 3; then - EXPECTED_PASSES_TRESHOLD=32 - sed -i '/FAIL: cast_op_tracepoint.stp/d' $_LOG || : - sed -i '/FAIL: perf2.stp/d' $_LOG || : - sed -i '/FAIL: reg_alloc3.stp/d' $_LOG || : - sed -i '/FAIL: tracepoint1.stp/d' $_LOG || : - elif test $(rpm -q --queryformat='%{version}\n' kernel | awk -F. '{print $1}') -eq 4; then - # (rhel-alt-7) systemtap-3.3-3.el7.x86_64, kernel-4.14.0-115.el7a.x86_64 - echo "ERROR: known bug on rhel-alt ('map entry 0: Function not implemented')" - echo "<@fche> # CONFIG_BPF_SYSCALL is not set" - exit 0 - else - echo "ERROR: UNSUPPORTED RHEL7 KERNEL VERSION" - exit 1 - fi - ;; - *) - echo "INFO: UNSUPPORTED RHEL7 ARCHITECTIRE ($(arch))" - exit 0 - ;; - esac -elif test $(rpm --eval '0%{fedora}') -eq 29; then - case `arch` in - x86_64) - EXPECTED_PASSES_TRESHOLD=33 - sed -i '/FAIL: array.stp/d' $_LOG || : - sed -i '/FAIL: bigmap1.stp/d' $_LOG || : - sed -i '/FAIL: cast_op_tracepoint.stp/d' $_LOG || : - sed -i '/FAIL: no_end.stp/d' $_LOG || : - sed -i '/FAIL: printf.stp/d' $_LOG || : - sed -i '/FAIL: reg_alloc3.stp/d' $_LOG || : - sed -i '/FAIL: string1.stp/d' $_LOG || : - sed -i '/FAIL: timer2.stp/d' $_LOG || : - sed -i '/FAIL: tracepoint1.stp/d' $_LOG || : - ;; - *) - # No test results for other arches yet - true; - ;; - esac -else - echo "ERROR: UNSUPPORTED RHELMAJOR" - exit 1 -fi - -true _v_v_v_v_v_v_v_v_v_v_v_ UNEXPECTED FAILURES: _v_v_v_v_v_v_v_v_v_v_v_v_v_v_ -fgrep 'FAIL: ' $_LOG || : -true -^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^-^- - - -EXPECTED_PASSES=$(grep -a '^PASS: ' $_LOG | wc -l) -UNEXPECTED_FAILURES=$(grep -a '^FAIL: ' $_LOG | wc -l) - -test ${EXPECTED_PASSES_TRESHOLD} -gt 1 -test 0${EXPECTED_PASSES} -ge 0${EXPECTED_PASSES_TRESHOLD} -test 0${UNEXPECTED_FAILURES} -eq 0 - -rm $_LOG - -set +xe - - diff --git a/tests/Regression/testsuite-upstream-raw/check_DEFAULT.sh b/tests/Regression/testsuite-upstream-raw/check_DEFAULT.sh deleted file mode 100755 index ed0eea8..0000000 --- a/tests/Regression/testsuite-upstream-raw/check_DEFAULT.sh +++ /dev/null @@ -1,55 +0,0 @@ -#!/bin/bash - -if [[ "$1" == "TCLIST" ]]; then - # Empty list means to run all the testcases: - exit 0 -fi - -set -xe - -# It turns out that dg-extract-results.sh relies on the logfiles -# summary (# of expected passes, # of unexpected failures, etc.) and -# counts the summary values based on that. This is is okay for the -# normal dg-extract-results.sh use-case where it combines together -# correct (per single testcase) logs coming from parallel GDB testcase -# runs, where each of the input logfiles has such summary. -# -# But in our case we are combining incomplete log snippets coming from -# various terminated/incomplete/partial testsuite runs (kernel -# stall/crash, watchdog termination etc), where the log snippets do not -# have that summary (with an exception of the very last one). The -# result is that only the last of the log snippets gets properly -# counted, and the results from the other log snippets are ignored. -# -# rlRun "EXPECTED_PASSES=$(awk '/^# of expected passes/ {print $NF}' systemtap.sum)" -# rlRun "UNEXPECTED_FAILURES=$(awk '/^# of unexpected failures/ {print $NF}' systemtap.sum)" -# -# So we really need to count the PASSes and FAILs on our own: -# - -EXPECTED_PASSES=$(grep -a '^PASS: ' systemtap.sum | wc -l) -UNEXPECTED_FAILURES=$(grep -a '^FAIL: ' systemtap.sum | wc -l) - -# -# For this rough check, ignoring other states such as KFAIL and others -# should be good enough. - -case `arch` in - x86_64) - EXPECTED_PASSES_TRESHOLD=9000 - UNEXPECTED_FAILURES_TRESHOLD=800 - ;; - ppc64*) - EXPECTED_PASSES_TRESHOLD=8000 - UNEXPECTED_FAILURES_TRESHOLD=750 - ;; - *) - EXPECTED_PASSES_TRESHOLD=8000 - UNEXPECTED_FAILURES_TRESHOLD=500 - ;; -esac - -test 0${EXPECTED_PASSES} -ge 0${EXPECTED_PASSES_TRESHOLD} -test 0${UNEXPECTED_FAILURES} -le 0${UNEXPECTED_FAILURES_TRESHOLD} - -set +xe diff --git a/tests/Regression/testsuite-upstream-raw/dg-extract-results.sh b/tests/Regression/testsuite-upstream-raw/dg-extract-results.sh deleted file mode 100755 index ffea0a3..0000000 --- a/tests/Regression/testsuite-upstream-raw/dg-extract-results.sh +++ /dev/null @@ -1,453 +0,0 @@ -#! /bin/sh - -# For a specified tool and optional list of test variants, extract -# test results from one or more test summary (.sum) files and combine -# the results into a new test summary file, sent to the standard output. -# The resulting file can be used with test result comparison scripts for -# results from tests that were run in parallel. See usage() below. - -# Copyright (C) 2008-2016 Free Software Foundation, Inc. -# Contributed by Janis Johnson -# -# This file is part of GCC. -# -# GCC is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 3, or (at your option) -# any later version. -# -# GCC is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see . - -PROGNAME=dg-extract-results.sh - -# Try to use the python version if possible, since it tends to be faster. -PYTHON_VER=`echo "$0" | sed 's/sh$/py/'` -if test "$PYTHON_VER" != "$0" && - test -f "$PYTHON_VER" && - python -c 'import sys; sys.exit (0 if sys.version_info >= (2, 6) else 1)' \ - > /dev/null 2> /dev/null; then - exec python $PYTHON_VER "$@" -fi - -usage() { - cat <&2 -Usage: $PROGNAME [-t tool] [-l variant-list] [-L] sum-file ... - - tool The tool (e.g. g++, libffi) for which to create a - new test summary file. If not specified then all - specified sum files must be for the same tool. - variant-list One or more test variant names. If the list is - not specified then one is constructed from all - variants in the files for . - sum-file A test summary file with the format of those - created by runtest from DejaGnu. - If -L is used, merge *.log files instead of *.sum. In this - mode the exact order of lines may not be preserved, just different - Running *.exp chunks should be in correct order. -EOF -} - -# Write a message to the standard error. - -msg() { - echo "$@" >&2 -} - -# Parse the command-line options. - -VARIANTS="" -TOOL="" -MODE="sum" - -while getopts "l:t:L" ARG; do - case $ARG in - l) VARIANTS="${VARIANTS} ${OPTARG}";; - t) test -z "$TOOL" || (msg "${PROGNAME}: only one tool can be specified"; exit 1); - TOOL="${OPTARG}";; - L) MODE="log";; - \?) usage; exit 0;; - esac -done -shift `expr ${OPTIND} - 1` - -if test $# -lt 1 ; then - usage - exit 1 -fi - -TMPDIR=${TMPDIR-/tmp} -SUM_FILES="$@" -FIRST_SUM=$1 -TMP= -trap 'EXIT_STATUS=$?; rm -rf $TMP && exit $EXIT_STATUS' 0 -# Create a (secure) tmp directory for tmp files. -{ - TMP=`(umask 077 && mktemp -d -q "${TMPDIR}/dg-combine-results-$$-XXXXXX") 2>/dev/null` && - test -n "$TMP" && test -d "$TMP" -} || -{ - TMP=${TMPDIR}/dg-combine-results-$$-$RANDOM - (umask 077 && mkdir $TMP) -} || -{ - msg "${PROGNAME}: cannot create a temporary directory" - { (exit 1); exit 1; } -} - -# Find a good awk. - -if test -z "$AWK" ; then - for AWK in gawk nawk awk - do - if type $AWK 2>&1 | grep 'not found' > /dev/null 2>&1 ; then - : - else - break - fi - done -fi - -# Verify that the specified summary files exist. - -ERROR=0 -for FILE in $SUM_FILES -do - if ! test -f $FILE ; then - msg "${PROGNAME}: file $FILE does not exist." - ERROR=1 - fi -done -test $ERROR -eq 0 || exit 1 - -# Test if grep supports the '--text' option - -GREP=grep - -if echo -e '\x00foo\x00' | $GREP --text foo > /dev/null 2>&1 ; then - GREP="grep --text" -else - # Our grep does not recognize the '--text' option. We have to - # treat our files in order to remove any non-printable character. - for file in $SUM_FILES ; do - mv $file ${file}.orig - cat -v ${file}.orig > $file - done -fi - -if [ -z "$TOOL" ]; then - # If no tool was specified, all specified summary files must be for - # the same tool. - - CNT=`$GREP '=== .* tests ===' $SUM_FILES | $AWK '{ print $3 }' | sort -u | wc -l` - if [ $CNT -eq 1 ]; then - TOOL=`$GREP '=== .* tests ===' $FIRST_SUM | $AWK '{ print $2 }'` - else - msg "${PROGNAME}: sum files are for multiple tools, specify a tool" - msg "" - usage - exit 1 - fi -else - # Ignore the specified summary files that are not for this tool. This - # should keep the relevant files in the same order. - - SUM_FILES=`$GREP -l "=== $TOOL" $SUM_FILES` - if test -z "$SUM_FILES" ; then - msg "${PROGNAME}: none of the specified files are results for $TOOL" - exit 1 - fi -fi - -if [ "$TOOL" = acats ]; then - # Acats *.sum or *.log files aren't dejagnu generated, and they have - # somewhat different format. - ACATS_AWK=${TMP}/acats.awk - cat < $ACATS_AWK -BEGIN { - print_prologue=1; curfile=""; insummary=0 - passcnt=0; failcnt=0; unsupcnt=0; failures="" -} -/^[ \t]*=== acats configuration ===/ { - insummary=0 - if (print_prologue) print - next -} -/^[ \t]*=== acats tests ===/ { - if (print_prologue) print - print_prologue=0 - next -} -/^Running chapter / { - if (curfile) close (curfile) - curfile="${TMP}/chapter-"\$3 - print >> curfile - next -} -/^[ \t]*=== acats Summary ===/ { - if (curfile) close (curfile) - curfile="" - insummary=1 - next -} -/^# of expected passes/ { if (insummary == 1) passcnt += \$5; next; } -/^# of unexpected failures/ { if (insummary == 1) failcnt += \$5; next; } -/^# of unsupported tests/ { if (insummary == 1) unsupcnt += \$5; next; } -/^\*\*\* FAILURES: / { - if (insummary == 1) { - if (failures) sub(/^\*\*\* FAILURES:/,"") - failures=failures""\$0 - } -} -{ - if (print_prologue) { print; next } - if (curfile) print >> curfile -} -END { - system ("cat ${TMP}/chapter-*") - print " === acats Summary ===" - print "# of expected passes " passcnt - print "# of unexpected failures " failcnt - if (unsupcnt) print "# of unsupported tests " unsupcnt - if (failures) print failures -} -EOF - - rm -f ${TMP}/chapter-* - $AWK -f $ACATS_AWK $SUM_FILES - exit 0 -fi - -# If no variants were specified, find all variants in the remaining -# summary files. Otherwise, ignore specified variants that aren't in -# any of those summary files. - -if test -z "$VARIANTS" ; then - VAR_AWK=${TMP}/variants.awk - cat < $VAR_AWK -/^Schedule of variations:/ { in_vars=1; next } -/^$/ { in_vars=0 } -/^Running target/ { exit } -{ if (in_vars==1) print \$1; else next } -EOF - - touch ${TMP}/varlist - for FILE in $SUM_FILES; do - $AWK -f $VAR_AWK $FILE >> ${TMP}/varlist - done - VARIANTS="`sort -u ${TMP}/varlist`" -else - VARS="$VARIANTS" - VARIANTS="" - for VAR in $VARS - do - $GREP "Running target $VAR" $SUM_FILES > /dev/null && VARIANTS="$VARIANTS $VAR" - done -fi - -# Find out if we have more than one variant, or any at all. - -VARIANT_COUNT=0 -for VAR in $VARIANTS -do - VARIANT_COUNT=`expr $VARIANT_COUNT + 1` -done - -if test $VARIANT_COUNT -eq 0 ; then - msg "${PROGNAME}: no file for $TOOL has results for the specified variants" - exit 1 -fi - -cat $SUM_FILES \ - | $AWK '/^Running/ { if ($2 != "target" && $3 == "...") print "EXPFILE: "$2 } ' \ - | sort -u > ${TMP}/expfiles - -# Write the begining of the combined summary file. - -head -n 2 $FIRST_SUM -echo -echo " === $TOOL tests ===" -echo -echo "Schedule of variations:" -for VAR in $VARIANTS -do - echo " $VAR" -done -echo - -# For each test variant for the tool, copy test reports from each of the -# summary files. Set up two awk scripts from within the loop to -# initialize VAR and TOOL with the script, rather than assuming that the -# available version of awk can pass variables from the command line. - -for VAR in $VARIANTS -do - GUTS_AWK=${TMP}/guts.awk - cat << EOF > $GUTS_AWK -BEGIN { - variant="$VAR" - firstvar=1 - expfileno=1 - cnt=0 - print_using=0 - need_close=0 -} -/^EXPFILE: / { - expfiles[expfileno] = \$2 - expfilesr[\$2] = expfileno - expfileno = expfileno + 1 -} -/^Running target / { - curvar = \$3 - if (variant == curvar && firstvar == 1) { print; print_using=1; firstvar = 0 } - next -} -/^Using / { - if (variant == curvar && print_using) { print; next } -} -/^Running .*\\.exp \\.\\.\\./ { - print_using=0 - if (variant == curvar) { - if (need_close) close(curfile) - curfile="${TMP}/list"expfilesr[\$2] - expfileseen[\$2]=expfileseen[\$2] + 1 - need_close=0 - testname="00" - next - } -} -/^\t\t=== .* ===$/ { curvar = ""; next } -/^(PASS|XPASS|FAIL|XFAIL|UNRESOLVED|WARNING|ERROR|UNSUPPORTED|UNTESTED|KFAIL):/ { - testname=\$2 - # Ugly hack for gfortran.dg/dg.exp - if ("$TOOL" == "gfortran" && testname ~ /^gfortran.dg\/g77\//) - testname="h"testname -} -/^$/ { if ("$MODE" == "sum") next } -{ if (variant == curvar && curfile) { - if ("$MODE" == "sum") { - printf "%s %08d|", testname, cnt >> curfile - cnt = cnt + 1 - } - filewritten[curfile]=1 - need_close=1 - print >> curfile - } else - next -} -END { - n=1 - while (n < expfileno) { - if (expfileseen[expfiles[n]]) { - print "Running "expfiles[n]" ..." - if (filewritten["${TMP}/list"n]) { - if (expfileseen[expfiles[n]] == 1) - cmd="cat" - else - cmd="LC_ALL=C sort" - if ("$MODE" == "sum") - system (cmd" ${TMP}/list"n" | sed -n 's/^[^ ]* [^ |]*|//p'") - else - system ("cat ${TMP}/list"n) - } - } - n = n + 1 - } -} -EOF - - SUMS_AWK=${TMP}/sums.awk - rm -f $SUMS_AWK - cat << EOF > $SUMS_AWK -BEGIN { - variant="$VAR" - tool="$TOOL" - passcnt=0; failcnt=0; untstcnt=0; xpasscnt=0; xfailcnt=0; kpasscnt=0; kfailcnt=0; unsupcnt=0; unrescnt=0; - curvar=""; insummary=0 -} -/^Running target / { curvar = \$3; next } -/^# of / { if (variant == curvar) insummary = 1 } -/^# of expected passes/ { if (insummary == 1) passcnt += \$5; next; } -/^# of unexpected successes/ { if (insummary == 1) xpasscnt += \$5; next; } -/^# of unexpected failures/ { if (insummary == 1) failcnt += \$5; next; } -/^# of expected failures/ { if (insummary == 1) xfailcnt += \$5; next; } -/^# of unknown successes/ { if (insummary == 1) kpasscnt += \$5; next; } -/^# of known failures/ { if (insummary == 1) kfailcnt += \$5; next; } -/^# of untested testcases/ { if (insummary == 1) untstcnt += \$5; next; } -/^# of unresolved testcases/ { if (insummary == 1) unrescnt += \$5; next; } -/^# of unsupported tests/ { if (insummary == 1) unsupcnt += \$5; next; } -/^$/ { if (insummary == 1) - { insummary = 0; curvar = "" } - next - } -{ next } -END { - printf ("\t\t=== %s Summary for %s ===\n\n", tool, variant) - if (passcnt != 0) printf ("# of expected passes\t\t%d\n", passcnt) - if (failcnt != 0) printf ("# of unexpected failures\t%d\n", failcnt) - if (xpasscnt != 0) printf ("# of unexpected successes\t%d\n", xpasscnt) - if (xfailcnt != 0) printf ("# of expected failures\t\t%d\n", xfailcnt) - if (kpasscnt != 0) printf ("# of unknown successes\t\t%d\n", kpasscnt) - if (kfailcnt != 0) printf ("# of known failures\t\t%d\n", kfailcnt) - if (untstcnt != 0) printf ("# of untested testcases\t\t%d\n", untstcnt) - if (unrescnt != 0) printf ("# of unresolved testcases\t%d\n", unrescnt) - if (unsupcnt != 0) printf ("# of unsupported tests\t\t%d\n", unsupcnt) -} -EOF - - PVAR=`echo $VAR | sed 's,/,.,g'` - TMPFILE=${TMP}/var-$PVAR - rm -f $TMPFILE - rm -f ${TMP}/list* - cat ${TMP}/expfiles $SUM_FILES | $AWK -f $GUTS_AWK - cat $SUM_FILES | $AWK -f $SUMS_AWK > $TMPFILE - # If there are multiple variants, output the counts for this one; - # otherwise there will just be the final counts at the end. - test $VARIANT_COUNT -eq 1 || cat $TMPFILE -done - -# Set up an awk script to get the combined summary counts for the tool. - -TOTAL_AWK=${TMP}/total.awk -cat << EOF > $TOTAL_AWK -BEGIN { - tool="$TOOL" - passcnt=0; failcnt=0; untstcnt=0; xpasscnt=0; xfailcnt=0; kfailcnt=0; unsupcnt=0; unrescnt=0 -} -/^# of expected passes/ { passcnt += \$5 } -/^# of unexpected failures/ { failcnt += \$5 } -/^# of unexpected successes/ { xpasscnt += \$5 } -/^# of expected failures/ { xfailcnt += \$5 } -/^# of unknown successes/ { kpasscnt += \$5 } -/^# of known failures/ { kfailcnt += \$5 } -/^# of untested testcases/ { untstcnt += \$5 } -/^# of unresolved testcases/ { unrescnt += \$5 } -/^# of unsupported tests/ { unsupcnt += \$5 } -END { - printf ("\n\t\t=== %s Summary ===\n\n", tool) - if (passcnt != 0) printf ("# of expected passes\t\t%d\n", passcnt) - if (failcnt != 0) printf ("# of unexpected failures\t%d\n", failcnt) - if (xpasscnt != 0) printf ("# of unexpected successes\t%d\n", xpasscnt) - if (xfailcnt != 0) printf ("# of expected failures\t\t%d\n", xfailcnt) - if (kpasscnt != 0) printf ("# of unknown successes\t\t%d\n", kpasscnt) - if (kfailcnt != 0) printf ("# of known failures\t\t%d\n", kfailcnt) - if (untstcnt != 0) printf ("# of untested testcases\t\t%d\n", untstcnt) - if (unrescnt != 0) printf ("# of unresolved testcases\t%d\n", unrescnt) - if (unsupcnt != 0) printf ("# of unsupported tests\t\t%d\n", unsupcnt) -} -EOF - -# Find the total summaries for the tool and add to the end of the output. -cat ${TMP}/var-* | $AWK -f $TOTAL_AWK - -# This is ugly, but if there's version output from the compiler under test -# at the end of the file, we want it. The other thing that might be there -# is the final summary counts. -tail -2 $FIRST_SUM | $GREP '^#' > /dev/null || tail -2 $FIRST_SUM - -exit 0 diff --git a/tests/Regression/testsuite-upstream-raw/helpers/createreport.sh b/tests/Regression/testsuite-upstream-raw/helpers/createreport.sh deleted file mode 100755 index 49180ac..0000000 --- a/tests/Regression/testsuite-upstream-raw/helpers/createreport.sh +++ /dev/null @@ -1,49 +0,0 @@ -#!/bin/bash - -TEMPDIR=$( mktemp -d ) -ORIGPWD=$( pwd ) - -cp /mnt/scratch/mcermak/testlogs/systemtap.upstream/*tar.xz $TEMPDIR/ - - -pushd $TEMPDIR || exit 1 - -# rename files so that identical commit hashes get identical (lowest possible) timestamp for sorting purposes -HASHES=$(ls systemtap*mcermak*tar.xz | awk -F\. '{print $4}' | sort -u) -for h in $HASHES; do - echo Processing hash $h - MINSTAMP4HASH=$( ls *$h* | tr '-' '.' | awk -F\. '{print $9}' | sort -n | grep '[0-9]\+' | head -n 1 ) - echo Min stamp for hash is: $MINSTAMP4HASH - PKG4HASH=$( ls *$h* ) - for p in $PKG4HASH; do - echo Processing pkg $p - PKGSTAMP=$( echo $p | tr '-' '.' | awk -F\. '{print $9}' ) - rename 'systemtap' "$MINSTAMP4HASH" $p - done -done - -# extract systemtap.sum files and rename them -for f in $( ls *tar.xz ); do - tar xJf $f systemtap.sum - mv systemtap.sum $f.sum - rename 'tar.xz.sum' 'log' $f.sum -done - -sh $ORIGPWD/report-helper.sh | tee wiki.out - -sed -i 's/UNKNOWN/?/g' wiki.out -sed -i 's/UNTESTED/-/g' wiki.out -sed -i 's/PASS/P/g' wiki.out -sed -i 's/FAIL/F/g' wiki.out -sed -i 's/ERROR/E/g' wiki.out - - -echo uploading logs to scratch... -OUT=/mnt/scratch/mcermak/testlogs/out -rm -rf $OUT && mkdir -p $OUT && chmod a+rwx $OUT && cp -v *tar.xz $OUT/ - -echo uploading to wiki... -cat wiki.out | $ORIGPWD/wikiup 'mcermak/systemtap.upstream' - -popd # $TEMPDIR -rm -rf $TEMPDIR diff --git a/tests/Regression/testsuite-upstream-raw/helpers/report-helper.sh b/tests/Regression/testsuite-upstream-raw/helpers/report-helper.sh deleted file mode 100755 index 1297045..0000000 --- a/tests/Regression/testsuite-upstream-raw/helpers/report-helper.sh +++ /dev/null @@ -1,130 +0,0 @@ -#!/bin/bash - -HASHES=$( ls | awk -F\. '{print $4}' | sort -u ) -ARCHES=$( ls *log | awk -F- '{print $(NF-1) }' | awk -F. '{print $NF}' | sort -u ) - -declare -A MAXTESTS - -for p in $HASHES; do - MAXTESTS[$p]=0 - for a in $ARCHES; do - c=$( ls *log | grep $p | grep $a | wc -l ) - test $c -gt ${MAXTESTS[$p]} && MAXTESTS[$p]=$c - done -done - -TESTCASES=$( cat *log | awk '/^Running\ \.\/systemtap/ {print $2}' | sort -u ) - -TEMPFILE=$( mktemp ) - -function getCaseResults() { - casename=$1 - logfile=$2 - casename=$( echo $casename | tr "/" "." ) - cmd="cat $logfile | sed -e '/$casename/,/^Running/ !d'" - eval "$cmd" | head -n -1 -} - -function getWorstResult() { - results="$1" - retval='UNKNOWN' - echo "$results" | grep -q '^PASS' && retval='PASS' - echo "$results" | grep -q '^KPASS' && retval='KPASS' - echo "$results" | grep -q '^XPASS' && retval='XPASS' - echo "$results" | grep -q '^UNTESTED' && retval='UNTESTED' - echo "$results" | grep -q '^KFAIL' && retval='KFAIL' - echo "$results" | grep -q '^XFAIL' && retval='XFAIL' - echo "$results" | grep -q '^FAIL' && retval='FAIL' - echo "$results" | grep -q '^ERROR' && retval='ERROR' - echo $retval -} - -function getResult() { - casename=$1 - logfile=$2 - worstResult=$( getWorstResult "$( getCaseResults "$casename" "$logfile" )" ) - if test -s $logfile; then - loglink="http://nfs.englab.brq.redhat.com/scratch/mcermak/testlogs/out/$( echo $logfile | sed 's/log/tar\.xz/' )" - echo "[[$loglink|$worstResult]]" - else - echo $worstResult - fi -} - -function getLogs() { - package=$1 - arch=$2 - logcnt=$3 - availogcont=$( ls *log | grep $package | grep $arch | wc -l ) - remainlogcnt=$(( $logcnt - $availogcont )) - logs=$( ls *log | grep $package | grep $arch ) - for i in $( seq 1 $remainlogcnt ); do - logs="$logs $TEMPFILE" - done - echo $logs -} - -function colorizeResult() { - result=$1 - if echo $result | egrep -q '(KFAIL|XFAIL)'; then - echo "<#a2eea2> $result" - elif echo $result | egrep -q '(FAIL|ERROR)'; then - echo "<#f30000> $result" - elif echo $result | egrep -q '(UNKNOWN)'; then - echo "<#ffffff> $result" - else - echo "<#a2eea2> $result" - fi -} - -function getResultSet() { - package=$1 - arch=$2 - testcase=$3 - #echo -n "|| $package ($arch) " - echo -n "|| '''$arch''' " - for logfile in $( getLogs "$package" "$arch" ${MAXTESTS[$package]} ); do - result=$( getResult "$testcase" "$logfile" ) - echo -n "||$( colorizeResult "$result" ) " - done -} - -function getBugsForTestcase() { - testcase=$1 - testcase=$( echo $testcase | sed 's/^\.\///' | tr "/" "." ) - cmd="awk '/$testcase/ {print \$2}' bugs.txt" - eval "$cmd" -} - -function getBugLinksForTestcase() { - bznos="$1" - if ! test -z "$bznos"; then - echo - for bzno in $bznos; do - echo -e "[[https://bugzilla.redhat.com/show_bug.cgi?id=$bzno|bz$bzno]]" - done - echo - fi -} - -echo -n "== " -first=1 -for package in $HASHES; do - test $first -eq 0 && echo -n "<-> " - echo -n "$package " - first=0 -done -echo " ==" - -for testcase in $TESTCASES; do - echo -e "\n=== $testcase ===\n" - getBugLinksForTestcase "$( getBugsForTestcase "$testcase" )" - for arch in $ARCHES; do - for __hash in $HASHES; do - getResultSet $__hash $arch $testcase - done - echo " ||" - done -done - - diff --git a/tests/Regression/testsuite-upstream-raw/helpers/wikiup b/tests/Regression/testsuite-upstream-raw/helpers/wikiup deleted file mode 100755 index f703910..0000000 --- a/tests/Regression/testsuite-upstream-raw/helpers/wikiup +++ /dev/null @@ -1,22 +0,0 @@ -#!/usr/bin/python - -import sys -import xmlrpclib - -wikilocation = sys.argv[1] -wikicontent = sys.stdin.read() - -if not wikilocation.startswith("mcermak/"): - print "wiki location must start with mcermak/" - sys.exit(1) - -user = 'xmlrpc2' -password = 'fo0m4nchU+' -url='http://wiki.test.redhat.com/' -wiki = xmlrpclib.ServerProxy(url + '?action=xmlrpc2', allow_none=False) -auth_token = wiki.getAuthToken(user, password) -mc = xmlrpclib.MultiCall(wiki) -mc.applyAuthToken(auth_token) -mc.putPage(wikilocation, wikicontent) -result = mc() - diff --git a/tests/Regression/testsuite-upstream-raw/internal-watchdog.sh b/tests/Regression/testsuite-upstream-raw/internal-watchdog.sh deleted file mode 100755 index f977337..0000000 --- a/tests/Regression/testsuite-upstream-raw/internal-watchdog.sh +++ /dev/null @@ -1,21 +0,0 @@ -#/bin/bash - -test -x -__TRESHOLD=$(( 240 * 60 )) -__SLEEP=$(( 15 * 60 )) -__LOG="$1" -test -z $__LOG && exit 1 -test +x - -echo "`date` internal watchdog $$ starting." >> $__LOG -while true; do - sleep $__SLEEP - __DELTA=$(( `date +'%s'` - `stat -c '%Y' $__LOG` )) - if [[ $__DELTA -gt $__TRESHOLD ]]; then - echo "`date` internal watchdog $$ rebooting due to inactivity." >> $__LOG - sync - sleep 1m - reboot -f - sleep 5m - fi -done diff --git a/tests/Regression/testsuite-upstream-raw/main.fmf b/tests/Regression/testsuite-upstream-raw/main.fmf deleted file mode 100644 index 883d060..0000000 --- a/tests/Regression/testsuite-upstream-raw/main.fmf +++ /dev/null @@ -1,50 +0,0 @@ -summary: testsuite-upstream-raw -description: '' -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -# test: /bin/true -framework: beakerlib -recommend: - - avahi-debuginfo - - avahi-devel - - boost-devel - - byteman - - coreutils - - coreutils-debuginfo - - crash-devel - - dejagnu - - '@development' - - '@development-tools' - - dyninst-devel - - elfutils-devel - - gcc-c++ - - gettext-devel - - git - - glibc-debuginfo - - glibc-devel - - libselinux-devel - - libstdc++-devel - - m4 - - nss-devel - - pkgconfig - - postgresql-debuginfo - - postgresql-server - - python - - python3-debuginfo - - python-debuginfo - - python-libs-debuginfo - - rpm-devel - - sqlite-devel - - systemtap - - systemtap-testsuite - - tcl - - xz - - zlib-devel - - sqlite - - systemtap-debuginfo - - kernel-headers -duration: 72h -extra-summary: /tools/systemtap/Regression/testsuite-upstream-raw -extra-task: /tools/systemtap/Regression/testsuite-upstream-raw diff --git a/tests/Regression/testsuite-upstream-raw/runtest.sh b/tests/Regression/testsuite-upstream-raw/runtest.sh deleted file mode 100755 index 6b9a1b0..0000000 --- a/tests/Regression/testsuite-upstream-raw/runtest.sh +++ /dev/null @@ -1,282 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/testsuite-upstream-raw -# Description: testsuite-upstream-raw -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2014 Red Hat, Inc. -# -# This program is free software: you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 2 of -# the License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see http://www.gnu.org/licenses/. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -# What part of the testsuite should we run (and then check for errors)? -_WHAT=${_WHAT:-DEFAULT} - -export AVC_ERROR='+no_avc_check' -touch /tmp/disable-qe-abrt - -unset DEBUGINFOD_PROGRESS -if test $(rpm --eval "0%{rhel}") -ge 9; then - # Allow use of debuginfod - export DEBUGINFOD_URLS=http://debuginfod.usersys.redhat.com:3632/ - # export DEBUGINFOD_PROGRESS=1 -else - unset DEBUGINFOD_URLS -fi - -trap '' SIGHUP SIGINT SIGQUIT SIGABRT - -ORIGPWD=$( pwd ) - -PKGMGR="yum --skip-broken --nogpgcheck" -rpm -q dnf && PKGMGR="dnf --setopt=strict=0 --nogpgcheck" - -STARTDATE=$(date +%Y-%m-%d-%H-%M-%S) -STAPSRPM=$(rpm -qif `which stap` | awk '/Source RPM/ {print $NF}' | sort -u | sed 's/\.src\.rpm//') -SUITERPM=$(rpm --queryformat '%{name}\n' -qf `which stap` | grep -o '.*systemtap' | sort -u)-testsuite -SUITELOC=$(rpm -ql $SUITERPM | grep -o '.*systemtap\/testsuite/' | sort -u) - -test_primary_arch_only () -{ - echo "=== TESTING PRIMARY ARCH ONLY ===" - sed -i '/^proc arch_compile_flags/,/^}/d' $SUITELOC/lib/compile_flags.exp - echo 'proc arch_compile_flags {} { return 1 }' >> $SUITELOC/lib/compile_flags.exp -} - -# For devtoolset, compat arch support was dropped for non-x86_64 arches. Ref: bz1493500 -if echo $SUITELOC | grep -q toolset && arch | egrep -q '^(ppc64|s390x)$'; then - test_primary_arch_only -elif test $(rpm -E '0%{rhel}') -ge 8 -a "$(arch)" != "x86_64"; then - test_primary_arch_only -fi - -# Currently the Makefile overrides what was set in the env via -# http://pkgs.devel.redhat.com/cgit/rpms/devtoolset-7/commit/?h=devtoolset-7.1-rhel-7&id=e305f5912a13bd2ca04ac319afca50bfab6f4aea -# And actually if the base rhel dyninst is installed, the dts testsuite runs against it rather than agains -# the dts-stap - producing irrelevant test results. -# -# A real fix on the stap side might be: -# -LD_LIBRARY_PATH=$(DESTDIR)$(libdir)/systemtap -# +LD_LIBRARY_PATH=$(DESTDIR)$(libdir)/systemtap:$(DESTDIR)$(libdir)/dyninst -# in the Makefile.am etc, but let's work this around for now in a way that we simply use the -# LD_LIBRARY_PATH taken directly from the env: -if echo $SUITELOC | grep -q toolset; then - sed -i 's/^LD_LIBRARY_PATH/# LD_LIBRARY_PATH/' $SUITELOC/Makefile -fi - -rlJournalStart - rlPhaseStartSetup - rlLogInfo "SUITERPM=$SUITERPM" - rlLogInfo "SUITELOC=$SUITELOC" - rlRun "pushd $SUITELOC" - rlServiceStop firewalld - rlServiceStop iptables - rlServiceStop ip6tables - rlServiceStart avahi-daemon - rlRun "rpm -qa | grep ^kernel | grep -v `uname -r` | xargs rpm -e --nodeps" 0-255 - # if ! (uname -r | fgrep -q '.rt'); then - # rlRun "$ORIGPWD/stap-prep" 0,127 || \ - # rlRun "stap-prep" 0,127 - # fi - rlRun "sysctl -w kernel.panic=1" - rlRun "sysctl -w kernel.panic_on_oops=1" - rlRun "$PKGMGR -y install --setopt=multilib_policy=all libstdc++ dejagnu elfutils-devel gettext libgcc glibc-devel gcc-c++ libstdc++-devel dyninst dyninst-devel" - rlPhaseEnd - - - MYDMESGDIR=/root/mydmesg - mkdir -p $MYDMESGDIR - if strings $(which dmesg) | fgrep -q -- '-w'; then - rlPhaseStart FAIL "Run dmesg recorder." - MYTIMESTAMP=$(date +%s) - dmesg -wH > $MYDMESGDIR/dmesg$MYTIMESTAMP & - MYDMESGPID=$! - rlLogInfo "Dmesg recorder file: $MYDMESGDIR/dmesg$MYTIMESTAMP" - rlLogInfo "Dmesg PID: $MYDMESGPID" - rlPhaseEnd - fi - - rlPhaseStart FAIL "sanity check" - rlRun "stap -vve 'probe kernel.function(\"vfs_read\"){ log(\"hey!\"); exit() } probe timer.s(60){log(\"timeout\"); exit()}'" - rlRun "stap -vvl 'process(\"/usr/sbin/fdisk\").function(\"main\")'" 0-255 - rlPhaseEnd - - if ! test -f $SUITELOC/systemtap.log; then - rlPhaseStart WARN "Apply blacklist" - # === RHEL7 === - if rlIsRHEL 7; then - if arch | grep -q s390; then - true - # PR17270 - #rlRun "rm -f systemtap.onthefly/hrtimer_onthefly.exp" - #rlRun "rm -f systemtap.onthefly/uprobes_onthefly.exp" - #rlRun "rm -f systemtap.onthefly/kprobes_onthefly.exp" - # PR17140 - #rlRun "rm -f systemtap.examples/profiling/functioncallcount.stp" - elif arch | grep -q ppc; then - true - # PR17270 - #rlRun "rm -f systemtap.onthefly/hrtimer_onthefly.exp" - #rlRun "rm -f systemtap.onthefly/uprobes_onthefly.exp" - #rlRun "rm -f systemtap.onthefly/kprobes_onthefly.exp" - # PR17126 - #rlRun "rm -f systemtap.base/tracepoints.exp" - # BZ1153082 - #rlRun "rm -f systemtap.clone/main_quiesce.exp" - #elif rpm -q systemtap | grep -q '2.4-16.el7_0'; then - # BZ1145958 - #rlRun "rm -f systemtap.base/process_resume.exp" - fi - # === FEDORA === - elif grep -qi fedora /etc/redhat-release; then - # BZ1153082 - rlRun "rm -f systemtap.clone/main_quiesce.exp" - fi - - # Work around problem fixed in https://sourceware.org/git/gitweb.cgi?p=systemtap.git;a=commitdiff;h=a9b0aa4dbd1aa7a1c36eba8102e1445e8f2eb8b8 - rlRun "sed -i 's/exit\ 0/return/' $(fgrep -ril 'exit 0' $(find . -type f -name '*.exp')) ||:" - rlPhaseEnd - else - rlPhaseStart FAIL "Post-process anticipated reboot" - # Sometimes the testsuite crashes the kernel or causes stall. - # In case --ignore-panic is set, the box gets rebooted (bz1155644). - # This shouldn't happen. It'd be nice to report it as FAIL, but that - # appears to be too pedantic. We'll need this bell to ring when - # too many unexpected failures get reported by the upstream test driver. - # rlRun "false" - - # Remove testcases that have already been run - for tc in $( awk '/^Running.*exp\ \.\.\.$/ {print $2}' *systemtap.log ); do - echo $tc | grep -q 'systemtap/notest.exp' && continue - test -f $tc && rm -f $tc && rlLog "Removed $tc" - done - - #generate random hash - HASH=$(date | md5sum | cut -c 1-32 -) - - # save existing logs before creating new ones - rlRun "mv systemtap.log ${HASH}-systemtap.log" - rlRun "mv systemtap.sum ${HASH}-systemtap.sum" - - # clean up garbage incl. systemtap.log - rlRun "make clean" - rlPhaseEnd - fi - - rlPhaseStartTest - # Start internal watchdog if running in beaker - if test -n $JOBID; then - rlLogInfo "Starting internal watchdog ..." - $ORIGPWD/internal-watchdog.sh "$SUITELOC/systemtap.sum" & - __WATCHDOG_PID=$! - sleep 3 - if ps -p $__WATCHDOG_PID; then - rlLogInfo "Internal watchdog running (pid $__WATCHDOG_PID)." - else - rlFail "Problem starting the internal watchdog." - fi - fi - - # The _WHAT env var allows the test to only run selected subset of all - # the tests and perform specific checks on the resulting logs. - # - # Accepted values: BPF - - # run the testsuite (grab the list of testcases from the respective check* file) - TESTCASES=$(bash ${ORIGPWD}/check_${_WHAT}.sh TCLIST) - rlRun "make RUNTESTFLAGS='$TESTCASES' installcheck 2>&1" - - # Kill internal watchdog if running in beaker - if ! test -z $JOBID; then - rlLogInfo "Killing internal watchdog ..." - kill -s TERM $__WATCHDOG_PID - fi - rlPhaseEnd - - rlPhaseStart FAIL "Put all the log fragments together" - rlRun "$ORIGPWD/dg-extract-results.sh *systemtap.sum > big-systemtap.sum" - rlRun "$ORIGPWD/dg-extract-results.sh -L *systemtap.log > big-systemtap.log" - rlRun "mv --force big-systemtap.sum systemtap.sum" - rlRun "mv --force big-systemtap.log systemtap.log" - # remove the hash-prefixed fragments - # these are needed for the resume mode, but since we got to this point, - # we most likely processed all the testcases somehow, put all the pieces - # together and can start cleaning up and reporting - rlRun "rm -f *-systemtap.{log,sum}" - rlPhaseEnd - - rlPhaseStart FAIL "rlFileSubmit logs" - rlRun "xz --keep --force systemtap.log" - rlFileSubmit "systemtap.log.xz" - rlRun "xz --keep --force systemtap.sum" - rlFileSubmit "systemtap.sum.xz" - rlRun "rm systemtap.log.xz systemtap.sum.xz" - rlPhaseEnd - - if [[ "$_WHAT" == "DEFAULT" ]]; then - rlPhaseStart FAIL "save logs to /mnt/scratch" - MP=$( mktemp -d ) - # Refer to /tools/systemtap/Install/upstream-head - SD=rhpkg; rpm -q systemtap | grep -q mcermak && SD=upstream - rlRun "echo ${BEAKER}jobs/${JOBID} > job.txt" - rlRun "tar cf mydmesg.tar $MYDMESGDIR" - rlRun "xz mydmesg.tar" - rlRun "mount -o rw,nolock nfs.englab.brq.redhat.com:/scratch/mcermak $MP" - if test $(rpm --eval '0%{rhel}') -eq 8 && (! echo ${STAPSRPM} | grep '\.el8'); then - rlRun "LOGNAME=${MP}/testlogs/systemtap.${SD}/${STAPSRPM}.el8.$(uname -m)-${STARTDATE}" - else - rlRun "LOGNAME=${MP}/testlogs/systemtap.${SD}/${STAPSRPM}.$(uname -m)-${STARTDATE}" - fi - rlRun "mkdir -p $( dirname $LOGNAME )" - rlRun "tar cJf ${LOGNAME}.tar.xz systemtap.log systemtap.sum job.txt mydmesg.tar.xz" - - # Upload logs to bunsen instance on tofan if running in beaker - if ! test -z $JOBID; then - LOGFULLNAME="${LOGNAME}.tar.xz" - LOGBASENAME="$(basename $LOGFULLNAME)" - rlLogInfo "Uploading test log to bunsen..." - rlRun "cat $LOGFULLNAME | \ - curl -X POST -F project=systemtap-qe \ - -F tarballname=$LOGBASENAME \ - -F 'tar=@-' \ - http://tofan.yyz.redhat.com:8013/bunsen-upload.py" - fi - rlRun "umount -l $MP && sleep 3 && rm -rf $MP" - rlPhaseEnd - fi - - rlPhaseStart FAIL "Log checks ($_WHAT)" - rlRun "bash ${ORIGPWD}/check_${_WHAT}.sh" - rlPhaseEnd - - rlPhaseStartCleanup - rlServiceRestore firewalld - rlServiceRestore iptables - rlServiceRestore ip6tables - rlServiceRestore avahi-daemon - rlRun popd - kill -9 $MYDMESGPID ||: - rlPhaseEnd -rlJournalPrintText -rlJournalEnd - -rm -f /tmp/disable-qe-abrt diff --git a/tests/Regression/testsuite-upstream-raw/stap-prep b/tests/Regression/testsuite-upstream-raw/stap-prep deleted file mode 100755 index 89b7c3c..0000000 --- a/tests/Regression/testsuite-upstream-raw/stap-prep +++ /dev/null @@ -1,150 +0,0 @@ -#! /bin/bash -LANG=C; export LANG -PATH=/usr/sbin:/sbin:/usr/bin:/bin:$PATH; export PATH - -check_error() { if test $1 != 0; then printf "\n$2\n"; exit $1; fi } - -prep_rpm_based() { -# uname -r can produce different kinds of output: -# 2.6.32-30.el6.x86_64 (no variant, but including ".arch") -# 2.6.18-194.3.1.el5debug ("variant", without dot, no arch) -# 2.6.33.4-95.fc13.i686.PAE (".arch.variant", two dots) -# 3.18.6-100.fc20.i686+PAE (".arch+variant", dot, plus) -if [ "$#" -lt 1 ]; then - UNAME=`uname -r` # determine the kernel running on the machine -else - UNAME=$1 #user passed in uname value -fi -UNAME=`echo $UNAME | sed "s/ //"` #strip out any whitespace -KERNEL="kernel" -for VARIANT in debug kdump PAE xen; do - # strip out ".variant" or else "+variant" or else "variant" at end. - TMP=`echo $UNAME | sed "s/[\.\+]\?$VARIANT\$//"` - if [ "$TMP" != "$UNAME" ]; then - UNAME=$TMP; KERNEL="kernel-$VARIANT" - fi -done -KERN_ARCH=`uname -m` -KERN_REV=`echo $UNAME | sed s/.$KERN_ARCH//` # strip arch from uname -if [ -x /usr/bin/dnf ]; then - DI="dnf debuginfo-install" - DI_DEPS="" - D="dnf" -else - DI="debuginfo-install" - DI_DEPS="yum-utils" - D="yum" -fi -CANDIDATES="$KERNEL-$KERN_REV.$KERN_ARCH \ - $KERNEL-devel-$KERN_REV.$KERN_ARCH \ - $DI_DEPS" - -# Can't simply work with /boot/vmlinuz-* below because of -# https://sourceware.org/bugzilla/show_bug.cgi?id=26599 -_debuginfod_file=$(rpm -ql kernel-core | fgrep $(uname -r) | grep '\.so$' | tail -1) -# Now let's assume following to come from outside env... -# export DEBUGINFOD_URLS=http://debuginfod.usersys.redhat.com:3632/ -# export DEBUGINFOD_PROGRESS=1 -debuginfod-find debuginfo $(rpm -ql kernel-core | fgrep $(uname -r) | grep '\.so$' | tail -1) || \ - CANDIDATES="$CANDIDATES $KERNEL-debuginfo-$KERN_REV.$KERN_ARCH" - -NEEDED=`rpm --qf "%{name}-%{version}-%{release}.%{arch}\n" \ - -q $CANDIDATES | grep "is not installed" | awk '{print $2}'` -if [ "$NEEDED" != "" ]; then - echo -e "Need to install the following packages:\n$NEEDED" - if [ `id -u` = "0" ]; then #attempt to install - $D install -y --enablerepo=\* $NEEDED - if expr "$NEEDED" : ".*debuginfo.*" >/dev/null; - then - $DI -y $KERNEL-$KERN_REV.$KERN_ARCH; - fi - rpm -q $NEEDED - rc=$? - check_error $rc "problem installing rpm(s) $NEEDED\nin case of file conflicts, try again after # $D erase $KERNEL-debuginfo" - fi -fi -} - -prep_deb_based() { -if [ $# -ne 0 ]; then - echo "Specifying kernel version is not yet support on deb based systems." 1>&2 - exit 1 -fi - -# 2.6.32-5-amd64 -# 2.6.32-37-generic -ABINAME="$(cut -d " " -f 3 /proc/version)" - -# 2.6.32 -BASEVERSION="$(echo "$ABINAME" | cut -d "-" -f 1)" -DEBIAN_FRONTEND=noninteractive # don't confirm or chat -export DEBIAN_FRONTEND - -case "$DISTRO" in - Debian) # 2.6.32-39 - if uname -v | grep -q Debian; then - VERSION="$(uname -v | cut -d " " -f 4)" - else - VERSION="$(cut -d " " -f 3 /proc/version)" - fi - ;; - Ubuntu) - # 2.6.32-37.81 - if [ -f /proc/version_signature ]; then - VERSION="$(cut -d " " -f 2 /proc/version_signature | cut -d "-" -f 1-2)" - else # 4.18 - VERSION="$(cut -d " " -f 3 /proc/version)" - fi - ;; -esac - -( - echo "make >= 0" - echo "linux-image-$ABINAME = $VERSION" - echo "linux-headers-$ABINAME = $VERSION" - echo "linux-image-$ABINAME-dbgsym = $VERSION" -) | while read package relation requiredversion; do - installedversion="$(dpkg-query -W "$package" 2> /dev/null | cut -f 2)" - if [ "$installedversion" = "" ]; then - availableversion="$(apt-cache show $package 2> /dev/null | grep ^Version: | cut -d " " -f 2)" - if [ "$availableversion" = "" -a "$(echo $package | grep dbgsym$)" ]; then - echo "You need package $package but it does not seem to be available" - if [ "$DISTRO" = "Ubuntu" ]; then - echo " Ubuntu -dbgsym packages are typically in a separate repository" - echo " Follow https://wiki.ubuntu.com/DebuggingProgramCrash to add this repository" - elif [ "$DISTRO" = "Debian" ]; then - echo " Debian -dbgsym packages are typically in a separate repository" - echo " Follow https://wiki.debian.org/AutomaticDebugPackages to add this repository" - fi - else - echo "Need to install $package" - if [ `id -u` = "0" ]; then #attempt to install - apt-get -y install $package - fi - fi - elif ! dpkg --compare-versions $installedversion $relation $requiredversion; then - echo "Package $package version $installedversion does not match version of currently running kernel: $requiredversion" - echo " Consider apt-get upgrade && reboot" - fi -done - -user="$(id --user --name)" -if [ "$user" != "root" ]; then - groups="$(id --groups --name)" - for i in stapusr stapdev; do - if [ "$(echo $groups | grep $i)" = "" ]; then - echo "Be root or adduser $user $i" - fi - done -fi -} - -DISTRO="$(lsb_release --id --short 2> /dev/null)" -case "$DISTRO" in -Debian|Ubuntu) - prep_deb_based "$@" - ;; -*) - prep_rpm_based "$@" - ;; -esac From 340640bc27872968082a90f76fdb49f82b801c54 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Thu, 23 Feb 2023 16:37:59 -0500 Subject: [PATCH 023/101] rhbz2173032 --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index 003149f..340791f 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -122,7 +122,7 @@ m stapdev stapdev Name: systemtap Version: 4.8 -Release: 4%{?release_override}%{?dist} +Release: 5%{?release_override}%{?dist} # for version, see also configure.ac @@ -1298,6 +1298,9 @@ exit 0 # PRERELEASE %changelog +* Thu Feb 23 2023 Frank Ch. Eigler - 4.8-5 +- Rebuilt for Dyninst update + * Mon Feb 20 2023 Jonathan Wakely - 4.8-4 - Rebuilt for Boost 1.81 From 8ea2489c531cd529bb0bba3d948e39ffbade36c8 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Fri, 10 Mar 2023 15:27:23 +0100 Subject: [PATCH 024/101] CI Testing: Extend test coverage on Fedora Enable most of the tests on Fedora. Port some of them to Fedora. Annotate expected failures with respective bugzilla IDs. --- tests/Regression/PR16166/main.fmf | 1 + .../golden.fc39.out | 153 +++++++++++++++ .../RHEL6Feature-cpp-backtraces/main.fmf | 1 + .../RHEL6Feature-cpp-backtraces/runtest.sh | 5 + .../RHEL6Feature-cpp-ctors-and-dtors/main.fmf | 1 + .../RHEL6Feature-cpp-inheritance/main.fmf | 1 + .../RHEL6Feature-cpp-methods/main.fmf | 1 + .../main.fmf | 1 + .../bz544960-no-cfa_ops-supplied/runtest.sh | 1 + .../bz706185-various-build-and-run/main.fmf | 1 + .../main.fmf | 1 + .../main.fmf | 1 + .../main.fmf | 1 + tests/Regression/ipv6-tapset-support/main.fmf | 1 + .../Regression/ipv6-tapset-support/runtest.sh | 1 + .../irq-vector-tracepoints/main.fmf | 1 + tests/Regression/netdev-receive/main.fmf | 1 + tests/Regression/netdev-receive/runtest.sh | 2 +- .../main.fmf | 1 + .../second-command-not-captured/main.fmf | 1 + .../main.fmf | 23 --- .../runtest.sh | 184 ------------------ .../main.fmf | 1 + .../semantic-errors-bz1062076/main.fmf | 1 + .../semantic-errors-bz1062076/runtest.sh | 3 +- .../semantic-errors-bz953776/main.fmf | 1 + .../main.fmf | 1 + .../main.fmf | 1 + .../Regression/suspicious-RCU-usage/main.fmf | 1 + .../main.fmf | 1 + .../main.fmf | 1 + .../main.fmf | 1 + .../utrace-taskfinder-misses-events/main.fmf | 1 + .../main.fmf | 1 + .../runtest.sh | 7 +- .../testpro/test-for-nfs | 50 ++--- .../byteman-java-methods-probing/main.fmf | 1 + tests/Sanity/kernel-modules/main.fmf | 1 + tests/Sanity/quick-smoke-test/main.fmf | 1 + .../Sanity/stap-server-basic-sanity/main.fmf | 1 + tests/Sanity/userspace-probes/main.fmf | 1 + 41 files changed, 212 insertions(+), 248 deletions(-) create mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/golden.fc39.out delete mode 100644 tests/Regression/selected-parts-of-upstream-testsuite/main.fmf delete mode 100755 tests/Regression/selected-parts-of-upstream-testsuite/runtest.sh diff --git a/tests/Regression/PR16166/main.fmf b/tests/Regression/PR16166/main.fmf index 9a85d18..091d481 100644 --- a/tests/Regression/PR16166/main.fmf +++ b/tests/Regression/PR16166/main.fmf @@ -14,3 +14,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1054962 extra-summary: /tools/systemtap/Regression/PR16166 extra-task: /tools/systemtap/Regression/PR16166 +tier: 1 diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.fc39.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.fc39.out new file mode 100644 index 0000000..ac8d8c9 --- /dev/null +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.fc39.out @@ -0,0 +1,153 @@ +publicB1 +privateB1 +publicA1 +publicA2 +privateA1 +privateA2 +recursiveA1: 3 +recursiveA1: 2 +recursiveA1: 1 +recursiveA1: 0 +================================================================================ +Probed function: [main] + +Backtrace: + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicB1] + +Backtrace: + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateB1] + +Backtrace: + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicA1] + +Backtrace: + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [publicA2] + +Backtrace: + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateA1] + +Backtrace: + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [privateA2] + +Backtrace: + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] +================================================================================ +Probed function: [recursiveA1] + +Backtrace: + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] + ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] + ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] + ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] + ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] + ADDRESS : main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] + ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] + ADDRESS : _start+ADDRESS/ADDRESS [PATH] diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf b/tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf index 3600214..7b71ea0 100644 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf @@ -12,3 +12,4 @@ recommend: duration: 10m extra-summary: /tools/systemtap/Regression/RHEL6Feature-cpp-backtraces extra-task: /tools/systemtap/Regression/RHEL6Feature-cpp-backtraces +tier: 1 diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/runtest.sh b/tests/Regression/RHEL6Feature-cpp-backtraces/runtest.sh index eddbc83..a2ad6bc 100755 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/runtest.sh +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/runtest.sh @@ -28,6 +28,7 @@ # Include rhts environment . /usr/share/beakerlib/beakerlib.sh || exit 1 +. /etc/os-release || exit 1 PACKAGE="systemtap" @@ -79,6 +80,10 @@ rlPhaseStartTest rlRun "cat golden.el9.`arch`.out > golden.out" fi + if [ "$ID" == "fedora" ] && test "0$VERSION_ID" -ge 39; then + rlRun "cat golden.fc39.out > golden.out" + fi + # RHEL-9 s390x runtime/stack-s390.c:63:52: error: ‘ASYNC_SIZE’ undeclared # (PAGE_SIZE << 1) on stap side seems to work it around diff --git a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/main.fmf b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/main.fmf index ba18df9..880faad 100644 --- a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/main.fmf +++ b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/main.fmf @@ -11,3 +11,4 @@ recommend: duration: 5m extra-summary: /tools/systemtap/Regression/RHEL6Feature-cpp-ctors-and-dtors extra-task: /tools/systemtap/Regression/RHEL6Feature-cpp-ctors-and-dtors +tier: 1 diff --git a/tests/Regression/RHEL6Feature-cpp-inheritance/main.fmf b/tests/Regression/RHEL6Feature-cpp-inheritance/main.fmf index dba249b..901d4da 100644 --- a/tests/Regression/RHEL6Feature-cpp-inheritance/main.fmf +++ b/tests/Regression/RHEL6Feature-cpp-inheritance/main.fmf @@ -11,3 +11,4 @@ recommend: duration: 10m extra-summary: /tools/systemtap/Regression/RHEL6Feature-cpp-inheritance extra-task: /tools/systemtap/Regression/RHEL6Feature-cpp-inheritance +tier: 1 diff --git a/tests/Regression/RHEL6Feature-cpp-methods/main.fmf b/tests/Regression/RHEL6Feature-cpp-methods/main.fmf index 56ac081..6e00402 100644 --- a/tests/Regression/RHEL6Feature-cpp-methods/main.fmf +++ b/tests/Regression/RHEL6Feature-cpp-methods/main.fmf @@ -11,3 +11,4 @@ recommend: duration: 120m extra-summary: /tools/systemtap/Regression/RHEL6Feature-cpp-methods extra-task: /tools/systemtap/Regression/RHEL6Feature-cpp-methods +tier: 1 diff --git a/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/main.fmf b/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/main.fmf index 33847c6..5e7923c 100644 --- a/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/main.fmf +++ b/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/main.fmf @@ -12,3 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1572501 extra-summary: /tools/systemtap/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap extra-task: /tools/systemtap/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap +tier: 1 diff --git a/tests/Regression/bz544960-no-cfa_ops-supplied/runtest.sh b/tests/Regression/bz544960-no-cfa_ops-supplied/runtest.sh index 4be6581..9b31b30 100755 --- a/tests/Regression/bz544960-no-cfa_ops-supplied/runtest.sh +++ b/tests/Regression/bz544960-no-cfa_ops-supplied/runtest.sh @@ -29,6 +29,7 @@ # Include Beaker environment . /usr/share/beakerlib/beakerlib.sh || exit 1 + PACKAGE="systemtap" _SCRIPTS="readpages.stp tcp.sendmsg.stp bdflush.stp" diff --git a/tests/Regression/bz706185-various-build-and-run/main.fmf b/tests/Regression/bz706185-various-build-and-run/main.fmf index 3d6770a..0e61577 100644 --- a/tests/Regression/bz706185-various-build-and-run/main.fmf +++ b/tests/Regression/bz706185-various-build-and-run/main.fmf @@ -13,3 +13,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=706185 extra-summary: /tools/systemtap/Regression/bz706185-various-build-and-run extra-task: /tools/systemtap/Regression/bz706185-various-build-and-run +tier: 1 diff --git a/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/main.fmf b/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/main.fmf index 05c4212..ec48caf 100644 --- a/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/main.fmf +++ b/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/main.fmf @@ -13,3 +13,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=902739 extra-summary: /tools/systemtap/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code extra-task: /tools/systemtap/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code +tier: 1 diff --git a/tests/Regression/elfutils-debuginfod-client-not-being-called/main.fmf b/tests/Regression/elfutils-debuginfod-client-not-being-called/main.fmf index 2ae6333..4d69c02 100644 --- a/tests/Regression/elfutils-debuginfod-client-not-being-called/main.fmf +++ b/tests/Regression/elfutils-debuginfod-client-not-being-called/main.fmf @@ -12,3 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1778921 extra-summary: /tools/systemtap/Regression/elfutils-debuginfod-client-not-being-called extra-task: /tools/systemtap/Regression/elfutils-debuginfod-client-not-being-called +tier: 1 diff --git a/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/main.fmf b/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/main.fmf index 96bcab2..371094d 100644 --- a/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/main.fmf +++ b/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/main.fmf @@ -12,3 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1810216 extra-summary: /tools/systemtap/Regression/ftrace-logging-tapset-not-working-as-expected-in extra-task: /tools/systemtap/Regression/ftrace-logging-tapset-not-working-as-expected-in +tier: 1 diff --git a/tests/Regression/ipv6-tapset-support/main.fmf b/tests/Regression/ipv6-tapset-support/main.fmf index 9d08d89..48a9775 100644 --- a/tests/Regression/ipv6-tapset-support/main.fmf +++ b/tests/Regression/ipv6-tapset-support/main.fmf @@ -14,3 +14,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=822503 extra-summary: /tools/systemtap/Regression/ipv6-tapset-support extra-task: /tools/systemtap/Regression/ipv6-tapset-support +tier: 1 diff --git a/tests/Regression/ipv6-tapset-support/runtest.sh b/tests/Regression/ipv6-tapset-support/runtest.sh index 62fa775..5e8fb68 100755 --- a/tests/Regression/ipv6-tapset-support/runtest.sh +++ b/tests/Regression/ipv6-tapset-support/runtest.sh @@ -31,6 +31,7 @@ rlJournalStart rlPhaseStartSetup + rlLogInfo "Related bugs: Fedora rawhide 6.2.0-0.rc8.57.fc39.x86_64 bz2177192" rlAssertRpm nfs-utils rlRun "uname -r" rlRun "which stap" diff --git a/tests/Regression/irq-vector-tracepoints/main.fmf b/tests/Regression/irq-vector-tracepoints/main.fmf index c9ec663..ff8a2c0 100644 --- a/tests/Regression/irq-vector-tracepoints/main.fmf +++ b/tests/Regression/irq-vector-tracepoints/main.fmf @@ -13,3 +13,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1020437 extra-summary: /tools/systemtap/Regression/irq-vector-tracepoints extra-task: /tools/systemtap/Regression/irq-vector-tracepoints +tier: 1 diff --git a/tests/Regression/netdev-receive/main.fmf b/tests/Regression/netdev-receive/main.fmf index 78ec038..f0e45d8 100644 --- a/tests/Regression/netdev-receive/main.fmf +++ b/tests/Regression/netdev-receive/main.fmf @@ -12,3 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1518462 extra-summary: /tools/systemtap/Regression/netdev-receive extra-task: /tools/systemtap/Regression/netdev-receive +tier: 1 diff --git a/tests/Regression/netdev-receive/runtest.sh b/tests/Regression/netdev-receive/runtest.sh index b184941..8495626 100755 --- a/tests/Regression/netdev-receive/runtest.sh +++ b/tests/Regression/netdev-receive/runtest.sh @@ -35,7 +35,7 @@ rlJournalStart rlPhaseStartTest # Here we rely on that netdev.receive gets hit immediately without us explicitly triggering it. # Not all rhel-7 stap versions have -T already, so we use -E instead. - rlRun "stap -o $TMPFILE -ve 'probe netdev.receive{log(\"HIT\") exit()}' -E 'probe timer.s(10) {log(\"TIMEOUT\") exit()}'" + rlRun "stap -o $TMPFILE -ve 'probe netdev.receive{log(\"HIT\") exit()}' -E 'probe timer.s(30) {log(\"TIMEOUT\") exit()}'" rlRun "cat $TMPFILE" rlRun "grep HIT $TMPFILE" rlRun "grep TIMEOUT $TMPFILE" 1 diff --git a/tests/Regression/pass-4-failure-netfilter-examples/main.fmf b/tests/Regression/pass-4-failure-netfilter-examples/main.fmf index 5244e99..4501cf6 100644 --- a/tests/Regression/pass-4-failure-netfilter-examples/main.fmf +++ b/tests/Regression/pass-4-failure-netfilter-examples/main.fmf @@ -14,3 +14,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1055778 extra-summary: /tools/systemtap/Regression/pass-4-failure-netfilter-examples extra-task: /tools/systemtap/Regression/pass-4-failure-netfilter-examples +tier: 1 diff --git a/tests/Regression/second-command-not-captured/main.fmf b/tests/Regression/second-command-not-captured/main.fmf index 7b88ecc..5659f4b 100644 --- a/tests/Regression/second-command-not-captured/main.fmf +++ b/tests/Regression/second-command-not-captured/main.fmf @@ -14,3 +14,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1857749 extra-summary: /tools/systemtap/Regression/second-command-not-captured extra-task: /tools/systemtap/Regression/second-command-not-captured +tier: 1 diff --git a/tests/Regression/selected-parts-of-upstream-testsuite/main.fmf b/tests/Regression/selected-parts-of-upstream-testsuite/main.fmf deleted file mode 100644 index a1d57ec..0000000 --- a/tests/Regression/selected-parts-of-upstream-testsuite/main.fmf +++ /dev/null @@ -1,23 +0,0 @@ -summary: selected-parts-of-upstream-testsuite -description: '' -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap - - libstdc++ - - dejagnu - - elfutils-devel - - gettext - - libgcc - - glibc-devel - - gcc-c++ - - libstdc++-devel - - dyninst - - dyninst-devel - - systemtap-testsuite -duration: 48h -extra-summary: /tools/systemtap/Regression/selected-parts-of-upstream-testsuite -extra-task: /tools/systemtap/Regression/selected-parts-of-upstream-testsuite diff --git a/tests/Regression/selected-parts-of-upstream-testsuite/runtest.sh b/tests/Regression/selected-parts-of-upstream-testsuite/runtest.sh deleted file mode 100755 index 7c2882b..0000000 --- a/tests/Regression/selected-parts-of-upstream-testsuite/runtest.sh +++ /dev/null @@ -1,184 +0,0 @@ -#!/bin/bash -# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/selected-parts-of-upstream-testsuite -# Description: selected-parts-of-upstream-testsuite -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2017 Red Hat, Inc. -# -# This program is free software: you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 2 of -# the License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see http://www.gnu.org/licenses/. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Be tolerant about selinux -export AVC_ERROR='+no_avc_check' - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -DMESG1=$(mktemp) -DMESG2=$(mktemp) - -PACKAGE="systemtap" - -SUBTESTS="\ -attach_detach.exp \ -bz1126645.exp \ -bz1214176.exp \ -bz1252436.exp \ -exelib.exp \ -pr22005.exp \ -server.exp \ -systemtap-service.exp \ -task_dentry_path.exp \ -task_paths.exp \ -tracepoints.exp \ -" - -blacklist_subtest() -{ - token=${1/\//\\/} - SUBTESTS=${SUBTESTS/$token/} -} - -P4TESTS="\ -buildok/nfs-all-probes.stp \ -buildok/nfs-detailed.stp \ -buildok/nfs-fop.check_flags.stp \ -buildok/nfs_proc-detailed.stp \ -buildok/nfsd-all-probes.stp \ -buildok/nfsd-detailed.stp \ -systemtap.examples/io/nfs_func_users.stp \ -systemtap.examples/network/nfsdtop.stp \ -" - -blacklist_p4() -{ - token=${1/\//\\/} - P4TESTS=${P4TESTS/$token/} -} - -if [[ $(rpm --eval '%{rhel}') -ge 8 ]]; then - # mjw authored that testcase - had been notified - arch | fgrep 'x86_64' && blacklist_subtest 'exelib.exp' - - blacklist_p4 'buildok/nfs-fop.check_flags.stp' - blacklist_p4 'buildok/nfs_proc-detailed.stp' - blacklist_p4 'buildok/nfsd-detailed.stp' - # bz1709831 - blacklist_p4 'buildok/nfs-detailed.stp' - arch | fgrep -q ppc64le && blacklist_p4 'buildok/nfs-all-probes.stp' -elif [[ $(rpm --eval '%{rhel}') -eq 7 ]]; then - # RHEL-ALT - if rpm -qi kernel | fgrep -q kernel-alt; then - # at_var.exp is expected to fail on Pegas - https://bugzilla.redhat.com/show_bug.cgi?id=1165848#c7 - blacklist_subtest 'at_var.exp' - fi - - # bz1107616, bz1698737 - blacklist_p4 'buildok/nfsd-detailed.stp' - if arch | fgrep -q ppc64le; then - blacklist_p4 'buildok/nfs-all-probes.stp' - blacklist_p4 'buildok/nfs-detailed.stp' - blacklist_p4 'buildok/nfsd-all-probes.stp' - fi -elif [[ $(rpm --eval '%{rhel}') -le 6 ]]; then - true -fi - -which stap | fgrep -q toolset && blacklist_subtest 'modules_out_of_tree.exp' - -rlJournalStart - rlPhaseStartSetup - TESTSUITERPM="$(rpm --queryformat='%{name}\n' -qf $(which stap) | head -1 | grep -o '.*systemtap')-testsuite" - rlLogInfo "$(rpm -q $TESTSUITERPM)" - TESTSUITEDIR="$(rpm -ql $TESTSUITERPM | grep -o '.*share/systemtap/testsuite/' | head -1)" - rlLogInfo "$TESTSUITEDIR" - - # For devtoolset, compat arch support was dropped for non-x86_64 arches. Ref: bz1493500 - if echo $TESTSUITEDIR | grep -q toolset && arch | egrep -q '^(ppc64|s390x)$'; then - sed -i '/^proc arch_compile_flags/,/^}/d' $TESTSUITEDIR/lib/compile_flags.exp - echo 'proc arch_compile_flags {} { return 1 }' >> $TESTSUITEDIR/lib/compile_flags.exp - fi - - # Need to suppress warnings so that task_dentry_path.exp can pass - # And --skip-badvars to let task_paths.exp pass - rlRun "sed -i 's/--rlimit-cpu=850/-w --skip-badvars \0/' $TESTSUITEDIR/lib/systemtap.exp" - - rlServiceStop firewalld - rlServiceStop iptables - rlServiceStop ip6tables - rlServiceStart avahi-daemon - rlRun "rpm -qa | grep ^kernel | grep -v `uname -r` | xargs rpm -e" 0-255 - rlRun "stap-prep" 0,127 - PKGMGR="yum --skip-broken --nogpgcheck" - rpm -q dnf && PKGMGR="dnf --setopt=strict=0 --nogpgcheck" - rlRun "$PKGMGR -y install --setopt=multilib_policy=all libstdc++ dejagnu elfutils-devel gettext libgcc glibc-devel gcc-c++ libstdc++-devel dyninst dyninst-devel" - rlRun "sysctl -w kernel.panic=1" - rlRun "sysctl -w kernel.panic_on_oops=1" - rlPhaseEnd - - rlPhaseStartTest - rlRun "cd $TESTSUITEDIR" - rlRun "make clean" - rlRun "dmesg > $DMESG1" - rlRun "make installcheck RUNTESTFLAGS=\"${RUNTESTFLAGS:-$SUBTESTS}\"" - rlRun "dmesg > $DMESG2" - rlLogInfo "$SUBTESTS" - rlDejaSum "systemtap.sum" - rlFileSubmit "systemtap.log" - rlFileSubmit "systemtap.sum" - rlPhaseEnd - - rlPhaseStart FAIL "Run selected -p4 tests" - for t in $P4TESTS; do - rlLogInfo "Trying to compile $t without prologue search ..." - ADDSWITCHES='' - stap $ADDSWITCHES -w -o /dev/null -p4 $t || ADDSWITCHES='-P' - rlRun "stap $ADDSWITCHES -w -p4 $t" - done - rlPhaseEnd - - rlPhaseStart FAIL "Check for BUG: in dmesg" - rlRun "diff $DMESG1 $DMESG2" 0-255 - rlRun "diff $DMESG1 $DMESG2 | grep 'BUG:'" 1 - rlPhaseEnd - - rlPhaseStart FAIL "Evaluate test results" - TEMPLOG=$(mktemp) - rlRun "cp systemtap.sum $TEMPLOG" - # BLACKLIST - if which stap | grep -q toolset; then - rlLogInfo "Ignore boot time probing subtest FAILures per bz1121363#c20 for devtoolset" - sed -i '/^FAIL: stap-service::boot probing - install script/d' $TEMPLOG - sed -i '/^FAIL: stap-service::boot probing - check script/d' $TEMPLOG - fi - # check for failures - rlRun "grep ^PASS $TEMPLOG" 0 "Assert a/some PASS" - rlRun "grep ^FAIL $TEMPLOG" 1 "Assert no FAIL" - rm -f $TEMPLOG - rlPhaseEnd - - rlPhaseStartCleanup - rlServiceRestore firewalld - rlServiceRestore iptables - rlServiceRestore ip6tables - rlServiceRestore avahi-daemon - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/semantic-error-nfs-proc-read_setup/main.fmf b/tests/Regression/semantic-error-nfs-proc-read_setup/main.fmf index 72489b4..264e6e0 100644 --- a/tests/Regression/semantic-error-nfs-proc-read_setup/main.fmf +++ b/tests/Regression/semantic-error-nfs-proc-read_setup/main.fmf @@ -12,3 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=884951 extra-summary: /tools/systemtap/Regression/semantic-error-nfs-proc-read_setup extra-task: /tools/systemtap/Regression/semantic-error-nfs-proc-read_setup +tier: 1 diff --git a/tests/Regression/semantic-errors-bz1062076/main.fmf b/tests/Regression/semantic-errors-bz1062076/main.fmf index ca70df0..4bf64fd 100644 --- a/tests/Regression/semantic-errors-bz1062076/main.fmf +++ b/tests/Regression/semantic-errors-bz1062076/main.fmf @@ -12,3 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1062076 extra-summary: /tools/systemtap/Regression/semantic-errors-bz1062076 extra-task: /tools/systemtap/Regression/semantic-errors-bz1062076 +tier: 1 diff --git a/tests/Regression/semantic-errors-bz1062076/runtest.sh b/tests/Regression/semantic-errors-bz1062076/runtest.sh index 3f53859..bd89675 100755 --- a/tests/Regression/semantic-errors-bz1062076/runtest.sh +++ b/tests/Regression/semantic-errors-bz1062076/runtest.sh @@ -31,9 +31,10 @@ rlJournalStart rlPhaseStartTest + rlLogInfo "Related bugs: Fedora rawhide 6.2.0-0.rc8.57.fc39.x86_64 bz2177196" rlLogInfo "Check if we might want to try out prologue search" p="" - stap -vp4 sript.stp >& /dev/null || p="-P" + stap -vp4 script.stp >& /dev/null || p="-P" rlRun "stap $p -vp4 script.stp" rlPhaseEnd rlJournalPrintText diff --git a/tests/Regression/semantic-errors-bz953776/main.fmf b/tests/Regression/semantic-errors-bz953776/main.fmf index c95eaee..6b7baa3 100644 --- a/tests/Regression/semantic-errors-bz953776/main.fmf +++ b/tests/Regression/semantic-errors-bz953776/main.fmf @@ -15,3 +15,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=953776 extra-summary: /tools/systemtap/Regression/semantic-errors-bz953776 extra-task: /tools/systemtap/Regression/semantic-errors-bz953776 +tier: 1 diff --git a/tests/Regression/stap-ERROR-Build-id-mismatch-with/main.fmf b/tests/Regression/stap-ERROR-Build-id-mismatch-with/main.fmf index 6744a8d..6e8560b 100644 --- a/tests/Regression/stap-ERROR-Build-id-mismatch-with/main.fmf +++ b/tests/Regression/stap-ERROR-Build-id-mismatch-with/main.fmf @@ -12,3 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1566422 extra-summary: /tools/systemtap/Regression/stap-ERROR-Build-id-mismatch-with extra-task: /tools/systemtap/Regression/stap-ERROR-Build-id-mismatch-with +tier: 1 diff --git a/tests/Regression/stapio-possible-circular-locking-dependency/main.fmf b/tests/Regression/stapio-possible-circular-locking-dependency/main.fmf index c1bafab..9f075f8 100644 --- a/tests/Regression/stapio-possible-circular-locking-dependency/main.fmf +++ b/tests/Regression/stapio-possible-circular-locking-dependency/main.fmf @@ -13,3 +13,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1020207 extra-summary: /tools/systemtap/Regression/stapio-possible-circular-locking-dependency extra-task: /tools/systemtap/Regression/stapio-possible-circular-locking-dependency +tier: 1 diff --git a/tests/Regression/suspicious-RCU-usage/main.fmf b/tests/Regression/suspicious-RCU-usage/main.fmf index 5e9c792..ce7a968 100644 --- a/tests/Regression/suspicious-RCU-usage/main.fmf +++ b/tests/Regression/suspicious-RCU-usage/main.fmf @@ -12,3 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1788662 extra-summary: /tools/systemtap/Regression/suspicious-RCU-usage extra-task: /tools/systemtap/Regression/suspicious-RCU-usage +tier: 1 diff --git a/tests/Regression/syscall-get-arguments-returning-wrong-value/main.fmf b/tests/Regression/syscall-get-arguments-returning-wrong-value/main.fmf index da42eb6..1199de4 100644 --- a/tests/Regression/syscall-get-arguments-returning-wrong-value/main.fmf +++ b/tests/Regression/syscall-get-arguments-returning-wrong-value/main.fmf @@ -13,3 +13,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1004059 extra-summary: /tools/systemtap/Regression/syscall-get-arguments-returning-wrong-value extra-task: /tools/systemtap/Regression/syscall-get-arguments-returning-wrong-value +tier: 1 diff --git a/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/main.fmf b/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/main.fmf index 97ec25b..835c151 100644 --- a/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/main.fmf +++ b/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/main.fmf @@ -12,3 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1412691 extra-summary: /tools/systemtap/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak extra-task: /tools/systemtap/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak +tier: 1 diff --git a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/main.fmf b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/main.fmf index 547e173..ff05762 100644 --- a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/main.fmf +++ b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/main.fmf @@ -12,3 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1430861 extra-summary: /tools/systemtap/Regression/task-exe-file-results-in-an-file-struct-leak extra-task: /tools/systemtap/Regression/task-exe-file-results-in-an-file-struct-leak +tier: 1 diff --git a/tests/Regression/utrace-taskfinder-misses-events/main.fmf b/tests/Regression/utrace-taskfinder-misses-events/main.fmf index b5af125..48771c2 100644 --- a/tests/Regression/utrace-taskfinder-misses-events/main.fmf +++ b/tests/Regression/utrace-taskfinder-misses-events/main.fmf @@ -14,3 +14,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=876848 extra-summary: /tools/systemtap/Regression/utrace-taskfinder-misses-events extra-task: /tools/systemtap/Regression/utrace-taskfinder-misses-events +tier: 1 diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/main.fmf b/tests/Regression/wrong-data-returned-by-nfs-commit-done/main.fmf index c4d5b52..fc2f518 100644 --- a/tests/Regression/wrong-data-returned-by-nfs-commit-done/main.fmf +++ b/tests/Regression/wrong-data-returned-by-nfs-commit-done/main.fmf @@ -12,3 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=920444 extra-summary: /tools/systemtap/Regression/wrong-data-returned-by-nfs-commit-done extra-task: /tools/systemtap/Regression/wrong-data-returned-by-nfs-commit-done +tier: 1 diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/runtest.sh b/tests/Regression/wrong-data-returned-by-nfs-commit-done/runtest.sh index 105b8b7..5543268 100755 --- a/tests/Regression/wrong-data-returned-by-nfs-commit-done/runtest.sh +++ b/tests/Regression/wrong-data-returned-by-nfs-commit-done/runtest.sh @@ -28,6 +28,7 @@ # Include Beaker environment . /usr/share/beakerlib/beakerlib.sh || exit 1 +. /etc/os-release || exit 1 PACKAGE="systemtap" @@ -47,9 +48,7 @@ rlJournalStart rlPhaseStart FAIL "Build testing binary, prepare nfs environment" rlRun "make" - rlRun "rhelmajor=$(rpm --eval %{rhel})" - rlRun "chmod u+x test-for-nfs" - rlRun "./test-for-nfs RHEL${rhelmajor}" + rlRun "./test-for-nfs" rlPhaseEnd rlPhaseStartTest @@ -62,7 +61,7 @@ rlJournalStart rlPhaseEnd rlPhaseStart WARN "Clean the nfs environment up" - rlRun "./test-for-nfs -c RHEL${rhelmajor}" + rlRun "./test-for-nfs -c" rlPhaseEnd rlPhaseStartCleanup diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/test-for-nfs b/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/test-for-nfs index 156831d..95579bc 100755 --- a/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/test-for-nfs +++ b/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/test-for-nfs @@ -8,11 +8,6 @@ nfs_service() local status="$1" local OS_VER="$2" - if [[ "$OS_VER" != "RHEL9" && "$OS_VER" != "RHEL8" && "$OS_VER" != "RHEL7" && "$OS_VER" != "RHEL6" && "$OS_VER" != "RHEL5" ]]; then - echo "Error: $OS_VER not supported." - return 1 - fi - case "$status" in restart) ps -ef | grep "nfsd" | grep -v grep > /dev/null 2>&1 @@ -21,22 +16,12 @@ nfs_service() return 0 fi - if [[ "$2" == "RHEL7" || "$2" == "RHEL8" || "$2" == "RHEL9" ]]; then - /bin/systemctl restart nfs-server.service - ret=$? - else - /etc/init.d/nfs restart - ret=$? - fi + /bin/systemctl restart nfs-server.service + ret=$? ;; stop) - if [[ "$2" == "RHEL7" || "$2" == "RHEL8" || "$2" == "RHEL9" ]]; then - /bin/systemctl stop nfs-server.service - ret=$? - else - /etc/init.d/nfs stop - ret=$? - fi + /bin/systemctl stop nfs-server.service + ret=$? ;; *) echo "Error: nfs_service [stop|restart]" @@ -52,7 +37,7 @@ clean_nfs_env() umount "$NFS_TMP"/sts_mount /usr/sbin/exportfs -u 127.0.0.1:"$NFS_TMP"/sts_share rm -rf "$NFS_TMP" - nfs_service stop $1 + nfs_service stop if [ $? -ne 0 ]; then return 1 else @@ -63,7 +48,7 @@ clean_nfs_env() create_nfs_env() { - nfs_service restart $1 + nfs_service restart if [ $? -ne 0 ]; then return 1 fi @@ -80,31 +65,26 @@ create_nfs_env() } if [ $# -gt 2 ]; then - echo "Usage: test-for-nfs [-c] OS_VERSION" + echo "Usage: test-for-nfs [-c]" exit 1 fi case "$1" in -c) - clean_nfs_env $2 + clean_nfs_env ret=$? if [ $ret -ne 0 ]; then echo "Error: cleaning the nfs env for test failed." fi ;; *) - if [ ! -z "$1" ]; then - create_nfs_env $1 - ret=$? - if [ $ret -eq 0 ]; then - echo "Info: The nfs env for test create successfully." - else - echo "Error: creating the nfs env for test failed." - fi - else - echo "Usage: test-for-nfs [-c] OS_VERSION" - ret=1 - fi + create_nfs_env + ret=$? + if [ $ret -eq 0 ]; then + echo "Info: The nfs env for test create successfully." + else + echo "Error: creating the nfs env for test failed." + fi ;; esac diff --git a/tests/Sanity/byteman-java-methods-probing/main.fmf b/tests/Sanity/byteman-java-methods-probing/main.fmf index 607b883..3717888 100644 --- a/tests/Sanity/byteman-java-methods-probing/main.fmf +++ b/tests/Sanity/byteman-java-methods-probing/main.fmf @@ -10,3 +10,4 @@ recommend: duration: 15m extra-summary: /tools/systemtap/Sanity/byteman-java-methods-probing extra-task: /tools/systemtap/Sanity/byteman-java-methods-probing +tier: 1 diff --git a/tests/Sanity/kernel-modules/main.fmf b/tests/Sanity/kernel-modules/main.fmf index 88e2d17..b8d53e3 100644 --- a/tests/Sanity/kernel-modules/main.fmf +++ b/tests/Sanity/kernel-modules/main.fmf @@ -15,3 +15,4 @@ recommend: duration: 10m extra-summary: /tools/systemtap/Sanity/kernel-modules extra-task: /tools/systemtap/Sanity/kernel-modules +tier: 1 diff --git a/tests/Sanity/quick-smoke-test/main.fmf b/tests/Sanity/quick-smoke-test/main.fmf index 0c8a945..2b8ca3c 100644 --- a/tests/Sanity/quick-smoke-test/main.fmf +++ b/tests/Sanity/quick-smoke-test/main.fmf @@ -13,3 +13,4 @@ recommend: duration: 1h extra-summary: /tools/systemtap/Sanity/quick-smoke-test extra-task: /tools/systemtap/Sanity/quick-smoke-test +tier: 1 diff --git a/tests/Sanity/stap-server-basic-sanity/main.fmf b/tests/Sanity/stap-server-basic-sanity/main.fmf index 248ecde..7862ee2 100644 --- a/tests/Sanity/stap-server-basic-sanity/main.fmf +++ b/tests/Sanity/stap-server-basic-sanity/main.fmf @@ -15,3 +15,4 @@ recommend: duration: 45m extra-summary: /tools/systemtap/Sanity/stap-server-basic-sanity extra-task: /tools/systemtap/Sanity/stap-server-basic-sanity +tier: 1 diff --git a/tests/Sanity/userspace-probes/main.fmf b/tests/Sanity/userspace-probes/main.fmf index b509a17..a89344f 100644 --- a/tests/Sanity/userspace-probes/main.fmf +++ b/tests/Sanity/userspace-probes/main.fmf @@ -14,3 +14,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=855981 extra-summary: /CoreOS/systemtap/Sanity/userspace-probes extra-task: /CoreOS/systemtap/Sanity/userspace-probes +tier: 1 From 0a08050f43df5c8e06188dd9cfed74649291593e Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Fri, 28 Apr 2023 17:21:02 -0400 Subject: [PATCH 025/101] upstream release --- .gitignore | 1 + rhbz1997192.patch | 50 ------------------------------ rhbz2145242.patch | 30 ------------------ rhbz2149223.patch | 78 ----------------------------------------------- rhbz2149666.patch | 73 -------------------------------------------- rhbz2154430.patch | 72 ------------------------------------------- sources | 2 +- systemtap.spec | 57 +++++++++++++++++----------------- 8 files changed, 31 insertions(+), 332 deletions(-) delete mode 100644 rhbz1997192.patch delete mode 100644 rhbz2145242.patch delete mode 100644 rhbz2149223.patch delete mode 100644 rhbz2149666.patch delete mode 100644 rhbz2154430.patch diff --git a/.gitignore b/.gitignore index 511f7f4..8865121 100644 --- a/.gitignore +++ b/.gitignore @@ -84,3 +84,4 @@ /systemtap-4.8~pre16594741g5bdc37b9.tar.gz /systemtap-4.8~pre16650659g6a096a7d.tar.gz /systemtap-4.8.tar.gz +/systemtap-4.9.tar.gz diff --git a/rhbz1997192.patch b/rhbz1997192.patch deleted file mode 100644 index 4500e85..0000000 --- a/rhbz1997192.patch +++ /dev/null @@ -1,50 +0,0 @@ -commit 47cab810bb7ea315a2dec23c2f61e7ba74515b82 -Author: Martin Cermak -Date: Fri Dec 16 16:08:20 2022 -0500 - - tapset: nfs.proc.commit_done compilation on some kernels - - Correct: - 9.0 Server x86_64 # stap -vp3 nfs.proc.commit_done.stp - - Pass 1: parsed user script and 482 library scripts using 108088virt/88468res/12460shr/75476data kb, in 190usr/60sys/501real ms. - semantic error: invalid access '->task' vs 'void*': operator '->' at /usr/share/systemtap/tapset/linux/nfs_proc.stpm:16:21 - source: ( get_ip(&@nfs_data->task) ) - ^ - in expansion of macro: operator '@_nfs_data_server_ip' at /usr/share/systemtap/tapset/linux/nfs_proc.stp:1421:15 - source: server_ip = @_nfs_data_server_ip($task->tk_calldata) - ^ - -diff --git a/tapset/linux/nfs_proc.stp b/tapset/linux/nfs_proc.stp -index 9b1f65f5f..4413384f9 100644 ---- a/tapset/linux/nfs_proc.stp -+++ b/tapset/linux/nfs_proc.stp -@@ -1442,10 +1442,11 @@ probe nfs.proc3.commit_done = kernel.function("nfs3_commit_done") !, - valid = @_nfs_data_valid($data) - } - else { -- server_ip = @_nfs_data_server_ip($task->tk_calldata) -- prot = @_nfs_data_prot($task->tk_calldata) -- count = @_nfs_data_res_count($task->tk_calldata) -- valid = @_nfs_data_valid($task->tk_calldata) -+ _tk_calldata=@choose_defined($task->tk_calldata, @cast($task, "rpc_task", "kernel:nfs")->tk_calldata) -+ server_ip = @_nfs_data_server_ip(_tk_calldata) -+ prot = @_nfs_data_prot(_tk_calldata) -+ count = @_nfs_data_res_count(_tk_calldata) -+ valid = @_nfs_data_valid(_tk_calldata) - } - timestamp = 0 - version = 3 -diff --git a/tapset/linux/nfs_proc.stpm b/tapset/linux/nfs_proc.stpm -index 8576c0f33..4fe40b2a5 100644 ---- a/tapset/linux/nfs_proc.stpm -+++ b/tapset/linux/nfs_proc.stpm -@@ -13,7 +13,7 @@ - - @define _nfs_data_server_ip(nfs_data) - %( -- ( get_ip(&@nfs_data->task) ) -+ ( get_ip(@choose_defined(&@nfs_data->task, &@cast(@nfs_data, "nfs_commit_data", "kernel:nfs")->task)) ) - %) - - @define _nfs_data_prot(nfs_data) diff --git a/rhbz2145242.patch b/rhbz2145242.patch deleted file mode 100644 index 1853a64..0000000 --- a/rhbz2145242.patch +++ /dev/null @@ -1,30 +0,0 @@ -commit 578e60102871d11ed8c18d36f6286f3a96258d8f -Author: Ryan Goldberg -Date: Thu Dec 1 16:15:44 2022 -0500 - - PR29676: Wildcard expansion fix for labels - - PR29676, introduced an bug where function symbols from the symbol - table were expanded in the function component resulting in wildcards - not being expanded in labels. This fix, removes the issue by restricting - the symbol table query to probes which don't need further debuginfo to - expand. - -diff --git a/tapsets.cxx b/tapsets.cxx -index 0ec71ebda..46b10f26e 100644 ---- a/tapsets.cxx -+++ b/tapsets.cxx -@@ -1256,7 +1256,11 @@ dwarf_query::handle_query_module() - // in the symbol table but not in dwarf and minidebuginfo is - // located in the gnu_debugdata section, alias_dupes checking - // is done before adding any probe points -- if(!pending_interrupts) -+ // PR29676. Some probes require additional debuginfo -+ // to expand wildcards (ex. .label, .callee). Since the debuginfo is -+ // not available, don't bother looking in the symbol table for these results. -+ // This can result in 0 results, if there is no dwarf info present -+ if(!pending_interrupts && !(has_label || has_callee || has_callees_num)) - query_module_symtab(); - } - - diff --git a/rhbz2149223.patch b/rhbz2149223.patch deleted file mode 100644 index 75ba486..0000000 --- a/rhbz2149223.patch +++ /dev/null @@ -1,78 +0,0 @@ -commit 05eb6742c169226ae09f1737aa8b9dc1dc12adb5 -Author: Mark Wielaard -Date: Tue Nov 29 18:50:58 2022 +0100 - - Handle DWARF5 DW_OP_implicit_pointer and DW_OP_entry_value - - These are the same as the GNU extensions for older DWARF, - DW_OP_GNU_implicit_pointer and DW_GNU_entry_value. - -diff --git a/loc2stap.cxx b/loc2stap.cxx -index efc78cc57..53316a480 100644 ---- a/loc2stap.cxx -+++ b/loc2stap.cxx -@@ -23,6 +23,11 @@ - #define DW_OP_GNU_entry_value 0xf3 - #endif - -+#if ! _ELFUTILS_PREREQ(0, 171) -+#define DW_OP_entry_value 0xa3 -+#define DW_OP_implicit_pointer 0xa0 -+#endif -+ - #define N_(x) x - - -@@ -372,7 +377,7 @@ location_context::translate (const Dwarf_Op *expr, const size_t len, - DIE ("operations follow DW_OP_implicit_value"); - - if (implicit_pointer != NULL) -- DIE ("operations follow DW_OP_GNU_implicit_pointer"); -+ DIE ("operations follow DW_OP implicit_pointer"); - } - - switch (expr[i].atom) -@@ -662,6 +667,7 @@ location_context::translate (const Dwarf_Op *expr, const size_t len, - - #if _ELFUTILS_PREREQ (0, 149) - case DW_OP_GNU_implicit_pointer: -+ case DW_OP_implicit_pointer: - implicit_pointer = &expr[i]; - /* Fake top of stack: implicit_pointer being set marks it. */ - PUSH(NULL); -@@ -684,10 +690,11 @@ location_context::translate (const Dwarf_Op *expr, const size_t len, - break; - - case DW_OP_GNU_entry_value: -+ case DW_OP_entry_value: - { - expression *result = handle_GNU_entry_value (expr[i]); - if (result == NULL) -- DIE("DW_OP_GNU_entry_value unable to resolve value"); -+ DIE("DW_OP entry_value unable to resolve value"); - PUSH(result); - } - break; -@@ -1248,7 +1255,8 @@ location_context::location_relative (const Dwarf_Op *expr, size_t len, - break; - - case DW_OP_GNU_entry_value: -- DIE ("unhandled DW_OP_GNU_entry_value"); -+ case DW_OP_entry_value: -+ DIE ("unhandled DW_OP entry_value"); - break; - - default: -diff --git a/testsuite/systemtap.base/dw_entry_value.exp b/testsuite/systemtap.base/dw_entry_value.exp -index 7339fc5fa..b728fa7ff 100644 ---- a/testsuite/systemtap.base/dw_entry_value.exp -+++ b/testsuite/systemtap.base/dw_entry_value.exp -@@ -10,7 +10,7 @@ if { $res != "" } { - pass "$test: compiled $test.c" - } - --if { ![catch { exec eu-readelf -w $test | grep GNU_entry_value }] } { -+if { ![catch { exec eu-readelf -w $test | grep entry_value: }] } { - stap_run $test no_load $all_pass_string $srcdir/$subdir/$test.stp -c ./${test} -w - } else { - untested "$test: no DW_OP_GNU_entry_value found" diff --git a/rhbz2149666.patch b/rhbz2149666.patch deleted file mode 100644 index 74be846..0000000 --- a/rhbz2149666.patch +++ /dev/null @@ -1,73 +0,0 @@ -commit 7eed8d1fef36997b9e4c1d9cdb67643483a51e56 -Author: William Cohen -Date: Fri Nov 4 11:12:05 2022 -0400 - - Ensure that SystemTap runtime uses smp_processor_id() in proper context - - There were cases on Fedora 36 and Rawhide running kernels with - CONFIG_DEBUG_PREEMPT=y where systemtap scripts would trigger kernel - log messages like the following: - - [ 257.544406] check_preemption_disabled: 4 callbacks suppressed - [ 257.544409] BUG: using smp_processor_id() in preemptible [00000000] code: staprun/2106 - [ 257.544465] caller is _stp_runtime_context_trylock+0x12/0x70 [stap_e36600406768aeefd49daf9fc7a3d23c_2106] - [ 257.544507] CPU: 0 PID: 2106 Comm: staprun Tainted: G OE ------- --- 6.1.0-0.rc2.20221028git23758867219c.24.fc38.x86_64 #1 - [ 257.544544] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.0-1.fc36 04/01/2014 - [ 257.544571] Call Trace: - [ 257.544583] - [ 257.544593] dump_stack_lvl+0x5b/0x77 - [ 257.544620] check_preemption_disabled+0xe1/0xf0 - [ 257.544641] _stp_runtime_context_trylock+0x12/0x70 [stap_e36600406768aeefd49daf9fc7a3d23c_2106] - [ 257.544673] _stp_runtime_entryfn_get_context+0xb/0x70 [stap_e36600406768aeefd49daf9fc7a3d23c_2106] - [ 257.544705] _stp_ctl_send+0x76/0x1e0 [stap_e36600406768aeefd49daf9fc7a3d23c_2106] - [ 257.544735] _stp_transport_init+0x71a/0x860 [stap_e36600406768aeefd49daf9fc7a3d23c_2106] - [ 257.544771] ? kallsyms_on_each_symbol+0x30/0x30 [stap_e36600406768aeefd49daf9fc7a3d23c_2106] - [ 257.544803] do_one_initcall+0x6b/0x320 - [ 257.544827] do_init_module+0x4a/0x200 - [ 257.544844] __do_sys_init_module+0x16a/0x1a0 - [ 257.544870] do_syscall_64+0x58/0x80 - [ 257.544885] ? up_read+0x17/0x20 - [ 257.544902] ? lock_is_held_type+0xe8/0x140 - [ 257.544921] ? asm_exc_page_fault+0x22/0x30 - [ 257.544939] ? lockdep_hardirqs_on+0x7d/0x100 - [ 257.544956] entry_SYSCALL_64_after_hwframe+0x63/0xcd - [ 257.544975] RIP: 0033:0x7f3cde12f5de - [ 257.544992] Code: 48 8b 0d 35 68 0c 00 f7 d8 64 89 01 48 83 c8 ff c3 66 2e 0f 1f 84 00 00 00 00 00 90 f3 0f 1e fa 49 89 ca b8 af 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 8b 0d 02 68 0c 00 f7 d8 64 89 01 48 - [ 257.545010] RSP: 002b:00007ffc5170c418 EFLAGS: 00000246 ORIG_RAX: 00000000000000af - [ 257.545010] RAX: ffffffffffffffda RBX: 0000563620bd4020 RCX: 00007f3cde12f5de - [ 257.545010] RDX: 0000563620bd4020 RSI: 0000000000040ea0 RDI: 00007f3cde44a010 - [ 257.545010] RBP: 0000000000000003 R08: 0000000000000000 R09: 0000000000000000 - [ 257.545010] R10: 0000000000000053 R11: 0000000000000246 R12: 00007ffc5170c510 - [ 257.545010] R13: 00007f3cde44a010 R14: 00007ffc5170c440 R15: 00007f3cde4631e8 - [ 257.545010] - - This issue was introduced by git commit 1641b6e7ea which added a fast - path check that used smp_processor_id() without first having a - preempt_disable(). The code now ensures that preemption is disabled - before using the smp_processor_id(). - -diff --git a/runtime/linux/runtime_context.h b/runtime/linux/runtime_context.h -index 3ed3cbd22..ee3870f32 100644 ---- a/runtime/linux/runtime_context.h -+++ b/runtime/linux/runtime_context.h -@@ -49,13 +49,18 @@ static bool _stp_runtime_context_trylock(void) - { - bool locked; - -+ /* Need to disable preemption because of the smp_processor_id() call -+ in _stp_runtime_get_context(). */ -+ preempt_disable(); -+ - /* fast path to ignore new online CPUs without percpu context memory - * allocations. this also serves as an extra safe guard for NULL context - * pointers. */ -- if (unlikely(_stp_runtime_get_context() == NULL)) -+ if (unlikely(_stp_runtime_get_context() == NULL)) { -+ preempt_enable_no_resched(); - return false; -+ } - -- preempt_disable(); - locked = atomic_add_unless(&_stp_contexts_busy_ctr, 1, INT_MAX); - if (!locked) - preempt_enable_no_resched(); diff --git a/rhbz2154430.patch b/rhbz2154430.patch deleted file mode 100644 index 0e6a7c2..0000000 --- a/rhbz2154430.patch +++ /dev/null @@ -1,72 +0,0 @@ -commit 8f3498781413a710dc9e128f5a96891a6a18fc52 -Author: Martin Cermak -Date: Wed Dec 14 17:37:58 2022 +0100 - - PR29766: kernel.function("__set_page_dirty_buffers") not found in vfs.stp - - Updates needed for 6.1.0-65.fc38 compatibility. - -diff --git a/tapset/linux/vfs.stp b/tapset/linux/vfs.stp -index e3c1a3032..aebeb3fc0 100644 ---- a/tapset/linux/vfs.stp -+++ b/tapset/linux/vfs.stp -@@ -822,13 +822,15 @@ probe vfs.buffer_migrate_page.return = - } - - /* default if aop not set, __set_page_dirty_nobuffers usually used if set */ --probe vfs.__set_page_dirty_buffers = kernel.function("__set_page_dirty_buffers") -+/* block_dirty_folio related to kernel commit e621900ad28b748e058b81d6078 */ -+probe vfs.__set_page_dirty_buffers = kernel.function("__set_page_dirty_buffers")!, -+ kernel.function("block_dirty_folio") - { -- dev = __page_dev($page) -- devname = __find_bdevname(dev, __page_bdev($page)) -- ino = __page_ino($page) -+ dev = __page_dev(@choose_defined($page, $folio)) -+ devname = __find_bdevname(dev, __page_bdev(@choose_defined($page, $folio))) -+ ino = __page_ino(@choose_defined($page, $folio)) - -- index = __page_index($page) -+ index = __page_index(@choose_defined($page, $folio)) - - name = "__set_page_dirty_buffers" - argstr = sprintf("%d", index) -@@ -837,7 +839,8 @@ probe vfs.__set_page_dirty_buffers = kernel.function("__set_page_dirty_buffers") - units = "pages" - } - probe vfs.__set_page_dirty_buffers.return = -- kernel.function("__set_page_dirty_buffers").return -+ kernel.function("__set_page_dirty_buffers").return!, -+ kernel.function("block_dirty_folio") - { - name = "__set_page_dirty_buffers" - retstr = sprintf("%d", $return) -@@ -914,8 +917,9 @@ probe __vfs.ext4_mpage_readpages.return = - - - /* newer style */ -+/* add_to_page_cache_locked removed per kernel commit f00654007fe1c15 */ - probe vfs.__add_to_page_cache = -- kernel.function("add_to_page_cache_locked"), -+ kernel.function("add_to_page_cache_locked") !, - kernel.function("add_to_page_cache_lru") - { } - -@@ -939,7 +943,7 @@ probe vfs.add_to_page_cache = - - /* newer style */ - probe vfs.__add_to_page_cache.return = -- kernel.function("add_to_page_cache_locked").return, -+ kernel.function("add_to_page_cache_locked").return !, - kernel.function("add_to_page_cache_lru").return - { } - -@@ -958,7 +962,7 @@ probe vfs.add_to_page_cache.return = - - probe vfs.remove_from_page_cache = - kernel.function("__delete_from_page_cache") !, -- kernel.function("__remove_from_page_cache") -+ kernel.function("__remove_from_page_cache") ? - { - dev = __page_dev($page) - devname = __find_bdevname(dev, __page_bdev($page)) diff --git a/sources b/sources index 9266c31..6711998 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-4.8.tar.gz) = fdcbc48ba17b2155c1419d99147a4cfbee2e69db945bfd0e6881b71ab11165bd23ea7ce9456856ae36807fb18f9934880a6b7c44456b63833ea260038744d9f2 +SHA512 (systemtap-4.9.tar.gz) = a2736223fee0c801c36719a0245f31ed7e2e63c30bb7d5cab631dd57e4eb10e04abf2c9b272bda2a17c207c9dd163a1eb8a3e0759eda0c781946e644625510b7 diff --git a/systemtap.spec b/systemtap.spec index 340791f..fd80232 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -121,8 +121,9 @@ m stapdev stapdev Name: systemtap -Version: 4.8 -Release: 5%{?release_override}%{?dist} +# PRERELEASE +Version: 4.9 +Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -141,6 +142,7 @@ Release: 5%{?release_override}%{?dist} # systemtap-runtime-virtguest udev rules, init scripts/systemd service, req:-runtime # systemtap-runtime-python2 HelperSDT python2 module, req:-runtime # systemtap-runtime-python3 HelperSDT python3 module, req:-runtime +# systemtap-jupyter /usr/bin/stap-jupyter-* interactive-notebook req:systemtap # # Typical scenarios: # @@ -158,14 +160,6 @@ License: GPLv2+ URL: http://sourceware.org/systemtap/ Source: ftp://sourceware.org/pub/systemtap/releases/systemtap-%{version}.tar.gz -Patch1: rhbz1997192.patch -Patch2: rhbz2145242.patch -Patch3: rhbz2149223.patch -Patch4: rhbz2149666.patch -Patch5: rhbz2154430.patch - - - # Build* BuildRequires: make BuildRequires: gcc-c++ @@ -578,17 +572,23 @@ This package installs the services necessary on a virtual machine for a systemtap-runtime-virthost machine to execute systemtap scripts. %endif +%if %{with_python3} && %{with_monitor} +%package jupyter +Summary: ISystemtap jupyter kernel and examples +License: GPLv2+ +URL: http://sourceware.org/systemtap/ +Requires: systemtap = %{version}-%{release} + +%description jupyter +This package includes files needed to build and run +the interactive systemtap Jupyter kernel, either locally +or within a container. +%endif # ------------------------------------------------------------------------ %prep %setup -q -%patch1 -p1 -%patch2 -p1 -%patch3 -p1 -%patch4 -p1 -%patch5 -p1 - %build # Enable/disable the dyninst pure-userspace backend @@ -1289,6 +1289,15 @@ exit 0 %{_sbindir}/stap-exporter %endif +%if %{with_python3} && %{with_monitor} +%files jupyter +%{_bindir}/stap-jupyter-container +%{_bindir}/stap-jupyter-install +%{_mandir}/man1/stap-jupyter.1* +%dir %{_datadir}/systemtap +%{_datadir}/systemtap/interactive-notebook +%endif + # ------------------------------------------------------------------------ # Future new-release entries should be of the form @@ -1298,22 +1307,14 @@ exit 0 # PRERELEASE %changelog -* Thu Feb 23 2023 Frank Ch. Eigler - 4.8-5 -- Rebuilt for Dyninst update - -* Mon Feb 20 2023 Jonathan Wakely - 4.8-4 -- Rebuilt for Boost 1.81 - -* Wed Feb 08 2023 Frank Ch. Eigler - 4.8-3 -- backport several RHEL/upstream patches - -* Sat Jan 21 2023 Fedora Release Engineering - 4.8-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild +* Fri Apr 28 2023 Frank Ch. Eigler - 4.9-1 +- Upstream release, see wiki page below for detailed notes. + https://sourceware.org/systemtap/wiki/SystemTapReleases * Thu Nov 03 2022 Serhei Makarov - 4.8-1 - Upstream release, see wiki page below for detailed notes. https://sourceware.org/systemtap/wiki/SystemTapReleases - + * Mon May 02 2022 Frank Ch. Eigler - 4.7-1 - Upstream release, see wiki page below for detailed notes. https://sourceware.org/systemtap/wiki/SystemTapReleases From 6e53120fd193b022862a6bb68ae0fb78d226949c Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Tue, 2 May 2023 10:47:18 +0200 Subject: [PATCH 026/101] CI Tests: Relax check for RPMs (not applicable to rhel8 modules) --- tests/Regression/python-probing/runtest.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/Regression/python-probing/runtest.sh b/tests/Regression/python-probing/runtest.sh index e8ce264..f4061ea 100755 --- a/tests/Regression/python-probing/runtest.sh +++ b/tests/Regression/python-probing/runtest.sh @@ -41,7 +41,7 @@ collection_path=$(which python | sed 's/\/usr\/bin\/python//') rlJournalStart rlPhaseStartSetup - rlAssertRpm --all + # rlAssertRpm --all rlAssertRpm "systemtap" rlLogInfo "Running on kernel: $(uname -r)" rlRun "rpm -qa 'systemtap*'" 0 "Checking systemtap packages" From 12975603f1cac32648df644d161e298089ed3bda Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Thu, 4 May 2023 17:56:45 +0200 Subject: [PATCH 027/101] CI Tests: Multiple updates tests/Regression/RHEL6Feature-cpp-methods: Fix locale/LANG dependent sort collation prob tests/Regression/python-probing: Make sure needed debuginfo is in place tests/Regression/wrong-data-returned-by-nfs-commit-done: Refactor, improve clranup, simplify --- .../RHEL6Feature-cpp-methods/golden.el7.out | 70 -------------- .../RHEL6Feature-cpp-methods/golden.el8.out | 83 ----------------- .../RHEL6Feature-cpp-methods/golden.out | 70 -------------- .../RHEL6Feature-cpp-methods/runtest.sh | 18 ++-- tests/Regression/python-probing/main.fmf | 3 + tests/Regression/python-probing/runtest.sh | 4 + .../{testpro => }/nfs.proc.commit_done.c | 2 +- .../{testpro => }/nfs.proc.commit_done.stp | 0 .../runtest.sh | 42 +++++---- .../testpro/Makefile | 11 --- .../testpro/test-for-nfs | 91 ------------------- 11 files changed, 41 insertions(+), 353 deletions(-) delete mode 100644 tests/Regression/RHEL6Feature-cpp-methods/golden.el7.out delete mode 100644 tests/Regression/RHEL6Feature-cpp-methods/golden.el8.out delete mode 100644 tests/Regression/RHEL6Feature-cpp-methods/golden.out rename tests/Regression/wrong-data-returned-by-nfs-commit-done/{testpro => }/nfs.proc.commit_done.c (96%) rename tests/Regression/wrong-data-returned-by-nfs-commit-done/{testpro => }/nfs.proc.commit_done.stp (100%) delete mode 100644 tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/Makefile delete mode 100755 tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/test-for-nfs diff --git a/tests/Regression/RHEL6Feature-cpp-methods/golden.el7.out b/tests/Regression/RHEL6Feature-cpp-methods/golden.el7.out deleted file mode 100644 index d7cff12..0000000 --- a/tests/Regression/RHEL6Feature-cpp-methods/golden.el7.out +++ /dev/null @@ -1,70 +0,0 @@ -StandaloneFunction start: _Z18StandaloneFunctionv -StandaloneFunction end: main -StandaloneFunction start: _ZN5inner18StandaloneFunctionEv -inner::StandaloneFunction start: _ZN5inner18StandaloneFunctionEv -StandaloneFunction end: main -inner::StandaloneFunction end: main -StandaloneFunction start: _ZN9moreinner18StandaloneFunctionEv -moreinner::StandaloneFunction start: _ZN9moreinner18StandaloneFunctionEv -StandaloneFunction end: main -moreinner::StandaloneFunction end: main -puMethod start: _ZN6CLASS18puMethodEv -prMethod start: _ZN6CLASS18prMethodEv -prMethod end: _ZN6CLASS18puMethodEv -puMethod end: main -stMethod start: _ZN6CLASS18stMethodEv -stMethod end: main -puMethod start: _ZN5inner6CLASS18puMethodEv -inner::puMethod start: _ZN5inner6CLASS18puMethodEv -prMethod start: _ZN5inner6CLASS18prMethodEv -inner::prMethod start: _ZN5inner6CLASS18prMethodEv -prMethod end: _ZN5inner6CLASS18puMethodEv -inner::prMethod end: _ZN5inner6CLASS18puMethodEv -puMethod end: main -inner::puMethod end: main -stMethod start: _ZN5inner6CLASS18stMethodEv -inner::stMethod start: _ZN5inner6CLASS18stMethodEv -stMethod end: main -inner::stMethod end: main -puMethod start: _ZN9moreinner6CLASS18puMethodEv -moreinner::puMethod start: _ZN9moreinner6CLASS18puMethodEv -prMethod start: _ZN9moreinner6CLASS18prMethodEv -moreinner::prMethod start: _ZN9moreinner6CLASS18prMethodEv -prMethod end: _ZN9moreinner6CLASS18puMethodEv -moreinner::prMethod end: _ZN9moreinner6CLASS18puMethodEv -puMethod end: main -moreinner::puMethod end: main -stMethod start: _ZN9moreinner6CLASS18stMethodEv -moreinner::stMethod start: _ZN9moreinner6CLASS18stMethodEv -stMethod end: main -moreinner::stMethod end: main -puMethod start: _ZN6CLASS18puMethodEv -prMethod start: _ZN6CLASS18prMethodEv -prMethod end: _ZN6CLASS18puMethodEv -puMethod end: main -stMethod start: _ZN6CLASS18stMethodEv -stMethod end: main -puMethod start: _ZN5inner6CLASS18puMethodEv -inner::puMethod start: _ZN5inner6CLASS18puMethodEv -prMethod start: _ZN5inner6CLASS18prMethodEv -inner::prMethod start: _ZN5inner6CLASS18prMethodEv -prMethod end: _ZN5inner6CLASS18puMethodEv -inner::prMethod end: _ZN5inner6CLASS18puMethodEv -puMethod end: main -inner::puMethod end: main -stMethod start: _ZN5inner6CLASS18stMethodEv -inner::stMethod start: _ZN5inner6CLASS18stMethodEv -stMethod end: main -inner::stMethod end: main -puMethod start: _ZN9moreinner6CLASS18puMethodEv -moreinner::puMethod start: _ZN9moreinner6CLASS18puMethodEv -prMethod start: _ZN9moreinner6CLASS18prMethodEv -moreinner::prMethod start: _ZN9moreinner6CLASS18prMethodEv -prMethod end: _ZN9moreinner6CLASS18puMethodEv -moreinner::prMethod end: _ZN9moreinner6CLASS18puMethodEv -puMethod end: main -moreinner::puMethod end: main -stMethod start: _ZN9moreinner6CLASS18stMethodEv -moreinner::stMethod start: _ZN9moreinner6CLASS18stMethodEv -stMethod end: main -moreinner::stMethod end: main diff --git a/tests/Regression/RHEL6Feature-cpp-methods/golden.el8.out b/tests/Regression/RHEL6Feature-cpp-methods/golden.el8.out deleted file mode 100644 index 6ba6bc9..0000000 --- a/tests/Regression/RHEL6Feature-cpp-methods/golden.el8.out +++ /dev/null @@ -1,83 +0,0 @@ -StandaloneFunction start: _Z18StandaloneFunctionv -StandaloneFunction end: main -StandaloneFunction start: _ZN5inner18StandaloneFunctionEv -inner::StandaloneFunction start: _ZN5inner18StandaloneFunctionEv -StandaloneFunction end: main -inner::StandaloneFunction end: main -StandaloneFunction start: _ZN9moreinner18StandaloneFunctionEv -moreinner::StandaloneFunction start: _ZN9moreinner18StandaloneFunctionEv -StandaloneFunction end: main -moreinner::StandaloneFunction end: main -puMethod start: _ZN6CLASS18puMethodEv -prMethod start: _ZN6CLASS18prMethodEv -prMethod end: _ZN6CLASS18puMethodEv -puMethod end: main -stMethod start: _ZN6CLASS18stMethodEv -stMethod end: main -puMethod start: _ZN5inner6CLASS18puMethodEv -inner::puMethod start: _ZN5inner6CLASS18puMethodEv -prMethod start: _ZN5inner6CLASS18prMethodEv -inner::prMethod start: _ZN5inner6CLASS18prMethodEv -prMethod end: _ZN5inner6CLASS18puMethodEv -inner::prMethod end: _ZN5inner6CLASS18puMethodEv -puMethod end: main -inner::puMethod end: main -stMethod start: _ZN5inner6CLASS18stMethodEv -inner::stMethod start: _ZN5inner6CLASS18stMethodEv -stMethod end: main -inner::stMethod end: main -puMethod start: _ZN9moreinner6CLASS18puMethodEv -moreinner::puMethod start: _ZN9moreinner6CLASS18puMethodEv -prMethod start: _ZN9moreinner6CLASS18prMethodEv -moreinner::prMethod start: _ZN9moreinner6CLASS18prMethodEv -prMethod end: _ZN9moreinner6CLASS18puMethodEv -moreinner::prMethod end: _ZN9moreinner6CLASS18puMethodEv -puMethod end: main -moreinner::puMethod end: main -stMethod start: _ZN9moreinner6CLASS18stMethodEv -moreinner::stMethod start: _ZN9moreinner6CLASS18stMethodEv -stMethod end: main -moreinner::stMethod end: main -puMethod start: _ZN6CLASS18puMethodEv -prMethod start: _ZN6CLASS18prMethodEv -prMethod end: _ZN6CLASS18puMethodEv -puMethod end: main -stMethod start: _ZN6CLASS18stMethodEv -stMethod end: main -puMethod start: _ZN5inner6CLASS18puMethodEv -inner::puMethod start: _ZN5inner6CLASS18puMethodEv -prMethod start: _ZN5inner6CLASS18prMethodEv -inner::prMethod start: _ZN5inner6CLASS18prMethodEv -prMethod end: _ZN5inner6CLASS18puMethodEv -inner::prMethod end: _ZN5inner6CLASS18puMethodEv -puMethod end: main -inner::puMethod end: main -stMethod start: _ZN5inner6CLASS18stMethodEv -inner::stMethod start: _ZN5inner6CLASS18stMethodEv -stMethod end: main -inner::stMethod end: main -puMethod start: _ZN9moreinner6CLASS18puMethodEv -moreinner::puMethod start: _ZN9moreinner6CLASS18puMethodEv -prMethod start: _ZN9moreinner6CLASS18prMethodEv -moreinner::prMethod start: _ZN9moreinner6CLASS18prMethodEv -prMethod end: _ZN9moreinner6CLASS18puMethodEv -moreinner::prMethod end: _ZN9moreinner6CLASS18puMethodEv -puMethod end: main -moreinner::puMethod end: main -stMethod start: _ZN9moreinner6CLASS18stMethodEv -moreinner::stMethod start: _ZN9moreinner6CLASS18stMethodEv -stMethod end: main -moreinner::stMethod end: main -__StandaloneFunction=0 -__hitcount=70 -__inner_StandaloneFunction=0 -__moreinner_StandaloneFunction=0 -__stMethod=0 -__inner_CLASS1_stMethod=0 -__moreinner_star_stMethod=0 -__prMethod=0 -__inner_CLASS1_prMethod=0 -__moreinner_star_prMethod=0 -__puMethod=0 -__inner_CLASS1_puMethod=0 -__moreinner_star_puMethod=0 diff --git a/tests/Regression/RHEL6Feature-cpp-methods/golden.out b/tests/Regression/RHEL6Feature-cpp-methods/golden.out deleted file mode 100644 index fe9c7bb..0000000 --- a/tests/Regression/RHEL6Feature-cpp-methods/golden.out +++ /dev/null @@ -1,70 +0,0 @@ -StandaloneFunction start: StandaloneFunction -StandaloneFunction end: StandaloneFunction -StandaloneFunction start: StandaloneFunction -inner::StandaloneFunction start: inner::StandaloneFunction -inner::StandaloneFunction end: inner::StandaloneFunction -StandaloneFunction end: StandaloneFunction -StandaloneFunction start: StandaloneFunction -moreinner::StandaloneFunction start: moreinner::StandaloneFunction -moreinner::StandaloneFunction end: moreinner::StandaloneFunction -StandaloneFunction end: StandaloneFunction -puMethod start: puMethod -prMethod start: prMethod -prMethod end: prMethod -puMethod end: puMethod -stMethod start: stMethod -stMethod end: stMethod -puMethod start: puMethod -inner::puMethod start: inner::CLASS1::puMethod -prMethod start: prMethod -inner::prMethod start: inner::CLASS1::prMethod -inner::prMethod end: inner::CLASS1::prMethod -prMethod end: prMethod -inner::puMethod end: inner::CLASS1::puMethod -puMethod end: puMethod -stMethod start: stMethod -inner::stMethod start: inner::CLASS1::stMethod -inner::stMethod end: inner::CLASS1::stMethod -stMethod end: stMethod -puMethod start: puMethod -moreinner::puMethod start: moreinner::CLASS1::puMethod -prMethod start: prMethod -moreinner::prMethod start: moreinner::CLASS1::prMethod -moreinner::prMethod end: moreinner::CLASS1::prMethod -prMethod end: prMethod -moreinner::puMethod end: moreinner::CLASS1::puMethod -puMethod end: puMethod -stMethod start: stMethod -moreinner::stMethod start: moreinner::CLASS1::stMethod -moreinner::stMethod end: moreinner::CLASS1::stMethod -stMethod end: stMethod -puMethod start: puMethod -prMethod start: prMethod -prMethod end: prMethod -puMethod end: puMethod -stMethod start: stMethod -stMethod end: stMethod -puMethod start: puMethod -inner::puMethod start: inner::CLASS1::puMethod -prMethod start: prMethod -inner::prMethod start: inner::CLASS1::prMethod -inner::prMethod end: inner::CLASS1::prMethod -prMethod end: prMethod -inner::puMethod end: inner::CLASS1::puMethod -puMethod end: puMethod -stMethod start: stMethod -inner::stMethod start: inner::CLASS1::stMethod -inner::stMethod end: inner::CLASS1::stMethod -stMethod end: stMethod -puMethod start: puMethod -moreinner::puMethod start: moreinner::CLASS1::puMethod -prMethod start: prMethod -moreinner::prMethod start: moreinner::CLASS1::prMethod -moreinner::prMethod end: moreinner::CLASS1::prMethod -prMethod end: prMethod -moreinner::puMethod end: moreinner::CLASS1::puMethod -puMethod end: puMethod -stMethod start: stMethod -moreinner::stMethod start: moreinner::CLASS1::stMethod -moreinner::stMethod end: moreinner::CLASS1::stMethod -stMethod end: stMethod diff --git a/tests/Regression/RHEL6Feature-cpp-methods/runtest.sh b/tests/Regression/RHEL6Feature-cpp-methods/runtest.sh index 443ff56..a019d7a 100755 --- a/tests/Regression/RHEL6Feature-cpp-methods/runtest.sh +++ b/tests/Regression/RHEL6Feature-cpp-methods/runtest.sh @@ -30,16 +30,13 @@ . /usr/share/beakerlib/beakerlib.sh || exit 1 PACKAGE="systemtap" +export LANG=C rlJournalStart rlPhaseStartSetup rlRun "stap-prep" 0-255 rlRun "g++ -O0 classes.cpp -o classes -g" - - rlIsRHEL 6 && COMPAT='--compatible=1.8' - # rlIsRHEL 7 && cp -f golden.el7.out golden.out - # rlIsRHEL 8 && cp -f golden.el8.out golden.out rlPhaseEnd rlPhaseStartTest @@ -50,22 +47,25 @@ rlPhaseStartTest # rlRun "diff golden.out output.out" rlRun "grep ^__ output.out | sort > summary.out" + # The way sort works across test systems may differ + # esp wrt whether capitals go first or not, so let's sort + # the golden_summary.out first using actual defaults + # slash LANG etc... + rlRun "sort golden_summary.out > golden_summary.sort" + # RHEL6: covert hex to dec: rlRun "sed -i 's/0x0/0/' summary.out" rlRun "sed -i 's/0x46/70/' summary.out" # Sanity check - rlRun "diff golden_summary.out summary.out" || ( + rlRun "diff golden_summary.sort summary.out" || ( rlRun "cat golden_summary.out" rlRun "cat summary.out" ) rlPhaseEnd rlPhaseStartCleanup - rlFileSubmit golden.out - rlFileSubmit output.out - - rlRun "rm -f output.out classes" + rlRun "rm -f golden_summary.sort output.out summary.out classes" rlPhaseEnd rlJournalPrintText diff --git a/tests/Regression/python-probing/main.fmf b/tests/Regression/python-probing/main.fmf index 55b3281..f3abc74 100644 --- a/tests/Regression/python-probing/main.fmf +++ b/tests/Regression/python-probing/main.fmf @@ -9,10 +9,13 @@ framework: beakerlib recommend: - python - python-debuginfo +- python3-debuginfo +- python3.9-debuginfo - systemtap - python2 - python3 - elfutils +- yum-utils duration: 15m extra-summary: /CoreOS/python/Sanity/systemtap extra-task: /CoreOS/python/Sanity/systemtap diff --git a/tests/Regression/python-probing/runtest.sh b/tests/Regression/python-probing/runtest.sh index f4061ea..80f10f9 100755 --- a/tests/Regression/python-probing/runtest.sh +++ b/tests/Regression/python-probing/runtest.sh @@ -48,6 +48,10 @@ rlJournalStart rlRun "TmpDir=\`mktemp -d\`" 0 "Creating tmp directory" rlRun "cp list.stp top.stp test.py $TmpDir" 0 "Copying scripts" rlRun "pushd $TmpDir" + + # Install needed debuginfo, best effort + rlRun "L=$(stap -p2 -e 'probe python.function.entry {exit()}' | awk -F\" '/process/ {print $2}')" 0-255 + rlRun "debuginfo-install -y $L" 0-255 rlPhaseEnd rlPhaseStartTest "Verifying ELF file for presence of .probes section" diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/nfs.proc.commit_done.c b/tests/Regression/wrong-data-returned-by-nfs-commit-done/nfs.proc.commit_done.c similarity index 96% rename from tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/nfs.proc.commit_done.c rename to tests/Regression/wrong-data-returned-by-nfs-commit-done/nfs.proc.commit_done.c index 0417d71..f7b5e9b 100644 --- a/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/nfs.proc.commit_done.c +++ b/tests/Regression/wrong-data-returned-by-nfs-commit-done/nfs.proc.commit_done.c @@ -7,7 +7,7 @@ #include #include -#define TEST_DIR "/systemtap-sts-nfs-share-and-mount-tmpdir/sts_mount" +#define TEST_DIR "/systemtap-sts-nfs-share-and-mount-tmpdir2/sts_mount" static int create_and_write(char *file_name); static int read_file(char *file_name); diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/nfs.proc.commit_done.stp b/tests/Regression/wrong-data-returned-by-nfs-commit-done/nfs.proc.commit_done.stp similarity index 100% rename from tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/nfs.proc.commit_done.stp rename to tests/Regression/wrong-data-returned-by-nfs-commit-done/nfs.proc.commit_done.stp diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/runtest.sh b/tests/Regression/wrong-data-returned-by-nfs-commit-done/runtest.sh index 5543268..b33b035 100755 --- a/tests/Regression/wrong-data-returned-by-nfs-commit-done/runtest.sh +++ b/tests/Regression/wrong-data-returned-by-nfs-commit-done/runtest.sh @@ -31,42 +31,48 @@ . /etc/os-release || exit 1 PACKAGE="systemtap" +export NFS_TMP="$HOME/systemtap-sts-nfs-share-and-mount-tmpdir2" rlJournalStart rlPhaseStartSetup - rlRun "rpm -qf $(which --skip-alias stap)" + rlRun "rpm -qf $(which --skip-alias stap)" rlRun "TMPDIR=$(mktemp -d)" - rlRun "cp -r testpro $TMPDIR" - rlRun "pushd $TMPDIR/testpro/" - rlPhaseEnd - - rlPhaseStart FAIL "Systemtap sanity check" - rlRun "stap --version" - rlRun "stap -v -e 'probe kernel.function(\"vfs_read\"){ exit() }'" - rlRun "uname -a" + rlRun "cp nfs.proc.commit_done.c nfs.proc.commit_done.stp $TMPDIR/" + rlRun "pushd $TMPDIR" + rlRun "mkdir -p ${NFS_TMP}/sts_share ${NFS_TMP}/sts_mount" rlPhaseEnd rlPhaseStart FAIL "Build testing binary, prepare nfs environment" - rlRun "make" - rlRun "./test-for-nfs" + rlRun "systemctl stop nfs-server.service" + rlRun "systemctl stop rpcbind.service" + rlRun "sleep 3" + rlRun "systemctl start rpcbind.service" + rlRun "sleep 3" + rlRun "systemctl start nfs-server.service" + rlRun "sleep 3" + rlRun "systemctl status nfs-server.service" + rlRun "systemctl status rpcbind.service" + rlRun "exportfs -i -o 'rw,async,no_root_squash' 127.0.0.1:${NFS_TMP}/sts_share" + rlRun "mount -vvvvv -t nfs 127.0.0.1:${NFS_TMP}/sts_share ${NFS_TMP}/sts_mount" + rlRun "gcc nfs.proc.commit_done.c -o nfs.proc.commit_done" rlPhaseEnd rlPhaseStartTest - if stap -p2 nfs.proc.commit_done.stp >&/dev/null; then - rlRun "stap --prologue-searching=never --poison-cache -vc './nfs.proc.commit_done' nfs.proc.commit_done.stp 2>&1 | tee testout.log" - else - rlRun "stap --prologue-searching=always --poison-cache -vc './nfs.proc.commit_done' nfs.proc.commit_done.stp 2>&1 | tee testout.log" - fi + ps="-P" + stap -p2 nfs.proc.commit_done.stp >&/dev/null && ps='' + rlRun "stap $ps --poison-cache -vc './nfs.proc.commit_done' nfs.proc.commit_done.stp 2>&1 | tee testout.log" rlRun "grep -qP 'nfs.proc.commit_done server_ip:\ \d+\.\d+\.\d+\.\d+' testout.log" rlPhaseEnd rlPhaseStart WARN "Clean the nfs environment up" - rlRun "./test-for-nfs -c" + rlRun "umount -l ${NFS_TMP}/sts_mount" + rlRun "systemctl stop nfs-server.service" + rlRun "systemctl stop rpcbind.service" rlPhaseEnd rlPhaseStartCleanup rlRun "popd" - rlRun "rm -r $TMPDIR" + rlRun "rm -r $TMPDIR $NFS_TMP" rlPhaseEnd rlJournalPrintText rlJournalEnd diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/Makefile b/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/Makefile deleted file mode 100644 index 021de18..0000000 --- a/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/Makefile +++ /dev/null @@ -1,11 +0,0 @@ -CFLAGS+= -Wall - -SRCS = $(wildcard *.c) -TARGETS = $(patsubst %.c,%,$(SRCS)) - -all: $(TARGETS) - -install: - -clean: - rm -f $(TARGETS) diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/test-for-nfs b/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/test-for-nfs deleted file mode 100755 index 95579bc..0000000 --- a/tests/Regression/wrong-data-returned-by-nfs-commit-done/testpro/test-for-nfs +++ /dev/null @@ -1,91 +0,0 @@ -#!/bin/bash - -export NFS_TMP="$HOME/systemtap-sts-nfs-share-and-mount-tmpdir" - -nfs_service() -{ - local ret - local status="$1" - local OS_VER="$2" - - case "$status" in - restart) - ps -ef | grep "nfsd" | grep -v grep > /dev/null 2>&1 - if [ $? -eq 0 ]; then - echo "nfsd already running!!" - return 0 - fi - - /bin/systemctl restart nfs-server.service - ret=$? - ;; - stop) - /bin/systemctl stop nfs-server.service - ret=$? - ;; - *) - echo "Error: nfs_service [stop|restart]" - ret=1 - ;; - esac - - return $ret -} - -clean_nfs_env() -{ - umount "$NFS_TMP"/sts_mount - /usr/sbin/exportfs -u 127.0.0.1:"$NFS_TMP"/sts_share - rm -rf "$NFS_TMP" - nfs_service stop - if [ $? -ne 0 ]; then - return 1 - else - echo "Info: The nfs env for test clean successfully." - return 0 - fi -} - -create_nfs_env() -{ - nfs_service restart - if [ $? -ne 0 ]; then - return 1 - fi - - sleep 1 - - mkdir -p "$NFS_TMP"/sts_share - mkdir -p "$NFS_TMP"/sts_mount - - /usr/sbin/exportfs -i -o 'rw,async,no_root_squash' 127.0.0.1:"$NFS_TMP"/sts_share - mount -t nfs 127.0.0.1:"$NFS_TMP"/sts_share "$NFS_TMP"/sts_mount - - return 0 -} - -if [ $# -gt 2 ]; then - echo "Usage: test-for-nfs [-c]" - exit 1 -fi - -case "$1" in --c) - clean_nfs_env - ret=$? - if [ $ret -ne 0 ]; then - echo "Error: cleaning the nfs env for test failed." - fi - ;; -*) - create_nfs_env - ret=$? - if [ $ret -eq 0 ]; then - echo "Info: The nfs env for test create successfully." - else - echo "Error: creating the nfs env for test failed." - fi - ;; -esac - -exit $ret From ca2a8a03ea8039f0439f0bcfa69002c4a392f1e8 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Wed, 17 May 2023 17:19:46 +0200 Subject: [PATCH 028/101] CI Tests: Work around PR29765 --- tests/Regression/bz544960-no-cfa_ops-supplied/readpages.stp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tests/Regression/bz544960-no-cfa_ops-supplied/readpages.stp b/tests/Regression/bz544960-no-cfa_ops-supplied/readpages.stp index 7ff57b4..9410376 100644 --- a/tests/Regression/bz544960-no-cfa_ops-supplied/readpages.stp +++ b/tests/Regression/bz544960-no-cfa_ops-supplied/readpages.stp @@ -1,4 +1,4 @@ -probe nfs.aop.readpages !, nfs.aop.readpage { +probe nfs.aop.readpages !, nfs.aop.readpage ? { log(name); printf("dev=%d\n", dev); printf("ino=%d\n", ino); @@ -11,9 +11,11 @@ probe nfs.aop.readpages !, nfs.aop.readpage { printf("units=%s\n", units); } -probe nfs.aop.readpages.return !, nfs.aop.readpage.return { +probe nfs.aop.readpages.return !, nfs.aop.readpage.return ? { log(name); printf("retstr=%s\n", retstr); printf("size=%d\n", size); printf("units=%s\n", units); } + +probe oneshot { log("hey!") } From 863bc06741354d9932bfca35408f0dcd0013e190 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Thu, 18 May 2023 12:26:45 +0200 Subject: [PATCH 029/101] CI Tests: Regression/small-tests: Use debuginfod on Fedora --- tests/Regression/small-tests/runtest.sh | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/tests/Regression/small-tests/runtest.sh b/tests/Regression/small-tests/runtest.sh index 3b89566..13f898a 100755 --- a/tests/Regression/small-tests/runtest.sh +++ b/tests/Regression/small-tests/runtest.sh @@ -27,11 +27,14 @@ # Include Beaker environment . /usr/share/beakerlib/beakerlib.sh || exit 1 +. /etc/os-release ||: PACKAGE="systemtap" -export DEBUGINFOD_URLS="https://debuginfod.fedoraproject.org/ $DEBUGINFOD_URLS" -export DEBUGINFOD_TIMEOUT=300 +if echo $ID | grep -Fq fedora; then + export DEBUGINFOD_URLS="https://debuginfod.fedoraproject.org/ $DEBUGINFOD_URLS" + export DEBUGINFOD_TIMEOUT=300 +fi _arch=$(arch) @@ -73,14 +76,7 @@ rlJournalStart ( perf_probe_failed "vfs_read" && exit rlPhaseStart FAIL "test 1 bz1162939" - # At this point a weird problem shows up: sometimes the first - # systemtap invocation fails for some reason, but subsequent - # invocations succeed. Can't reproduce this manually: - rlRun "stap -vvvp4 -e 'probe vfs.read{println(\"hit\")}'" 0,1 - sleep 30 - rlRun "stap -vvvp4 -e 'probe vfs.read{println(\"hit\")}'" 0,1 - sleep 30 - rlRun "stap -e 'probe vfs.read{println(\"hit\")}' -c 'head -1 /etc/hosts'" + rlRun "stap -e 'probe vfs.read{println(\"hit\"); exit()}' -c 'head -1 /etc/hosts' | grep -F hit" rlPhaseEnd ) # bz1119335 --------------------------------------------------- From 3759fe484fccdc10347e45337cb1422cb4750e05 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Thu, 18 May 2023 13:09:44 +0200 Subject: [PATCH 030/101] CI Tests: Instead of waiting for a random event/hit, trigger one via ping --- tests/Regression/netdev-receive/runtest.sh | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/tests/Regression/netdev-receive/runtest.sh b/tests/Regression/netdev-receive/runtest.sh index 8495626..b294186 100755 --- a/tests/Regression/netdev-receive/runtest.sh +++ b/tests/Regression/netdev-receive/runtest.sh @@ -29,16 +29,14 @@ . /usr/share/beakerlib/beakerlib.sh || exit 1 PACKAGE="systemtap" -TMPFILE=$(mktemp) rlJournalStart rlPhaseStartTest - # Here we rely on that netdev.receive gets hit immediately without us explicitly triggering it. - # Not all rhel-7 stap versions have -T already, so we use -E instead. - rlRun "stap -o $TMPFILE -ve 'probe netdev.receive{log(\"HIT\") exit()}' -E 'probe timer.s(30) {log(\"TIMEOUT\") exit()}'" + rlRun "TMPFILE=$(mktemp)" + rlRun "stap -o $TMPFILE -ve 'probe netdev.receive{log(\"HIT\") exit()}' -c 'ping -c1 localhost'" rlRun "cat $TMPFILE" rlRun "grep HIT $TMPFILE" - rlRun "grep TIMEOUT $TMPFILE" 1 + rlRun "rm $TMPFILE" rlPhaseEnd rlJournalPrintText rlJournalEnd From 91acc811a1f5d373d4f7fe5f9b6685959bbc15e7 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Fri, 19 May 2023 10:34:46 +0200 Subject: [PATCH 031/101] CI Tests: Set DEBUGINFOD_URLS based on test FMF context. Tests are supposed to be executed within defined context, such as e.g. tmt --root . -c arch=x86_64 -c distro=fedora-38 -c trigger=build run ... FTR: https://tmt.readthedocs.io/en/stable/spec/plans.html#context This update sets DEBUGINFOD_URLS based on the provided distro via the ci.fmf file. --- plans/ci.fmf | 14 ++++++++++---- plans/ci/prepare/prepare.fmf | 7 ------- plans/{ci/prepare => }/prepare.sh | 11 ++++++----- tests/Regression/python-probing/runtest.sh | 4 +++- tests/Regression/small-tests/runtest.sh | 7 ++----- .../Sanity/byteman-java-methods-probing/runtest.sh | 6 +++--- tests/Sanity/quick-smoke-test/runtest.sh | 7 ++----- tests/Sanity/stap-server-basic-sanity/runtest.sh | 5 ++--- tests/Sanity/userspace-probes/runtest.sh | 5 ++--- 9 files changed, 30 insertions(+), 36 deletions(-) delete mode 100755 plans/ci/prepare/prepare.fmf rename plans/{ci/prepare => }/prepare.sh (82%) diff --git a/plans/ci.fmf b/plans/ci.fmf index 6ef79f3..50b4c14 100644 --- a/plans/ci.fmf +++ b/plans/ci.fmf @@ -3,13 +3,19 @@ adjust: - when: distro == fedora discover+: filter: 'tier: 1' + environment+: + DEBUGINFOD_URLS: https://debuginfod.fedoraproject.org/ + DEBUGINFOD_TIMEOUT: 300 + - when: distro == rhel + environment+: + DEBUGINFOD_URLS: https://debuginfod.usersys.redhat.com/ + DEBUGINFOD_TIMEOUT: 300 discover: how: fmf directory: tests prepare: - how: install - exclude: - - glibc-headers-x86 - - glibc-headers-s390 + - name: prepare + how: shell + script: ./plans/prepare.sh execute: how: tmt diff --git a/plans/ci/prepare/prepare.fmf b/plans/ci/prepare/prepare.fmf deleted file mode 100755 index 23e61d1..0000000 --- a/plans/ci/prepare/prepare.fmf +++ /dev/null @@ -1,7 +0,0 @@ -summary: Setup task -prepare: - script: ./plans/ci/prepare/prepare.sh -recommend: -- koji -- bind-utils -- avahi-tools diff --git a/plans/ci/prepare/prepare.sh b/plans/prepare.sh similarity index 82% rename from plans/ci/prepare/prepare.sh rename to plans/prepare.sh index 368ea84..dfce543 100755 --- a/plans/ci/prepare/prepare.sh +++ b/plans/prepare.sh @@ -1,12 +1,9 @@ #!/bin/bash -export DEBUGINFOD_URLS="https://debuginfod.fedoraproject.org/ $DEBUGINFOD_URLS" -export DEBUGINFOD_TIMEOUT=300 - # On Rawhide, the running kernel packages won't probably be avail in # configured repos. Debuginfo isn't a problem, we access that using # the debuginfod. -__install_deps () +__fedora_install_deps () { TMPD=$(mktemp -d) pushd $TMPD @@ -20,8 +17,12 @@ __install_deps () set -xe +source /etc/os-release + # Install needed packages -stap-prep || __install_deps +if [ "$ID" == "fedora" ]; then + stap-prep || __fedora_install_deps +fi stap-prep # Report installed packages diff --git a/tests/Regression/python-probing/runtest.sh b/tests/Regression/python-probing/runtest.sh index 80f10f9..81ffd9e 100755 --- a/tests/Regression/python-probing/runtest.sh +++ b/tests/Regression/python-probing/runtest.sh @@ -50,8 +50,10 @@ rlJournalStart rlRun "pushd $TmpDir" # Install needed debuginfo, best effort + rlLogInfo "DEBUGINFOD_URLS=$DEBUGINFOD_URLS" + rlLogInfo "DEBUGINFOD_TIMEOUT=$DEBUGINFOD_TIMEOUT" rlRun "L=$(stap -p2 -e 'probe python.function.entry {exit()}' | awk -F\" '/process/ {print $2}')" 0-255 - rlRun "debuginfo-install -y $L" 0-255 + rlRun "debuginfo-install -y $L /usr/bin/python\*" 0-255 rlPhaseEnd rlPhaseStartTest "Verifying ELF file for presence of .probes section" diff --git a/tests/Regression/small-tests/runtest.sh b/tests/Regression/small-tests/runtest.sh index 13f898a..62d9fa8 100755 --- a/tests/Regression/small-tests/runtest.sh +++ b/tests/Regression/small-tests/runtest.sh @@ -31,11 +31,6 @@ PACKAGE="systemtap" -if echo $ID | grep -Fq fedora; then - export DEBUGINFOD_URLS="https://debuginfod.fedoraproject.org/ $DEBUGINFOD_URLS" - export DEBUGINFOD_TIMEOUT=300 -fi - _arch=$(arch) function perf_probe_failed () @@ -70,6 +65,8 @@ rlJournalStart rlRun "rpm -qa | egrep '^(kernel|systemtap|perf)' | sort" rlRun "uname -r" rlRun "perf --version" + rlLogInfo "DEBUGINFOD_URLS=$DEBUGINFOD_URLS" + rlLogInfo "DEBUGINFOD_TIMEOUT=$DEBUGINFOD_TIMEOUT" rlPhaseEnd # bz1162939 --------------------------------------------------- diff --git a/tests/Sanity/byteman-java-methods-probing/runtest.sh b/tests/Sanity/byteman-java-methods-probing/runtest.sh index f60f287..fe493da 100755 --- a/tests/Sanity/byteman-java-methods-probing/runtest.sh +++ b/tests/Sanity/byteman-java-methods-probing/runtest.sh @@ -29,11 +29,11 @@ # Include Beaker environment . /usr/share/beakerlib/beakerlib.sh || exit 1 -export DEBUGINFOD_URLS="https://debuginfod.fedoraproject.org/ $DEBUGINFOD_URLS" -export DEBUGINFOD_TIMEOUT=300 - rlJournalStart rlPhaseStartSetup + rlLogInfo "DEBUGINFOD_URLS=$DEBUGINFOD_URLS" + rlLogInfo "DEBUGINFOD_TIMEOUT=$DEBUGINFOD_TIMEOUT" + # At this point we simply rely on that the %triggerin scriptlet from # systemtap-runtime-java did it's job well. There was a hack to force # trigger it here, but commit respective to this comment removes it. diff --git a/tests/Sanity/quick-smoke-test/runtest.sh b/tests/Sanity/quick-smoke-test/runtest.sh index f04c2f1..9fdd72d 100755 --- a/tests/Sanity/quick-smoke-test/runtest.sh +++ b/tests/Sanity/quick-smoke-test/runtest.sh @@ -4,13 +4,10 @@ . /usr/share/beakerlib/beakerlib.sh || exit 1 -export DEBUGINFOD_URLS="https://debuginfod.fedoraproject.org/ $DEBUGINFOD_URLS" -export DEBUGINFOD_TIMEOUT=300 -# export DEBUGINFOD_PROGRESS=1 - - rlJournalStart rlPhaseStartTest + rlLogInfo "DEBUGINFOD_URLS=$DEBUGINFOD_URLS" + rlLogInfo "DEBUGINFOD_TIMEOUT=$DEBUGINFOD_TIMEOUT" rlRun "rpm -qa | egrep '^(kernel|systemtap)' | sort" rlRun "uname -r" rlRun "stap-prep" diff --git a/tests/Sanity/stap-server-basic-sanity/runtest.sh b/tests/Sanity/stap-server-basic-sanity/runtest.sh index e121a51..7c40bad 100755 --- a/tests/Sanity/stap-server-basic-sanity/runtest.sh +++ b/tests/Sanity/stap-server-basic-sanity/runtest.sh @@ -33,9 +33,6 @@ CMD='stap' BIN=$(which --skip-alias $CMD) PACKAGE="${PACKAGE:-$(rpm -qf --qf='%{name}\n' $BIN | head -1)}" -export DEBUGINFOD_URLS="https://debuginfod.fedoraproject.org/ $DEBUGINFOD_URLS" -export DEBUGINFOD_TIMEOUT=300 - function service_stap_server() { action=$1 retval=${2:-0} @@ -57,6 +54,8 @@ _rhelmajor=$(rpm --eval '%{rhel}') rlJournalStart rlPhaseStartSetup + rlLogInfo "DEBUGINFOD_URLS=$DEBUGINFOD_URLS" + rlLogInfo "DEBUGINFOD_TIMEOUT=$DEBUGINFOD_TIMEOUT" rlRun "TMPDIR=$(mktemp -d)" rlRun "pushd $TMPDIR" rlAssertRpm dbus diff --git a/tests/Sanity/userspace-probes/runtest.sh b/tests/Sanity/userspace-probes/runtest.sh index a25899b..32523dd 100755 --- a/tests/Sanity/userspace-probes/runtest.sh +++ b/tests/Sanity/userspace-probes/runtest.sh @@ -29,9 +29,6 @@ # Include Beaker environment . /usr/share/beakerlib/beakerlib.sh || exit 1 -export DEBUGINFOD_URLS="https://debuginfod.fedoraproject.org/ $DEBUGINFOD_URLS" -export DEBUGINFOD_TIMEOUT=300 - PACKAGE="$(rpm -qf $( which stap ) | head -n 1 )" WORKDIR=$( mktemp -d ) TESTUSER=mytestuser @@ -40,6 +37,8 @@ TESTUSER=mytestuser rlJournalStart rlPhaseStart WARN "Check the environment" + rlLogInfo "DEBUGINFOD_URLS=$DEBUGINFOD_URLS" + rlLogInfo "DEBUGINFOD_TIMEOUT=$DEBUGINFOD_TIMEOUT" if ! stap -V 2>&1 | grep -q 'enabled features:.*DYNINST'; then rlLogWarning "No dyninst available in $PACKAGE" rlPhaseEnd From 11422e39ad6dfbaee1331129755c77da72f287b7 Mon Sep 17 00:00:00 2001 From: Mark Wielaard Date: Fri, 19 May 2023 22:49:33 +0200 Subject: [PATCH 032/101] 4.9-2 - rebuilt for f39-build-side-67564 target --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index fd80232..ea788f4 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -123,7 +123,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE Version: 4.9 -Release: 1%{?release_override}%{?dist} +Release: 2%{?release_override}%{?dist} # for version, see also configure.ac @@ -1307,6 +1307,9 @@ exit 0 # PRERELEASE %changelog +* Fri May 19 2023 Mark Wielaard - 4.9-2 +- rebuilt for f39-build-side-67564 target + * Fri Apr 28 2023 Frank Ch. Eigler - 4.9-1 - Upstream release, see wiki page below for detailed notes. https://sourceware.org/systemtap/wiki/SystemTapReleases From 6464adf385fc5a254154d7deb83180a16205d2d7 Mon Sep 17 00:00:00 2001 From: Python Maint Date: Tue, 13 Jun 2023 23:29:35 +0200 Subject: [PATCH 033/101] Rebuilt for Python 3.12 --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index ea788f4..68fe71b 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -123,7 +123,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE Version: 4.9 -Release: 2%{?release_override}%{?dist} +Release: 3%{?release_override}%{?dist} # for version, see also configure.ac @@ -1307,6 +1307,9 @@ exit 0 # PRERELEASE %changelog +* Tue Jun 13 2023 Python Maint - 4.9-3 +- Rebuilt for Python 3.12 + * Fri May 19 2023 Mark Wielaard - 4.9-2 - rebuilt for f39-build-side-67564 target From 61a9dae5eae075d5451a80460dc29b98b9f60dce Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Tue, 4 Jul 2023 21:30:50 -0400 Subject: [PATCH 034/101] Automated weekly systemtap rawhide release: 5.0~pre16885197g6b17715f --- .gitignore | 1 + sources | 2 +- systemtap.spec | 40 ++++++++++++++++++++++------------------ 3 files changed, 24 insertions(+), 19 deletions(-) diff --git a/.gitignore b/.gitignore index 8865121..08f1a2f 100644 --- a/.gitignore +++ b/.gitignore @@ -85,3 +85,4 @@ /systemtap-4.8~pre16650659g6a096a7d.tar.gz /systemtap-4.8.tar.gz /systemtap-4.9.tar.gz +/systemtap-5.0~pre16885197g6b17715f.tar.gz diff --git a/sources b/sources index 6711998..915f875 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-4.9.tar.gz) = a2736223fee0c801c36719a0245f31ed7e2e63c30bb7d5cab631dd57e4eb10e04abf2c9b272bda2a17c207c9dd163a1eb8a3e0759eda0c781946e644625510b7 +SHA512 (systemtap-5.0~pre16885197g6b17715f.tar.gz) = e48a82409d43f55e837212b3ae918cd06b51cb5ef3a8eea2c36c3e6bc949b1266d3311cd965d7ccc9bd09f92b2a5260b795fae340000a624e34bba0f77360922 diff --git a/systemtap.spec b/systemtap.spec index 68fe71b..e00a1b4 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -122,8 +122,8 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 4.9 -Release: 3%{?release_override}%{?dist} +Version: 5.0~pre16885197g6b17715f +Release: 0.1%{?release_override}%{?dist} # for version, see also configure.ac @@ -156,9 +156,9 @@ Release: 3%{?release_override}%{?dist} # intermediary stap-server for --use-server: systemtap-server (-devel unused) Summary: Programmable system-wide instrumentation system -License: GPLv2+ +License: GPL-2.0-or-later URL: http://sourceware.org/systemtap/ -Source: ftp://sourceware.org/pub/systemtap/releases/systemtap-%{version}.tar.gz +Source: %{name}-%{version}.tar.gz # Build* BuildRequires: make @@ -262,7 +262,7 @@ the components needed to locally develop and execute systemtap scripts. %package server Summary: Instrumentation System Server -License: GPLv2+ +License: GPL-2.0-or-later URL: http://sourceware.org/systemtap/ Requires: systemtap-devel = %{version}-%{release} Conflicts: systemtap-devel < %{version}-%{release} @@ -292,7 +292,7 @@ compiles systemtap scripts to kernel objects on their demand. %package devel Summary: Programmable system-wide instrumentation system - development headers, tools -License: GPLv2+ +License: GPL-2.0-or-later AND GPL-2.0-only AND BSD-3-Clause AND LGPL-2.1-only URL: http://sourceware.org/systemtap/ %if 0%{?rhel} >= 8 || 0%{?fedora} >= 20 @@ -322,7 +322,7 @@ a copy of the standard tapset library and the runtime library C files. %package runtime Summary: Programmable system-wide instrumentation system - runtime -License: GPLv2+ +License: GPL-2.0-or-later URL: http://sourceware.org/systemtap/ Requires(pre): shadow-utils Conflicts: systemtap-devel < %{version}-%{release} @@ -337,7 +337,7 @@ using a local or remote systemtap-devel installation. %package client Summary: Programmable system-wide instrumentation system - client -License: GPLv2+ +License: GPL-2.0-or-later AND GPL-2.0-only AND BSD-3-Clause AND LGPL-2.1-only AND CC-BY AND GFDL-1.2-or-later AND GPL URL: http://sourceware.org/systemtap/ Requires: zip unzip Requires: systemtap-runtime = %{version}-%{release} @@ -360,7 +360,7 @@ documentation, and a copy of the tapset library for reference. %package initscript Summary: Systemtap Initscripts -License: GPLv2+ +License: GPL-2.0-or-later URL: http://sourceware.org/systemtap/ Requires: systemtap = %{version}-%{release} %if %{with_systemd} @@ -380,7 +380,7 @@ boot-time probing if supported. %package sdt-devel Summary: Static probe support tools -License: GPLv2+ and Public Domain +License: GPL-2.0-or-later AND CC0-1.0 URL: http://sourceware.org/systemtap/ %if %{with_pyparsing} %if %{with_python3} @@ -403,7 +403,7 @@ with the optional dtrace-compatibility preprocessor to process related %package testsuite Summary: Instrumentation System Testsuite -License: GPLv2+ +License: GPL-2.0-or-later AND GPL AND GPL-2.0-only AND GPL-3.0-or-later AND MIT URL: http://sourceware.org/systemtap/ Requires: systemtap = %{version}-%{release} Requires: systemtap-sdt-devel = %{version}-%{release} @@ -475,7 +475,7 @@ systemtap on the current system. %if %{with_java} %package runtime-java Summary: Systemtap Java Runtime Support -License: GPLv2+ +License: GPL-2.0-or-later URL: http://sourceware.org/systemtap/ Requires: systemtap-runtime = %{version}-%{release} # work around fedora ci gating kvetching about i686<->x86-64 conflicts @@ -497,7 +497,7 @@ that probe Java processes running on the OpenJDK runtimes using Byteman. %if %{with_python2_probes} %package runtime-python2 Summary: Systemtap Python 2 Runtime Support -License: GPLv2+ +License: GPL-2.0-or-later URL: http://sourceware.org/systemtap/ Requires: systemtap-runtime = %{version}-%{release} @@ -509,7 +509,7 @@ that probe python 2 processes. %if %{with_python3_probes} %package runtime-python3 Summary: Systemtap Python 3 Runtime Support -License: GPLv2+ +License: GPL-2.0-or-later URL: http://sourceware.org/systemtap/ Requires: systemtap-runtime = %{version}-%{release} @@ -526,7 +526,7 @@ that probe python 3 processes. %if %{with_python3_probes} %package exporter Summary: Systemtap-prometheus interoperation mechanism -License: GPLv2+ +License: GPL-2.0-or-later URL: http://sourceware.org/systemtap/ Requires: systemtap-runtime = %{version}-%{release} @@ -539,7 +539,7 @@ to remote requesters on demand. %if %{with_virthost} %package runtime-virthost Summary: Systemtap Cross-VM Instrumentation - host -License: GPLv2+ +License: GPL-2.0-or-later URL: http://sourceware.org/systemtap/ # only require libvirt-libs really #Requires: libvirt >= 1.0.2 @@ -554,7 +554,7 @@ connection. %if %{with_virtguest} %package runtime-virtguest Summary: Systemtap Cross-VM Instrumentation - guest -License: GPLv2+ +License: GPL-2.0-or-later URL: http://sourceware.org/systemtap/ Requires: systemtap-runtime = %{version}-%{release} %if %{with_systemd} @@ -575,7 +575,7 @@ systemtap-runtime-virthost machine to execute systemtap scripts. %if %{with_python3} && %{with_monitor} %package jupyter Summary: ISystemtap jupyter kernel and examples -License: GPLv2+ +License: GPL-2.0-or-later URL: http://sourceware.org/systemtap/ Requires: systemtap = %{version}-%{release} @@ -1307,6 +1307,10 @@ exit 0 # PRERELEASE %changelog +* Tue Jul 04 2023 Frank Ch. Eigler - 5.0-16885197g6b17715f +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Tue Jun 13 2023 Python Maint - 4.9-3 - Rebuilt for Python 3.12 From 6c6cf1bcac99e5f664023835514d5a1569042c2b Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Tue, 4 Jul 2023 22:17:16 -0400 Subject: [PATCH 035/101] Automated weekly systemtap rawhide release: 5.0~pre16885234gd98d6c2d --- .gitignore | 1 + sources | 2 +- systemtap.spec | 9 +++++++-- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 08f1a2f..81a9ee2 100644 --- a/.gitignore +++ b/.gitignore @@ -86,3 +86,4 @@ /systemtap-4.8.tar.gz /systemtap-4.9.tar.gz /systemtap-5.0~pre16885197g6b17715f.tar.gz +/systemtap-5.0~pre16885234gd98d6c2d.tar.gz diff --git a/sources b/sources index 915f875..7c35ee1 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.0~pre16885197g6b17715f.tar.gz) = e48a82409d43f55e837212b3ae918cd06b51cb5ef3a8eea2c36c3e6bc949b1266d3311cd965d7ccc9bd09f92b2a5260b795fae340000a624e34bba0f77360922 +SHA512 (systemtap-5.0~pre16885234gd98d6c2d.tar.gz) = 6b3cf3ee5832caea75f3139ce909fb620d7f08ef96cdbd997844d78113f49e4288af9462c02eb27656ace4f72ed2bec2cf0d27e8d55da621d7246cb02c73c0c0 diff --git a/systemtap.spec b/systemtap.spec index e00a1b4..93c39dd 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -7,7 +7,8 @@ %ifarch ppc ppc64 %{sparc} %{mips} %{riscv} %{!?with_crash: %global with_crash 0} %else -%{!?with_crash: %global with_crash 1} +# rawhide crash-devel breakage rhbz2219728 +%{!?with_crash: %global with_crash 0} %endif %{!?with_rpm: %global with_rpm 1} %{!?elfutils_version: %global elfutils_version 0.179} @@ -122,7 +123,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.0~pre16885197g6b17715f +Version: 5.0~pre16885234gd98d6c2d Release: 0.1%{?release_override}%{?dist} # for version, see also configure.ac @@ -1307,6 +1308,10 @@ exit 0 # PRERELEASE %changelog +* Tue Jul 04 2023 Frank Ch. Eigler - 5.0-16885234gd98d6c2d +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Tue Jul 04 2023 Frank Ch. Eigler - 5.0-16885197g6b17715f - Automated weekly rawhide release - Applied spec changes from upstream git From f303d28d53df789ef8f6093421e219705f8da947 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Mon, 10 Jul 2023 15:47:14 -0400 Subject: [PATCH 036/101] Automated weekly systemtap rawhide release: 5.0~pre16890184ge891a37e --- .gitignore | 1 + sources | 2 +- systemtap.spec | 8 ++++++-- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 81a9ee2..21cb9f8 100644 --- a/.gitignore +++ b/.gitignore @@ -87,3 +87,4 @@ /systemtap-4.9.tar.gz /systemtap-5.0~pre16885197g6b17715f.tar.gz /systemtap-5.0~pre16885234gd98d6c2d.tar.gz +/systemtap-5.0~pre16890184ge891a37e.tar.gz diff --git a/sources b/sources index 7c35ee1..ec0a2ec 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.0~pre16885234gd98d6c2d.tar.gz) = 6b3cf3ee5832caea75f3139ce909fb620d7f08ef96cdbd997844d78113f49e4288af9462c02eb27656ace4f72ed2bec2cf0d27e8d55da621d7246cb02c73c0c0 +SHA512 (systemtap-5.0~pre16890184ge891a37e.tar.gz) = 64a480f24c0dd4e427c3fe8c4342d0d8e93055e43dcd188cc373fe207c9f8f287d96c5e1b85298245027bec3c331649e602281da356c6be5b5c3daf4f77d7281 diff --git a/systemtap.spec b/systemtap.spec index 93c39dd..8ffd1d6 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -123,7 +123,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.0~pre16885234gd98d6c2d +Version: 5.0~pre16890184ge891a37e Release: 0.1%{?release_override}%{?dist} # for version, see also configure.ac @@ -338,7 +338,7 @@ using a local or remote systemtap-devel installation. %package client Summary: Programmable system-wide instrumentation system - client -License: GPL-2.0-or-later AND GPL-2.0-only AND BSD-3-Clause AND LGPL-2.1-only AND CC-BY AND GFDL-1.2-or-later AND GPL +License: GPL-2.0-or-later AND GPL-2.0-only AND BSD-3-Clause AND LGPL-2.1-only AND GFDL-1.2-or-later URL: http://sourceware.org/systemtap/ Requires: zip unzip Requires: systemtap-runtime = %{version}-%{release} @@ -1308,6 +1308,10 @@ exit 0 # PRERELEASE %changelog +* Mon Jul 10 2023 Frank Ch. Eigler - 5.0-16890184ge891a37e +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Tue Jul 04 2023 Frank Ch. Eigler - 5.0-16885234gd98d6c2d - Automated weekly rawhide release - Applied spec changes from upstream git From 3be2cacf55b7611b76b6db6259c92be88a467b2a Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Tue, 11 Jul 2023 21:23:14 -0400 Subject: [PATCH 037/101] Automated weekly systemtap rawhide release: 5.0~pre16891249ge891a37e --- .gitignore | 1 + sources | 2 +- systemtap.spec | 6 +++++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 21cb9f8..0d6e652 100644 --- a/.gitignore +++ b/.gitignore @@ -88,3 +88,4 @@ /systemtap-5.0~pre16885197g6b17715f.tar.gz /systemtap-5.0~pre16885234gd98d6c2d.tar.gz /systemtap-5.0~pre16890184ge891a37e.tar.gz +/systemtap-5.0~pre16891249ge891a37e.tar.gz diff --git a/sources b/sources index ec0a2ec..aa57da6 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.0~pre16890184ge891a37e.tar.gz) = 64a480f24c0dd4e427c3fe8c4342d0d8e93055e43dcd188cc373fe207c9f8f287d96c5e1b85298245027bec3c331649e602281da356c6be5b5c3daf4f77d7281 +SHA512 (systemtap-5.0~pre16891249ge891a37e.tar.gz) = 3d912d0d00a9f1d74a9e062f3a0ea9042caa1363ad8987a4bd18906676734aa4f813490a714cdc31d257ce94aacf4f026e1ad43edf78e4a18bdd99f09e658f79 diff --git a/systemtap.spec b/systemtap.spec index 8ffd1d6..7d86db1 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -123,7 +123,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.0~pre16890184ge891a37e +Version: 5.0~pre16891249ge891a37e Release: 0.1%{?release_override}%{?dist} # for version, see also configure.ac @@ -1308,6 +1308,10 @@ exit 0 # PRERELEASE %changelog +* Tue Jul 11 2023 Frank Ch. Eigler - 5.0-16891249ge891a37e +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Mon Jul 10 2023 Frank Ch. Eigler - 5.0-16890184ge891a37e - Automated weekly rawhide release - Applied spec changes from upstream git From 92650f26477c01f55bb99aa78f96cc4999983d4e Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Sat, 22 Jul 2023 03:06:17 +0000 Subject: [PATCH 038/101] Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild Signed-off-by: Fedora Release Engineering --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index 7d86db1..cceff65 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -124,7 +124,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE Version: 5.0~pre16891249ge891a37e -Release: 0.1%{?release_override}%{?dist} +Release: 0.2%{?release_override}%{?dist} # for version, see also configure.ac @@ -1308,6 +1308,9 @@ exit 0 # PRERELEASE %changelog +* Sat Jul 22 2023 Fedora Release Engineering - 5.0~pre16891249ge891a37e-0.2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild + * Tue Jul 11 2023 Frank Ch. Eigler - 5.0-16891249ge891a37e - Automated weekly rawhide release - Applied spec changes from upstream git From b7cac72f196f1b5ac290e43df1d132277fb21163 Mon Sep 17 00:00:00 2001 From: William Cohen Date: Wed, 27 Sep 2023 16:30:49 -0400 Subject: [PATCH 039/101] Automated weekly systemtap rawhide release: 5.0~pre16958465gca71442b --- .gitignore | 1 + sources | 2 +- systemtap.spec | 27 +++++++++++---------------- 3 files changed, 13 insertions(+), 17 deletions(-) diff --git a/.gitignore b/.gitignore index 0d6e652..330cbec 100644 --- a/.gitignore +++ b/.gitignore @@ -89,3 +89,4 @@ /systemtap-5.0~pre16885234gd98d6c2d.tar.gz /systemtap-5.0~pre16890184ge891a37e.tar.gz /systemtap-5.0~pre16891249ge891a37e.tar.gz +/systemtap-5.0~pre16958465gca71442b.tar.gz diff --git a/sources b/sources index aa57da6..4d190e7 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.0~pre16891249ge891a37e.tar.gz) = 3d912d0d00a9f1d74a9e062f3a0ea9042caa1363ad8987a4bd18906676734aa4f813490a714cdc31d257ce94aacf4f026e1ad43edf78e4a18bdd99f09e658f79 +SHA512 (systemtap-5.0~pre16958465gca71442b.tar.gz) = 81ef14e8644fd509f2040089047bdbfec34ea709e44373e8e37e339d37e2be88534d3d7111469b1d8ff6552217acd35acb4c0977cfe565e9bfedf63c17ed4f0d diff --git a/systemtap.spec b/systemtap.spec index cceff65..2cb435f 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -46,7 +46,7 @@ %{!?with_sysusers: %global with_sysusers 0%{?fedora} >= 32 || 0%{?rhel} >= 9} # Virt is supported on these arches, even on el7, but it's not in core EL7 -%if 0%{?rhel} <= 7 +%if 0%{?rhel} && 0%{?rhel} <= 7 %ifarch ppc64le aarch64 %global with_virthost 0 %endif @@ -65,9 +65,6 @@ %else %if 0%{?rhel} >= 6 %define udevrulesdir /lib/udev/rules.d - %else - # RHEL5 - %define udevrulesdir /etc/udev/rules.d %endif %endif %endif @@ -84,11 +81,7 @@ %define dracutbindir %{_bindir} %endif -%if 0%{?rhel} == 6 - %{!?_rpmmacrodir: %define _rpmmacrodir /etc/rpm/} -%else - %{!?_rpmmacrodir: %define _rpmmacrodir %{_rpmconfigdir}/macros.d} -%endif +%{!?_rpmmacrodir: %define _rpmmacrodir %{_rpmconfigdir}/macros.d} # To avoid testsuite/*/*.stp has shebang which doesn't start with '/' %define __brp_mangle_shebangs_exclude_from .stp$ @@ -123,8 +116,8 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.0~pre16891249ge891a37e -Release: 0.2%{?release_override}%{?dist} +Version: 5.0~pre16958465gca71442b +Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -170,6 +163,7 @@ BuildRequires: pkgconfig(nss) BuildRequires: pkgconfig(avahi-client) %if %{with_debuginfod} BuildRequires: pkgconfig(libdebuginfod) +BuildRequires: pkgconfig(json-c) %endif %if %{with_dyninst} BuildRequires: dyninst-devel >= 10.0 @@ -221,9 +215,6 @@ BuildRequires: pkgconfig(libvirt) BuildRequires: pkgconfig(libxml-2.0) %endif BuildRequires: readline-devel -%if 0%{?rhel} <= 5 -BuildRequires: pkgconfig(ncurses) -%endif %if %{with_python2_probes} BuildRequires: python2-devel %if 0%{?fedora} >= 1 @@ -293,7 +284,7 @@ compiles systemtap scripts to kernel objects on their demand. %package devel Summary: Programmable system-wide instrumentation system - development headers, tools -License: GPL-2.0-or-later AND GPL-2.0-only AND BSD-3-Clause AND LGPL-2.1-only +License: GPL-2.0-or-later AND GPL-2.0-only AND BSD-3-Clause AND LGPL-2.1-only AND BSD-2-Clause URL: http://sourceware.org/systemtap/ %if 0%{?rhel} >= 8 || 0%{?fedora} >= 20 @@ -338,7 +329,7 @@ using a local or remote systemtap-devel installation. %package client Summary: Programmable system-wide instrumentation system - client -License: GPL-2.0-or-later AND GPL-2.0-only AND BSD-3-Clause AND LGPL-2.1-only AND GFDL-1.2-or-later +License: GPL-2.0-or-later AND GPL-2.0-only AND BSD-3-Clause AND LGPL-2.1-only AND GFDL-1.2-or-later AND BSD-2-Clause URL: http://sourceware.org/systemtap/ Requires: zip unzip Requires: systemtap-runtime = %{version}-%{release} @@ -1308,6 +1299,10 @@ exit 0 # PRERELEASE %changelog +* Wed Sep 27 2023 William Cohen - 5.0-16958465gca71442b +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Sat Jul 22 2023 Fedora Release Engineering - 5.0~pre16891249ge891a37e-0.2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild From 5d53a19f79ac677e4513ca87346810b3fcdecd80 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Fri, 13 Oct 2023 23:05:42 +0200 Subject: [PATCH 040/101] Fix Regression/ipv6-tapset-support for modern Fedoras --- tests/Regression/ipv6-tapset-support/runtest.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/Regression/ipv6-tapset-support/runtest.sh b/tests/Regression/ipv6-tapset-support/runtest.sh index 5e8fb68..307b6b1 100755 --- a/tests/Regression/ipv6-tapset-support/runtest.sh +++ b/tests/Regression/ipv6-tapset-support/runtest.sh @@ -28,6 +28,7 @@ # Include Beaker environment . /usr/share/beakerlib/beakerlib.sh || exit 1 +. /etc/os-release || exit 1 rlJournalStart rlPhaseStartSetup @@ -45,6 +46,7 @@ rlJournalStart sleep 5 NFS_SERVICE=nfs rlIsRHEL '>=8' && NFS_SERVICE=nfs-server + [ $ID == 'fedora' ] && test $VERSION_ID -ge 38 && NFS_SERVICE=nfs-server rlServiceStart $NFS_SERVICE sleep 10 rlRun "exportfs -ua" From 7e30728b5fd40a572c0560dc6fd2e9b55a2b81fb Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Sat, 4 Nov 2023 12:31:05 -0400 Subject: [PATCH 041/101] Upstream release 5.0 --- .gitignore | 1 + sources | 2 +- systemtap.spec | 40 +++++++--------------------------------- 3 files changed, 9 insertions(+), 34 deletions(-) diff --git a/.gitignore b/.gitignore index 330cbec..fc4e31c 100644 --- a/.gitignore +++ b/.gitignore @@ -90,3 +90,4 @@ /systemtap-5.0~pre16890184ge891a37e.tar.gz /systemtap-5.0~pre16891249ge891a37e.tar.gz /systemtap-5.0~pre16958465gca71442b.tar.gz +/systemtap-5.0.tar.gz diff --git a/sources b/sources index 4d190e7..9271007 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.0~pre16958465gca71442b.tar.gz) = 81ef14e8644fd509f2040089047bdbfec34ea709e44373e8e37e339d37e2be88534d3d7111469b1d8ff6552217acd35acb4c0977cfe565e9bfedf63c17ed4f0d +SHA512 (systemtap-5.0.tar.gz) = dc511a05e66abcbbd8c926973962751196180f3c571d0cd2a3b158ae367c5339ad32967a680ecd03224ab5f7ed2c55be7064867e4fb1b1cd7ea1cb21b2436e4c diff --git a/systemtap.spec b/systemtap.spec index 2cb435f..887455b 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -7,8 +7,7 @@ %ifarch ppc ppc64 %{sparc} %{mips} %{riscv} %{!?with_crash: %global with_crash 0} %else -# rawhide crash-devel breakage rhbz2219728 -%{!?with_crash: %global with_crash 0} +%{!?with_crash: %global with_crash 1} %endif %{!?with_rpm: %global with_rpm 1} %{!?elfutils_version: %global elfutils_version 0.179} @@ -116,7 +115,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.0~pre16958465gca71442b +Version: 5.0 Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -152,7 +151,7 @@ Release: 1%{?release_override}%{?dist} Summary: Programmable system-wide instrumentation system License: GPL-2.0-or-later URL: http://sourceware.org/systemtap/ -Source: %{name}-%{version}.tar.gz +Source: ftp://sourceware.org/pub/systemtap/releases/systemtap-%{version}.tar.gz # Build* BuildRequires: make @@ -400,7 +399,7 @@ URL: http://sourceware.org/systemtap/ Requires: systemtap = %{version}-%{release} Requires: systemtap-sdt-devel = %{version}-%{release} Requires: systemtap-server = %{version}-%{release} -Requires: dejagnu which elfutils grep nc +Requires: dejagnu which elfutils grep nc wget %if %{with_debuginfod} Requires: elfutils-debuginfod %endif @@ -1299,34 +1298,9 @@ exit 0 # PRERELEASE %changelog -* Wed Sep 27 2023 William Cohen - 5.0-16958465gca71442b -- Automated weekly rawhide release -- Applied spec changes from upstream git - -* Sat Jul 22 2023 Fedora Release Engineering - 5.0~pre16891249ge891a37e-0.2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild - -* Tue Jul 11 2023 Frank Ch. Eigler - 5.0-16891249ge891a37e -- Automated weekly rawhide release -- Applied spec changes from upstream git - -* Mon Jul 10 2023 Frank Ch. Eigler - 5.0-16890184ge891a37e -- Automated weekly rawhide release -- Applied spec changes from upstream git - -* Tue Jul 04 2023 Frank Ch. Eigler - 5.0-16885234gd98d6c2d -- Automated weekly rawhide release -- Applied spec changes from upstream git - -* Tue Jul 04 2023 Frank Ch. Eigler - 5.0-16885197g6b17715f -- Automated weekly rawhide release -- Applied spec changes from upstream git - -* Tue Jun 13 2023 Python Maint - 4.9-3 -- Rebuilt for Python 3.12 - -* Fri May 19 2023 Mark Wielaard - 4.9-2 -- rebuilt for f39-build-side-67564 target +* Sat Nov 04 2023 Frank Ch. Eigler - 5.0-1 +- Upstream release, see wiki page below for detailed notes. + https://sourceware.org/systemtap/wiki/SystemTapReleases * Fri Apr 28 2023 Frank Ch. Eigler - 4.9-1 - Upstream release, see wiki page below for detailed notes. From 2a2af534e305045a58b25a67e699b4d7df8cb7e1 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Tue, 14 Nov 2023 17:51:38 -0500 Subject: [PATCH 042/101] Resolves: RHEL-16549, systemtap uprobe partial registration failure can cause crashes --- RHEL-16549.patch | 59 ++++++++++++++++++++++++++++++++++++++++++++++++ systemtap.spec | 11 ++++++++- 2 files changed, 69 insertions(+), 1 deletion(-) create mode 100644 RHEL-16549.patch diff --git a/RHEL-16549.patch b/RHEL-16549.patch new file mode 100644 index 0000000..4469759 --- /dev/null +++ b/RHEL-16549.patch @@ -0,0 +1,59 @@ +commit 0fef0bd60ff4b359a32da52262855dfe82fe51ae +gpg: Signature made Tue 14 Nov 2023 03:20:12 PM EST +gpg: using RSA key 4B35DCD2EA45C4E0783135BC8094BE9C9F4696A1 +gpg: Can't check signature: No public key +Author: Yichun Zhang (agentzh) +Date: Fri Nov 10 21:51:56 2023 -0800 + + PR31051: memory and uprobe leaks in early uprobe registraton code when errors happen + +diff --git a/runtime/linux/uprobes-inode.c b/runtime/linux/uprobes-inode.c +index 997f4528d..289cce00b 100644 +--- a/runtime/linux/uprobes-inode.c ++++ b/runtime/linux/uprobes-inode.c +@@ -529,6 +529,16 @@ stapiu_init(struct stapiu_consumer *consumers, size_t nconsumers) + } + + if (unlikely(ret != 0)) { ++ for ( ;; ) { ++ struct stapiu_consumer *c = &consumers[i]; ++ // protect against conceivable stapiu_refresh() at same time ++ mutex_lock(& c->consumer_lock); ++ stapiu_consumer_unreg(c); ++ mutex_unlock(& c->consumer_lock); ++ if (i == 0) ++ break; ++ i--; ++ } + return ret; + } + +@@ -545,7 +555,27 @@ stapiu_init(struct stapiu_consumer *consumers, size_t nconsumers) + break; + } + } +- return ret; ++ ++ if (unlikely(ret != 0)) { ++ int j; ++ for (j = 0; j < nconsumers; ++j) { ++ struct stapiu_consumer *c = &consumers[j]; ++ // protect against conceivable stapiu_refresh() at same time ++ mutex_lock(& c->consumer_lock); ++ stapiu_consumer_unreg(c); ++ mutex_unlock(& c->consumer_lock); ++ } ++ for ( ;; ) { ++ struct stapiu_consumer *c = &consumers[i]; ++ stap_cleanup_task_finder_target(&c->finder); ++ if (i == 0) ++ break; ++ i--; ++ } ++ return ret; ++ } ++ ++ return 0; + } + + diff --git a/systemtap.spec b/systemtap.spec index 887455b..0dbcffc 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -116,7 +116,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE Version: 5.0 -Release: 1%{?release_override}%{?dist} +Release: 3%{?release_override}%{?dist} # for version, see also configure.ac @@ -153,6 +153,8 @@ License: GPL-2.0-or-later URL: http://sourceware.org/systemtap/ Source: ftp://sourceware.org/pub/systemtap/releases/systemtap-%{version}.tar.gz +Patch1: RHEL-16549.patch + # Build* BuildRequires: make BuildRequires: gcc-c++ @@ -579,6 +581,7 @@ or within a container. %prep %setup -q +%patch -P1 -p1 %build @@ -1298,6 +1301,12 @@ exit 0 # PRERELEASE %changelog +* Tue Nov 14 2023 Frank Ch. Eigler - 5.0-3 +- RHEL-16549 + +* Mon Nov 06 2023 Frank Ch. Eigler - 5.0-2 +- License header tweak + * Sat Nov 04 2023 Frank Ch. Eigler - 5.0-1 - Upstream release, see wiki page below for detailed notes. https://sourceware.org/systemtap/wiki/SystemTapReleases From 1d4a6f14bb247c63c237a56ac9116852e5b9a228 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Fri, 24 Nov 2023 15:13:33 +0100 Subject: [PATCH 043/101] CI Tests: Robustify Regression/RHEL6Feature-cpp-backtraces --- .../golden-ppc64-17.out | 142 -------------- .../golden-ppc64.out | 76 -------- .../golden-s390x.out | 65 ------- .../golden.el9.aarch64.out | 153 --------------- .../golden.el9.ppc64le.out | 142 -------------- .../golden.el9.s390x.out | 153 --------------- .../golden.el9.x86_64.out | 153 --------------- .../golden.fc39.out | 153 --------------- .../RHEL6Feature-cpp-backtraces/golden.out | 175 ++++++------------ .../RHEL6Feature-cpp-backtraces/main.fmf | 1 - .../RHEL6Feature-cpp-backtraces/runtest.sh | 71 +------ 11 files changed, 63 insertions(+), 1221 deletions(-) delete mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/golden-ppc64-17.out delete mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/golden-ppc64.out delete mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/golden-s390x.out delete mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.aarch64.out delete mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.ppc64le.out delete mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.s390x.out delete mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.x86_64.out delete mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/golden.fc39.out diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden-ppc64-17.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden-ppc64-17.out deleted file mode 100644 index 1a9d1ce..0000000 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/golden-ppc64-17.out +++ /dev/null @@ -1,142 +0,0 @@ -publicB1 -privateB1 -publicA1 -publicA2 -privateA1 -privateA2 -recursiveA1: 3 -recursiveA1: 2 -recursiveA1: 1 -recursiveA1: 0 -================================================================================ -Probed function: [main] - -Backtrace: - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicB1] - -Backtrace: - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateB1] - -Backtrace: - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicA1] - -Backtrace: - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicA2] - -Backtrace: - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateA1] - -Backtrace: - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateA2] - -Backtrace: - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : generic_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden-ppc64.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden-ppc64.out deleted file mode 100644 index 0f98c88..0000000 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/golden-ppc64.out +++ /dev/null @@ -1,76 +0,0 @@ -publicB1 -privateB1 -publicA1 -publicA2 -privateA1 -privateA2 -recursiveA1: 3 -recursiveA1: 2 -recursiveA1: 1 -recursiveA1: 0 -================================================================================ -Probed function: [main] - -Backtrace: - ADDRESS : main+ADDRESS/ADDRESS [PATH] -[ADDRESS] [ADDRESS] ADDRESS (inexact) -================================================================================ -Probed function: [publicB1] - -Backtrace: - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] -[ADDRESS] [ADDRESS] ADDRESS (inexact) -================================================================================ -Probed function: [privateB1] - -Backtrace: - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] -[ADDRESS] [ADDRESS] ADDRESS (inexact) -================================================================================ -Probed function: [publicA1] - -Backtrace: - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] -[ADDRESS] [ADDRESS] ADDRESS (inexact) -================================================================================ -Probed function: [publicA2] - -Backtrace: - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] -[ADDRESS] [ADDRESS] ADDRESS (inexact) -================================================================================ -Probed function: [privateA1] - -Backtrace: - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] -[ADDRESS] [ADDRESS] ADDRESS (inexact) -================================================================================ -Probed function: [privateA2] - -Backtrace: - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] -[ADDRESS] [ADDRESS] ADDRESS (inexact) -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] -[ADDRESS] [ADDRESS] ADDRESS (inexact) -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] -[ADDRESS] [ADDRESS] ADDRESS (inexact) -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] -[ADDRESS] [ADDRESS] ADDRESS (inexact) -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] -[ADDRESS] [ADDRESS] ADDRESS (inexact) diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden-s390x.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden-s390x.out deleted file mode 100644 index 1f5f902..0000000 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/golden-s390x.out +++ /dev/null @@ -1,65 +0,0 @@ -publicB1 -privateB1 -publicA1 -publicA2 -privateA1 -privateA2 -recursiveA1: 3 -recursiveA1: 2 -recursiveA1: 1 -recursiveA1: 0 -================================================================================ -Probed function: [main] - -Backtrace: - ADDRESS : main+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicB1] - -Backtrace: - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateB1] - -Backtrace: - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicA1] - -Backtrace: - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicA2] - -Backtrace: - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateA1] - -Backtrace: - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateA2] - -Backtrace: - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.aarch64.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.aarch64.out deleted file mode 100644 index 15c7b1e..0000000 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.aarch64.out +++ /dev/null @@ -1,153 +0,0 @@ -publicB1 -privateB1 -publicA1 -publicA2 -privateA1 -privateA2 -recursiveA1: 3 -recursiveA1: 2 -recursiveA1: 1 -recursiveA1: 0 -================================================================================ -Probed function: [main] - -Backtrace: - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicB1] - -Backtrace: - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateB1] - -Backtrace: - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicA1] - -Backtrace: - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicA2] - -Backtrace: - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateA1] - -Backtrace: - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateA2] - -Backtrace: - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.ppc64le.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.ppc64le.out deleted file mode 100644 index 64f2232..0000000 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.ppc64le.out +++ /dev/null @@ -1,142 +0,0 @@ -publicB1 -privateB1 -publicA1 -publicA2 -privateA1 -privateA2 -recursiveA1: 3 -recursiveA1: 2 -recursiveA1: 1 -recursiveA1: 0 -================================================================================ -Probed function: [main] - -Backtrace: - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicB1] - -Backtrace: - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateB1] - -Backtrace: - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicA1] - -Backtrace: - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicA2] - -Backtrace: - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateA1] - -Backtrace: - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateA2] - -Backtrace: - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.17+ADDRESS/ADDRESS [PATH] diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.s390x.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.s390x.out deleted file mode 100644 index c0c1262..0000000 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.s390x.out +++ /dev/null @@ -1,153 +0,0 @@ -publicB1 -privateB1 -publicA1 -publicA2 -privateA1 -privateA2 -recursiveA1: 3 -recursiveA1: 2 -recursiveA1: 1 -recursiveA1: 0 -================================================================================ -Probed function: [main] - -Backtrace: - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicB1] - -Backtrace: - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateB1] - -Backtrace: - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicA1] - -Backtrace: - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicA2] - -Backtrace: - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateA1] - -Backtrace: - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateA2] - -Backtrace: - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.x86_64.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.x86_64.out deleted file mode 100644 index ac8d8c9..0000000 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.el9.x86_64.out +++ /dev/null @@ -1,153 +0,0 @@ -publicB1 -privateB1 -publicA1 -publicA2 -privateA1 -privateA2 -recursiveA1: 3 -recursiveA1: 2 -recursiveA1: 1 -recursiveA1: 0 -================================================================================ -Probed function: [main] - -Backtrace: - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicB1] - -Backtrace: - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateB1] - -Backtrace: - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicA1] - -Backtrace: - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicA2] - -Backtrace: - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateA1] - -Backtrace: - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateA2] - -Backtrace: - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.fc39.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.fc39.out deleted file mode 100644 index ac8d8c9..0000000 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.fc39.out +++ /dev/null @@ -1,153 +0,0 @@ -publicB1 -privateB1 -publicA1 -publicA2 -privateA1 -privateA2 -recursiveA1: 3 -recursiveA1: 2 -recursiveA1: 1 -recursiveA1: 0 -================================================================================ -Probed function: [main] - -Backtrace: - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicB1] - -Backtrace: - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateB1] - -Backtrace: - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicA1] - -Backtrace: - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [publicA2] - -Backtrace: - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateA1] - -Backtrace: - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [privateA2] - -Backtrace: - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] -================================================================================ -Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_call_main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main@GLIBC_2.2.5+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.out index 5013977..9f643d6 100644 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.out +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.out @@ -1,142 +1,77 @@ -publicB1 -privateB1 -publicA1 -publicA2 -privateA1 -privateA2 -recursiveA1: 3 -recursiveA1: 2 -recursiveA1: 1 -recursiveA1: 0 ================================================================================ Probed function: [main] - -Backtrace: - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] ================================================================================ Probed function: [publicB1] - -Backtrace: - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] +publicB1 ================================================================================ Probed function: [privateB1] - -Backtrace: - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] +privateB1 +publicB1 ================================================================================ Probed function: [publicA1] - -Backtrace: - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] +publicA1 +privateB1 +publicB1 ================================================================================ Probed function: [publicA2] - -Backtrace: - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] +publicA2 +publicA1 +privateB1 +publicB1 ================================================================================ Probed function: [privateA1] - -Backtrace: - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] +privateA1 +publicA2 +publicA1 +privateB1 +publicB1 ================================================================================ Probed function: [privateA2] - -Backtrace: - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] +privateA2 +privateA1 +publicA2 +publicA1 +privateB1 +publicB1 ================================================================================ Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] +recursiveA1 +privateA2 +privateA1 +publicA2 +publicA1 +privateB1 +publicB1 ================================================================================ Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] +recursiveA1 +recursiveA1 +privateA2 +privateA1 +publicA2 +publicA1 +privateB1 +publicB1 ================================================================================ Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] +recursiveA1 +recursiveA1 +recursiveA1 +privateA2 +privateA1 +publicA2 +publicA1 +privateB1 +publicB1 ================================================================================ Probed function: [recursiveA1] - -Backtrace: - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : recursiveA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA2+ADDRESS/ADDRESS [PATH] - ADDRESS : privateA1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA2+ADDRESS/ADDRESS [PATH] - ADDRESS : publicA1+ADDRESS/ADDRESS [PATH] - ADDRESS : privateB1+ADDRESS/ADDRESS [PATH] - ADDRESS : publicB1+ADDRESS/ADDRESS [PATH] - ADDRESS : main+ADDRESS/ADDRESS [PATH] - ADDRESS : __libc_start_main+ADDRESS/ADDRESS [PATH] - ADDRESS : _start+ADDRESS/ADDRESS [PATH] +recursiveA1 +recursiveA1 +recursiveA1 +recursiveA1 +privateA2 +privateA1 +publicA2 +publicA1 +privateB1 +publicB1 diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf b/tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf index 7b71ea0..88d542d 100644 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf @@ -8,7 +8,6 @@ framework: beakerlib recommend: - systemtap - gcc-c++ - - glibc-debuginfo duration: 10m extra-summary: /tools/systemtap/Regression/RHEL6Feature-cpp-backtraces extra-task: /tools/systemtap/Regression/RHEL6Feature-cpp-backtraces diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/runtest.sh b/tests/Regression/RHEL6Feature-cpp-backtraces/runtest.sh index a2ad6bc..629c082 100755 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/runtest.sh +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/runtest.sh @@ -32,36 +32,15 @@ PACKAGE="systemtap" -inputAs_rlLog(){ - while read line - do - rlLog "$line" - done -} - -compareAndLog(){ - rlAssertNotDiffer "$1" "$2" - if [ "$?" != "0" ] - then - rlLog "Difference:" - diff -u "$1" "$2" | inputAs_rlLog - fi -} - rlJournalStart rlPhaseStartSetup rlRun "g++ classes.cpp main.cpp -g -o classes" - rlAssertRpm glibc # show NVR - rlAssertRpm glibc-debuginfo rlRun "stap-prep" 0-255 rlPhaseEnd rlPhaseStartTest - rlRun "stap --ldd backtrackator.stp -c ./classes > output.out" - rlRun "cp output.out unprocessed.out" - rlLog "Processing output" - rlRun "sed -i -r -e 's/0x[0-9a-f]+/ADDRESS/g' output.out" + rlRun "stap --ldd backtrackator.stp -c ./classes -o output.out" rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*publicA1[A-Za-z0-9]*/publicA1/g' output.out" rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*publicA2[A-Za-z0-9]*/publicA2/g' output.out" rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*privateA1[A-Za-z0-9]*/privateA1/g' output.out" @@ -69,53 +48,19 @@ rlPhaseStartTest rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*recursiveA1[A-Za-z0-9]*/recursiveA1/g' output.out" rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*publicB1[A-Za-z0-9]*/publicB1/g' output.out" rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*privateB1[A-Za-z0-9]*/privateB1/g' output.out" - rlRun "sed -i -r -e 's!\[((.*\/.*)|(classes))\]!\[PATH\]!g' output.out" - # http://stackoverflow.com/questions/13963150/what-does-the-gcc-function-suffix-isra-mean - rlIsRHEL '>=' 7 && arch | grep -q ppc && \ - rlRun "sed -i 's/generic_start_main.isra.0/generic_start_main/' output.out" - - if rlIsRHEL '>=' 9; then - [[ "`uname -m`" =~ "ppc64" ]] && \ - rlRun "cat golden.el9.`arch`.out > golden-ppc64-17.out" || \ - rlRun "cat golden.el9.`arch`.out > golden.out" - fi - - if [ "$ID" == "fedora" ] && test "0$VERSION_ID" -ge 39; then - rlRun "cat golden.fc39.out > golden.out" - fi - - # RHEL-9 s390x runtime/stack-s390.c:63:52: error: ‘ASYNC_SIZE’ undeclared - # (PAGE_SIZE << 1) on stap side seems to work it around - - - if [ "`uname -m`" == "s390x" ] && ( rlIsRHEL 5 || rlIsRHEL 4 ) - then - rlLog "Detected we are running on: s390x && RHEL <= 5" - rlLog "Using special expected output" - compareAndLog golden-s390x.out output.out - elif [ "`uname -m`" == "ppc64" ] && ( rlIsRHEL 5 || rlIsRHEL 4 ) - then - rlLog "Detected we are running on: ppc64 && RHEL <= 5" - rlLog "Using special expected output" - compareAndLog golden-ppc64.out output.out - elif [[ "`uname -m`" =~ "ppc64" ]] - then - rlLog "Detected we are running on: ppc64" - rlLog "Using special expected output" - compareAndLog golden-ppc64-17.out output.out - else - rlLog "Detected we are running on: nothing special" - rlLog "Using generic expected output" - compareAndLog golden.out output.out - fi + rlRun "grep -o -e publicA1 -e publicA2 -e privateA1 -e privateA2 -e recursiveA1 \ + -e publicB1 -e privateB1 -e 'Probed function:.*' -e '=*' \ + output.out > output.processed" + rlRun "diff output.processed golden.out" rlPhaseEnd rlPhaseStartCleanup rlFileSubmit output.out + rlFileSubmit output.processed rlFileSubmit golden.out - rlFileSubmit unprocessed.out - rlRun "rm -f classes output.out unprocessed.out" + rlRun "rm -f output.out output.processed" rlPhaseEnd rlJournalPrintText + rlJournalEnd From 2783b620add162c3bdb0ac1c77589fcd4b3757d1 Mon Sep 17 00:00:00 2001 From: Jonathan Wakely Date: Thu, 18 Jan 2024 05:21:41 +0000 Subject: [PATCH 044/101] Rebuilt for Boost 1.83 --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index 0dbcffc..305a02f 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -116,7 +116,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE Version: 5.0 -Release: 3%{?release_override}%{?dist} +Release: 4%{?release_override}%{?dist} # for version, see also configure.ac @@ -1301,6 +1301,9 @@ exit 0 # PRERELEASE %changelog +* Thu Jan 18 2024 Jonathan Wakely - 5.0-4 +- Rebuilt for Boost 1.83 + * Tue Nov 14 2023 Frank Ch. Eigler - 5.0-3 - RHEL-16549 From 4aed2098f333a9f8b727198429e00b497ebd5d19 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Thu, 18 Jan 2024 16:07:50 -0500 Subject: [PATCH 045/101] Automated weekly systemtap rawhide release: 5.1~pre17056120g2ccc0c4c --- .gitignore | 1 + sources | 2 +- systemtap.spec | 18 ++++++++---------- 3 files changed, 10 insertions(+), 11 deletions(-) diff --git a/.gitignore b/.gitignore index fc4e31c..28c55e2 100644 --- a/.gitignore +++ b/.gitignore @@ -91,3 +91,4 @@ /systemtap-5.0~pre16891249ge891a37e.tar.gz /systemtap-5.0~pre16958465gca71442b.tar.gz /systemtap-5.0.tar.gz +/systemtap-5.1~pre17056120g2ccc0c4c.tar.gz diff --git a/sources b/sources index 9271007..72e684e 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.0.tar.gz) = dc511a05e66abcbbd8c926973962751196180f3c571d0cd2a3b158ae367c5339ad32967a680ecd03224ab5f7ed2c55be7064867e4fb1b1cd7ea1cb21b2436e4c +SHA512 (systemtap-5.1~pre17056120g2ccc0c4c.tar.gz) = 041814b0253e848145fa4ae192102aa793d50149b0d7fa2b18c3b0ce761d1a625b6ba9323a5807149f507952618b9e002ce9b101ed1aed32d720badf2f2bbbcf diff --git a/systemtap.spec b/systemtap.spec index 305a02f..806a4ed 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -115,8 +115,8 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.0 -Release: 4%{?release_override}%{?dist} +Version: 5.1~pre17056120g2ccc0c4c +Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -151,9 +151,7 @@ Release: 4%{?release_override}%{?dist} Summary: Programmable system-wide instrumentation system License: GPL-2.0-or-later URL: http://sourceware.org/systemtap/ -Source: ftp://sourceware.org/pub/systemtap/releases/systemtap-%{version}.tar.gz - -Patch1: RHEL-16549.patch +Source: %{name}-%{version}.tar.gz # Build* BuildRequires: make @@ -565,7 +563,6 @@ This package installs the services necessary on a virtual machine for a systemtap-runtime-virthost machine to execute systemtap scripts. %endif -%if %{with_python3} && %{with_monitor} %package jupyter Summary: ISystemtap jupyter kernel and examples License: GPL-2.0-or-later @@ -576,12 +573,11 @@ Requires: systemtap = %{version}-%{release} This package includes files needed to build and run the interactive systemtap Jupyter kernel, either locally or within a container. -%endif + # ------------------------------------------------------------------------ %prep %setup -q -%patch -P1 -p1 %build @@ -1283,14 +1279,12 @@ exit 0 %{_sbindir}/stap-exporter %endif -%if %{with_python3} && %{with_monitor} %files jupyter %{_bindir}/stap-jupyter-container %{_bindir}/stap-jupyter-install %{_mandir}/man1/stap-jupyter.1* %dir %{_datadir}/systemtap %{_datadir}/systemtap/interactive-notebook -%endif # ------------------------------------------------------------------------ @@ -1301,6 +1295,10 @@ exit 0 # PRERELEASE %changelog +* Thu Jan 18 2024 Frank Ch. Eigler - 5.1-17056120g2ccc0c4c +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Thu Jan 18 2024 Jonathan Wakely - 5.0-4 - Rebuilt for Boost 1.83 From d628fd39d2204a098f6cdf92f4458b2f08c7ae03 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Thu, 18 Jan 2024 16:39:40 -0500 Subject: [PATCH 046/101] Automated weekly systemtap rawhide release: 5.1~pre17056139g6c0b92b3 --- .gitignore | 1 + sources | 2 +- systemtap.spec | 6 +++++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 28c55e2..4e6fbf8 100644 --- a/.gitignore +++ b/.gitignore @@ -92,3 +92,4 @@ /systemtap-5.0~pre16958465gca71442b.tar.gz /systemtap-5.0.tar.gz /systemtap-5.1~pre17056120g2ccc0c4c.tar.gz +/systemtap-5.1~pre17056139g6c0b92b3.tar.gz diff --git a/sources b/sources index 72e684e..b63222c 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.1~pre17056120g2ccc0c4c.tar.gz) = 041814b0253e848145fa4ae192102aa793d50149b0d7fa2b18c3b0ce761d1a625b6ba9323a5807149f507952618b9e002ce9b101ed1aed32d720badf2f2bbbcf +SHA512 (systemtap-5.1~pre17056139g6c0b92b3.tar.gz) = 1b94a25246309dbe57804030636eb9e31999cfa69a74444447b2e9ba92d39c0be9aa60ca930e3545bec693d4de10d9f8a322a1009201fe6405522884385be421 diff --git a/systemtap.spec b/systemtap.spec index 806a4ed..ee4ab4f 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -115,7 +115,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.1~pre17056120g2ccc0c4c +Version: 5.1~pre17056139g6c0b92b3 Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -1295,6 +1295,10 @@ exit 0 # PRERELEASE %changelog +* Thu Jan 18 2024 Frank Ch. Eigler - 5.1-17056139g6c0b92b3 +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Thu Jan 18 2024 Frank Ch. Eigler - 5.1-17056120g2ccc0c4c - Automated weekly rawhide release - Applied spec changes from upstream git From 086a7444b9cc4da3cb761af65adaee6e665d4539 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Mon, 22 Jan 2024 10:44:38 -0500 Subject: [PATCH 047/101] Automated weekly systemtap rawhide release: 5.1~pre17059382g67086c54 --- .gitignore | 1 + sources | 2 +- systemtap.spec | 6 +++++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 4e6fbf8..ec9c3d3 100644 --- a/.gitignore +++ b/.gitignore @@ -93,3 +93,4 @@ /systemtap-5.0.tar.gz /systemtap-5.1~pre17056120g2ccc0c4c.tar.gz /systemtap-5.1~pre17056139g6c0b92b3.tar.gz +/systemtap-5.1~pre17059382g67086c54.tar.gz diff --git a/sources b/sources index b63222c..9865f3c 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.1~pre17056139g6c0b92b3.tar.gz) = 1b94a25246309dbe57804030636eb9e31999cfa69a74444447b2e9ba92d39c0be9aa60ca930e3545bec693d4de10d9f8a322a1009201fe6405522884385be421 +SHA512 (systemtap-5.1~pre17059382g67086c54.tar.gz) = f3eb107638dd58edcd95aaebe670a22234c9651f7b66bf9df184e20d8da09efb7e77ef3866bb3ab7fdcdea6b0c1c6a3bfe02cbcab59d91ba6c6b09cf3576fd06 diff --git a/systemtap.spec b/systemtap.spec index ee4ab4f..1241d1a 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -115,7 +115,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.1~pre17056139g6c0b92b3 +Version: 5.1~pre17059382g67086c54 Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -1295,6 +1295,10 @@ exit 0 # PRERELEASE %changelog +* Mon Jan 22 2024 Frank Ch. Eigler - 5.1-17059382g67086c54 +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Thu Jan 18 2024 Frank Ch. Eigler - 5.1-17056139g6c0b92b3 - Automated weekly rawhide release - Applied spec changes from upstream git From f078b4cd797fbdae910e2ed8b0923eb082580175 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Tue, 23 Jan 2024 15:00:09 -0500 Subject: [PATCH 048/101] Automated weekly systemtap rawhide release: 5.1~pre17060399gb6abf4bd --- .gitignore | 1 + sources | 2 +- systemtap.spec | 17 +++++++++++++++-- 3 files changed, 17 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index ec9c3d3..1750e09 100644 --- a/.gitignore +++ b/.gitignore @@ -94,3 +94,4 @@ /systemtap-5.1~pre17056120g2ccc0c4c.tar.gz /systemtap-5.1~pre17056139g6c0b92b3.tar.gz /systemtap-5.1~pre17059382g67086c54.tar.gz +/systemtap-5.1~pre17060399gb6abf4bd.tar.gz diff --git a/sources b/sources index 9865f3c..fa9b102 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.1~pre17059382g67086c54.tar.gz) = f3eb107638dd58edcd95aaebe670a22234c9651f7b66bf9df184e20d8da09efb7e77ef3866bb3ab7fdcdea6b0c1c6a3bfe02cbcab59d91ba6c6b09cf3576fd06 +SHA512 (systemtap-5.1~pre17060399gb6abf4bd.tar.gz) = 3497f18350329a21384b0f9a4f4ead343a9f1c46878311e486d460566adb4269cb5ca5cd998ef7bab9a33ff8410d51435912895d05f36156af7d527ae196e773 diff --git a/systemtap.spec b/systemtap.spec index 1241d1a..f13e850 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -1,3 +1,5 @@ +# work around flakey gcc warnings +%{!?with_Werror: %global with_Werror 0} %{!?with_sqlite: %global with_sqlite 0%{?fedora} >= 17 || 0%{?rhel} >= 7} # prefer prebuilt docs %{!?with_docs: %global with_docs 0} @@ -115,7 +117,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.1~pre17059382g67086c54 +Version: 5.1~pre17060399gb6abf4bd Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -588,6 +590,13 @@ or within a container. %global dyninst_config --without-dyninst %endif +# Enable/disable the dyninst pure-userspace backend +%if %{with_Werror} +%global Werror_config --enable-Werror +%else +%global Werror_config --disable-Werror +%endif + # Enable/disable the sqlite coverage testing support %if %{with_sqlite} %global sqlite_config --enable-sqlite @@ -675,7 +684,7 @@ or within a container. # We don't ship compileworthy python code, just oddball samples %global py_auto_byte_compile 0 -%configure %{dyninst_config} %{sqlite_config} %{crash_config} %{docs_config} %{rpm_config} %{java_config} %{virt_config} %{dracut_config} %{python3_config} %{python2_probes_config} %{python3_probes_config} %{httpd_config} %{bpf_config} %{debuginfod_config} --disable-silent-rules --with-extra-version="rpm %{version}-%{release}" +%configure %{Werror_config} %{dyninst_config} %{sqlite_config} %{crash_config} %{docs_config} %{rpm_config} %{java_config} %{virt_config} %{dracut_config} %{python3_config} %{python2_probes_config} %{python3_probes_config} %{httpd_config} %{bpf_config} %{debuginfod_config} --disable-silent-rules --with-extra-version="rpm %{version}-%{release}" make %{?_smp_mflags} V=1 @@ -1295,6 +1304,10 @@ exit 0 # PRERELEASE %changelog +* Tue Jan 23 2024 Frank Ch. Eigler - 5.1-17060399gb6abf4bd +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Mon Jan 22 2024 Frank Ch. Eigler - 5.1-17059382g67086c54 - Automated weekly rawhide release - Applied spec changes from upstream git From 0cecbe69662aaa6702db2d86f1a8ec4a80044152 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Thu, 25 Jan 2024 14:39:53 -0500 Subject: [PATCH 049/101] Automated weekly systemtap rawhide release: 5.1~pre17062114g2604d135 --- .gitignore | 1 + sources | 2 +- systemtap.spec | 6 +++++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 1750e09..6cf97f7 100644 --- a/.gitignore +++ b/.gitignore @@ -95,3 +95,4 @@ /systemtap-5.1~pre17056139g6c0b92b3.tar.gz /systemtap-5.1~pre17059382g67086c54.tar.gz /systemtap-5.1~pre17060399gb6abf4bd.tar.gz +/systemtap-5.1~pre17062114g2604d135.tar.gz diff --git a/sources b/sources index fa9b102..0ebae3c 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.1~pre17060399gb6abf4bd.tar.gz) = 3497f18350329a21384b0f9a4f4ead343a9f1c46878311e486d460566adb4269cb5ca5cd998ef7bab9a33ff8410d51435912895d05f36156af7d527ae196e773 +SHA512 (systemtap-5.1~pre17062114g2604d135.tar.gz) = 6a831321928b2eff0a0a9828f73c913b9982aa1ee2764dfc5e332fe0c54ca5a6fe5efd28b1613d253693128fb46d2ba1596adf12be0c7a602c07dac3b2e65746 diff --git a/systemtap.spec b/systemtap.spec index f13e850..c3ff4b9 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -117,7 +117,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.1~pre17060399gb6abf4bd +Version: 5.1~pre17062114g2604d135 Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -1304,6 +1304,10 @@ exit 0 # PRERELEASE %changelog +* Thu Jan 25 2024 Frank Ch. Eigler - 5.1-17062114g2604d135 +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Tue Jan 23 2024 Frank Ch. Eigler - 5.1-17060399gb6abf4bd - Automated weekly rawhide release - Applied spec changes from upstream git From 9c100ef16f705e343f967ddfa7dd83f4aa1207eb Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Thu, 25 Jan 2024 15:04:14 -0500 Subject: [PATCH 050/101] restore SPDX %changelog blurb --- systemtap.spec | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index c3ff4b9..eb24d2f 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -1336,7 +1336,8 @@ exit 0 * Sat Nov 04 2023 Frank Ch. Eigler - 5.0-1 - Upstream release, see wiki page below for detailed notes. https://sourceware.org/systemtap/wiki/SystemTapReleases - +- migrated to SPDX license + * Fri Apr 28 2023 Frank Ch. Eigler - 4.9-1 - Upstream release, see wiki page below for detailed notes. https://sourceware.org/systemtap/wiki/SystemTapReleases From 5c095346d451422dac8fdc1f3728ab9672461af6 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Thu, 25 Jan 2024 16:38:34 -0500 Subject: [PATCH 051/101] Regression/PR16166/towers.c: gcc14 warning suppression --- tests/Regression/PR16166/towers.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/Regression/PR16166/towers.c b/tests/Regression/PR16166/towers.c index 6465bc4..f8a5a20 100644 --- a/tests/Regression/PR16166/towers.c +++ b/tests/Regression/PR16166/towers.c @@ -30,7 +30,7 @@ error (emsg) } void -makenull (s) +makenull (int s) { stack[s] = 0; } From 6b9b6584425192cb14a07a141361e5449c3265d6 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Thu, 25 Jan 2024 16:42:18 -0500 Subject: [PATCH 052/101] testsuite: adapt to "fgrep" deprecation Since for some reason upstream grep deprecated "fgrep", and for some reason fedora packagers followed suit, some these tests scripts fail with the goofy "fgrep: warning: fgrep is obsolescent; using grep -F" warning. --- .../runtest.sh | 2 +- tests/Regression/pass-4-failure-netfilter-examples/runtest.sh | 2 +- tests/Regression/semantic-errors-bz953776/runtest.sh | 2 +- tests/Regression/small-tests/runtest.sh | 2 +- tests/Regression/suspicious-RCU-usage/runtest.sh | 2 +- .../runtest.sh | 2 +- .../task-exe-file-results-in-an-file-struct-leak/runtest.sh | 4 ++-- tests/Sanity/byteman-java-methods-probing/runtest.sh | 2 +- tests/Sanity/userspace-probes/runtest.sh | 2 +- 9 files changed, 10 insertions(+), 10 deletions(-) diff --git a/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/runtest.sh b/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/runtest.sh index 4d3a759..4360d83 100755 --- a/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/runtest.sh +++ b/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/runtest.sh @@ -35,7 +35,7 @@ LOG2=$(mktemp) rlJournalStart rlPhaseStartTest - rlRun "mount | fgrep -i 'debugfs on'" + rlRun "mount | grep -F -i 'debugfs on'" rlRun "cat /sys/kernel/debug/tracing/tracing_on | grep '^1$'" rlRun "journalctl > $LOG1" rlRun "stap -g -k -v hellotrace.stp" diff --git a/tests/Regression/pass-4-failure-netfilter-examples/runtest.sh b/tests/Regression/pass-4-failure-netfilter-examples/runtest.sh index 2eed9af..a70a337 100755 --- a/tests/Regression/pass-4-failure-netfilter-examples/runtest.sh +++ b/tests/Regression/pass-4-failure-netfilter-examples/runtest.sh @@ -34,7 +34,7 @@ PACKAGE="systemtap" rlJournalStart rlPhaseStartSetup TESTS=$(mktemp) - rlRun "rpm -qa | fgrep systemtap-testsuite" + rlRun "rpm -qa | grep -F systemtap-testsuite" rlPhaseEnd rpm -qa | grep systemtap-testsuite | xargs rpm -ql \ diff --git a/tests/Regression/semantic-errors-bz953776/runtest.sh b/tests/Regression/semantic-errors-bz953776/runtest.sh index 28e9359..f88d195 100755 --- a/tests/Regression/semantic-errors-bz953776/runtest.sh +++ b/tests/Regression/semantic-errors-bz953776/runtest.sh @@ -140,7 +140,7 @@ EOF # gcc 8.2.1->8.3.1 change related to systemtap debuginfo regression in rhel-8.1.0, kernel -84 -> -85 # https://bugzilla.redhat.com/show_bug.cgi?id=1709831#c17 - # ( fgrep RESULT: /tmp/typescript | sort -u ) + # ( grep -F RESULT: /tmp/typescript | sort -u ) rlPhaseStart FAIL 'case-6' rlRun "stap $p -vp4 -e 'probe sunrpc.clnt.shutdown_client { println(servername) }'" rlPhaseEnd diff --git a/tests/Regression/small-tests/runtest.sh b/tests/Regression/small-tests/runtest.sh index 62d9fa8..b7446ec 100755 --- a/tests/Regression/small-tests/runtest.sh +++ b/tests/Regression/small-tests/runtest.sh @@ -181,7 +181,7 @@ rlJournalStart # Protected from elision -------------------------------------- rlPhaseStart FAIL "test 14 protected from elision" rlRun "stap -v -e 'probe nfs.fop.fsync {} probe begin {print(\"Protected from elision\")}' -c true |\ - fgrep 'Protected from elision'" + grep -F 'Protected from elision'" rlPhaseEnd # bz544207 ---------------------------------------------------- diff --git a/tests/Regression/suspicious-RCU-usage/runtest.sh b/tests/Regression/suspicious-RCU-usage/runtest.sh index bd11b63..8c8af00 100755 --- a/tests/Regression/suspicious-RCU-usage/runtest.sh +++ b/tests/Regression/suspicious-RCU-usage/runtest.sh @@ -42,7 +42,7 @@ rlJournalStart rlRun "diff $dmesg1 $dmesg2 |& tee $diff" # Reproduced on hpe-moonshot-02-c02.hpe1.lab.eng.bos.redhat.com # using kernel-4.18.0-167.el8.aarch64+debug and systemtap-4.2-1.el8.aarch64. - rlRun "fgrep -i rcu $diff" 1 + rlRun "grep -F -i rcu $diff" 1 rm $dmesg{1,2} $diff rlPhaseEnd rlJournalPrintText diff --git a/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/runtest.sh b/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/runtest.sh index aa64f4e..1a742f2 100755 --- a/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/runtest.sh +++ b/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/runtest.sh @@ -33,7 +33,7 @@ PACKAGE="systemtap" rlJournalStart rlPhaseStartTest EXTRA="" - arch | fgrep ppc64le && EXTRA='-P' + arch | grep -F ppc64le && EXTRA='-P' # We rely on (and check for) units to be kB rlRun "test \"$( awk '/KernelStack/ {print $3}' /proc/meminfo )\" == \"kB\"" diff --git a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/runtest.sh b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/runtest.sh index 0c4e643..67d8be4 100755 --- a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/runtest.sh +++ b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/runtest.sh @@ -33,10 +33,10 @@ PACKAGE="systemtap" rlJournalStart rlPhaseStartTest EXTRA='' - arch | fgrep ppc64le && EXTRA="-P" + arch | grep -F ppc64le && EXTRA="-P" rlRun "FILE_NR1=$(awk '{print $1}' /proc/sys/fs/file-nr)" REPRODUCER=reproducer.stp - rlRun "stap -g -w $EXTRA --dump-functions | fgrep task_exe_file || REPRODUCER=reproducer2.stp" + rlRun "stap -g -w $EXTRA --dump-functions | grep -F task_exe_file || REPRODUCER=reproducer2.stp" rlRun "stap -w $EXTRA $REPRODUCER -c 'bash ./trigger.sh' -o /dev/null" rlRun "FILE_NR2=$(awk '{print $1}' /proc/sys/fs/file-nr)" rlRun "test $((FILE_NR2 - 1000)) -le $FILE_NR1" diff --git a/tests/Sanity/byteman-java-methods-probing/runtest.sh b/tests/Sanity/byteman-java-methods-probing/runtest.sh index fe493da..aa424fc 100755 --- a/tests/Sanity/byteman-java-methods-probing/runtest.sh +++ b/tests/Sanity/byteman-java-methods-probing/runtest.sh @@ -39,7 +39,7 @@ rlJournalStart # trigger it here, but commit respective to this comment removes it. # https://bugzilla.redhat.com/show_bug.cgi?id=1732514#c11 - rlRun "rpm -qa | fgrep -e systemtap-runtime-java -e byteman -e openjdk | sort" + rlRun "rpm -qa | grep -F -e systemtap-runtime-java -e byteman -e openjdk | sort" rlRun "stap-prep" diff --git a/tests/Sanity/userspace-probes/runtest.sh b/tests/Sanity/userspace-probes/runtest.sh index 32523dd..ee0d0b1 100755 --- a/tests/Sanity/userspace-probes/runtest.sh +++ b/tests/Sanity/userspace-probes/runtest.sh @@ -48,7 +48,7 @@ rlJournalStart fi rlRun "useradd $TESTUSER" 0,9 rlRun "su $TESTUSER -c 'which stap'" - rlRun "rpm -qa | fgrep -e dyninst -e systemtap | sort" + rlRun "rpm -qa | grep -F -e dyninst -e systemtap | sort" rlPhaseEnd rlPhaseStartSetup From 756feba0634b0ee630a437a8490f9722debd4b18 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Thu, 25 Jan 2024 16:47:16 -0500 Subject: [PATCH 053/101] Automated weekly systemtap rawhide release: 5.1~pre17062192g5fd8daba --- .gitignore | 1 + sources | 2 +- systemtap.spec | 6 +++++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 6cf97f7..e64fe0a 100644 --- a/.gitignore +++ b/.gitignore @@ -96,3 +96,4 @@ /systemtap-5.1~pre17059382g67086c54.tar.gz /systemtap-5.1~pre17060399gb6abf4bd.tar.gz /systemtap-5.1~pre17062114g2604d135.tar.gz +/systemtap-5.1~pre17062192g5fd8daba.tar.gz diff --git a/sources b/sources index 0ebae3c..75bc5a4 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.1~pre17062114g2604d135.tar.gz) = 6a831321928b2eff0a0a9828f73c913b9982aa1ee2764dfc5e332fe0c54ca5a6fe5efd28b1613d253693128fb46d2ba1596adf12be0c7a602c07dac3b2e65746 +SHA512 (systemtap-5.1~pre17062192g5fd8daba.tar.gz) = 423b09c001a2446d807be9fb8b66226545dddb15e7e57af01780966b17af5e2d8c16f44ce3f77d9a884c4e64a379604f9fb493b2a0f5e6ae50d65de19d9af992 diff --git a/systemtap.spec b/systemtap.spec index eb24d2f..d22819b 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -117,7 +117,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.1~pre17062114g2604d135 +Version: 5.1~pre17062192g5fd8daba Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -1304,6 +1304,10 @@ exit 0 # PRERELEASE %changelog +* Thu Jan 25 2024 Frank Ch. Eigler - 5.1-17062192g5fd8daba +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Thu Jan 25 2024 Frank Ch. Eigler - 5.1-17062114g2604d135 - Automated weekly rawhide release - Applied spec changes from upstream git From 4ae6e4b0297b9afb948c9308e4e57d056d504587 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Thu, 25 Jan 2024 17:56:03 -0500 Subject: [PATCH 054/101] testsuite: adapt to "egrep" deprecation sigh --- tests/Regression/ipv6-tapset-support/runtest.sh | 2 +- tests/Regression/irq-vector-tracepoints/runtest.sh | 2 +- tests/Regression/pass-4-failure-netfilter-examples/runtest.sh | 2 +- tests/Regression/small-tests/runtest.sh | 2 +- .../syscall-get-arguments-returning-wrong-value/runtest.sh | 2 +- tests/Sanity/quick-smoke-test/runtest.sh | 2 +- tests/Sanity/userspace-probes/runtest.sh | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) diff --git a/tests/Regression/ipv6-tapset-support/runtest.sh b/tests/Regression/ipv6-tapset-support/runtest.sh index 307b6b1..a05d136 100755 --- a/tests/Regression/ipv6-tapset-support/runtest.sh +++ b/tests/Regression/ipv6-tapset-support/runtest.sh @@ -67,7 +67,7 @@ rlJournalStart rlRun "stap $EXTRA_SWITCHES -v -c 'mount -t nfs -v [::1]:$TMPD/A $TMPD/B' nfsd.proc.lookup.stp |& tee $STAPLOG" rlRun "umount $TMPD/B" rlRun "grep 'Unsupported Address Family' $STAPLOG" 1 - rlRun "egrep '^\[0000:0000:0000:0000:0000:0000:0000:0001\]:[0-9]+.*$(basename $TMPD)' $STAPLOG" + rlRun "grep -E '^\[0000:0000:0000:0000:0000:0000:0000:0001\]:[0-9]+.*$(basename $TMPD)' $STAPLOG" rlPhaseEnd rlPhaseStartCleanup diff --git a/tests/Regression/irq-vector-tracepoints/runtest.sh b/tests/Regression/irq-vector-tracepoints/runtest.sh index 9b88712..6f11faa 100755 --- a/tests/Regression/irq-vector-tracepoints/runtest.sh +++ b/tests/Regression/irq-vector-tracepoints/runtest.sh @@ -58,7 +58,7 @@ rlJournalStart rlRun "stap -vp4 -e 'probe kernel.trace(\"local_timer_entry\") {println(pp())}'" rlRun "stap -vp4 -e 'probe kernel.trace(\"reschedule_entry\") {println(pp())}'" else - if arch | egrep 'x86_64|i[36]86'; then + if arch | grep -E 'x86_64|i[36]86'; then rlLogError "$dir does not exist" else rlLogInfo "$dir does not exist" diff --git a/tests/Regression/pass-4-failure-netfilter-examples/runtest.sh b/tests/Regression/pass-4-failure-netfilter-examples/runtest.sh index a70a337..b2d8156 100755 --- a/tests/Regression/pass-4-failure-netfilter-examples/runtest.sh +++ b/tests/Regression/pass-4-failure-netfilter-examples/runtest.sh @@ -38,7 +38,7 @@ rlJournalStart rlPhaseEnd rpm -qa | grep systemtap-testsuite | xargs rpm -ql \ - | egrep 'netfilter_drop.stp|netfilter_summary.stp' \ + | grep -E 'netfilter_drop.stp|netfilter_summary.stp' \ | while read line; do rlPhaseStart FAIL "Testing $line" rlRun "stap -p4 $line -v -g TCP 1" && \ diff --git a/tests/Regression/small-tests/runtest.sh b/tests/Regression/small-tests/runtest.sh index b7446ec..b7b1477 100755 --- a/tests/Regression/small-tests/runtest.sh +++ b/tests/Regression/small-tests/runtest.sh @@ -62,7 +62,7 @@ function perf_found_none_of () rlJournalStart # Check the environment --------------------------------------- rlPhaseStart WARN "Check the environment" - rlRun "rpm -qa | egrep '^(kernel|systemtap|perf)' | sort" + rlRun "rpm -qa | grep -E '^(kernel|systemtap|perf)' | sort" rlRun "uname -r" rlRun "perf --version" rlLogInfo "DEBUGINFOD_URLS=$DEBUGINFOD_URLS" diff --git a/tests/Regression/syscall-get-arguments-returning-wrong-value/runtest.sh b/tests/Regression/syscall-get-arguments-returning-wrong-value/runtest.sh index 182d69c..2143280 100755 --- a/tests/Regression/syscall-get-arguments-returning-wrong-value/runtest.sh +++ b/tests/Regression/syscall-get-arguments-returning-wrong-value/runtest.sh @@ -31,7 +31,7 @@ ASMLINKAGE=''; -uname -m | egrep 'i[36]86' && \ +uname -m | grep -E 'i[36]86' && \ ASMLINKAGE='asmlinkage();' SCRIPT=$( mktemp ) diff --git a/tests/Sanity/quick-smoke-test/runtest.sh b/tests/Sanity/quick-smoke-test/runtest.sh index 9fdd72d..35f0313 100755 --- a/tests/Sanity/quick-smoke-test/runtest.sh +++ b/tests/Sanity/quick-smoke-test/runtest.sh @@ -8,7 +8,7 @@ rlJournalStart rlPhaseStartTest rlLogInfo "DEBUGINFOD_URLS=$DEBUGINFOD_URLS" rlLogInfo "DEBUGINFOD_TIMEOUT=$DEBUGINFOD_TIMEOUT" - rlRun "rpm -qa | egrep '^(kernel|systemtap)' | sort" + rlRun "rpm -qa | grep -E '^(kernel|systemtap)' | sort" rlRun "uname -r" rlRun "stap-prep" rlRun "stap -L 'process(\"stap\").mark(\"*\")' | grep pass" diff --git a/tests/Sanity/userspace-probes/runtest.sh b/tests/Sanity/userspace-probes/runtest.sh index ee0d0b1..52fb25d 100755 --- a/tests/Sanity/userspace-probes/runtest.sh +++ b/tests/Sanity/userspace-probes/runtest.sh @@ -78,7 +78,7 @@ rlJournalStart rlRun "cat $LOG" rlRun "grep '^\*\*\*\ exiting\ \*\*\*$' $LOG" - rlRun "egrep -i 'error|warning' $LOG" 1 + rlRun "grep -E -i 'error|warning' $LOG" 1 rlPhaseEnd rlPhaseStartCleanup From 63994d28433253160e90c796a30478dff8533fb0 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Wed, 21 Feb 2024 15:26:12 +0100 Subject: [PATCH 055/101] Align with modern FMF specs. --- plans/ci.fmf | 1 - tests/Regression/PR16166/main.fmf | 1 - tests/Regression/bz706185-various-build-and-run/main.fmf | 1 - tests/Regression/semantic-errors-bz953776/main.fmf | 1 - .../stapio-possible-circular-locking-dependency/main.fmf | 1 - 5 files changed, 5 deletions(-) diff --git a/plans/ci.fmf b/plans/ci.fmf index 50b4c14..c4e22c1 100644 --- a/plans/ci.fmf +++ b/plans/ci.fmf @@ -12,7 +12,6 @@ adjust: DEBUGINFOD_TIMEOUT: 300 discover: how: fmf - directory: tests prepare: - name: prepare how: shell diff --git a/tests/Regression/PR16166/main.fmf b/tests/Regression/PR16166/main.fmf index 091d481..ea62246 100644 --- a/tests/Regression/PR16166/main.fmf +++ b/tests/Regression/PR16166/main.fmf @@ -5,7 +5,6 @@ component: - systemtap test: ./runtest.sh framework: beakerlib -require: recommend: - valgrind - systemtap diff --git a/tests/Regression/bz706185-various-build-and-run/main.fmf b/tests/Regression/bz706185-various-build-and-run/main.fmf index 0e61577..147247a 100644 --- a/tests/Regression/bz706185-various-build-and-run/main.fmf +++ b/tests/Regression/bz706185-various-build-and-run/main.fmf @@ -5,7 +5,6 @@ component: - systemtap test: ./runtest.sh framework: beakerlib -require: recommend: - systemtap duration: 20m diff --git a/tests/Regression/semantic-errors-bz953776/main.fmf b/tests/Regression/semantic-errors-bz953776/main.fmf index 6b7baa3..0fa8521 100644 --- a/tests/Regression/semantic-errors-bz953776/main.fmf +++ b/tests/Regression/semantic-errors-bz953776/main.fmf @@ -5,7 +5,6 @@ component: - systemtap test: ./runtest.sh framework: beakerlib -require: recommend: - systemtap - perf diff --git a/tests/Regression/stapio-possible-circular-locking-dependency/main.fmf b/tests/Regression/stapio-possible-circular-locking-dependency/main.fmf index 9f075f8..eb2003e 100644 --- a/tests/Regression/stapio-possible-circular-locking-dependency/main.fmf +++ b/tests/Regression/stapio-possible-circular-locking-dependency/main.fmf @@ -5,7 +5,6 @@ component: - systemtap test: ./runtest.sh framework: beakerlib -require: recommend: - systemtap duration: 4h From 668b8dd42a9be335d41c2dfa38e2161259311bdc Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Wed, 17 Apr 2024 08:29:50 +0200 Subject: [PATCH 056/101] CI test updates - Add upstream testsuite tests/Regression/upstream-testsuite to the CI testplan. However, this one isn't a good measure for gating, because it is too complex and flaky. But it's good to have test results at hand. This testcase reports a failure only in case of an infrastructure problem. Individual .exp test failures are not a show stopper from the persp of the CI gating. - Add upstream systemtap build and install pseudo testcase. tests/Install/upstream-systemtap to the testplan. This one is disabled by default (in its main.fmf file). The point here is to be able to test with upstream version of systemtap in case a working fedora build isn't available. This is a helper for manual testing, although if enabled, it will do its job in the automated CI pipeline too. - Use FMF tag instead of tier attributes to define the testplan. - Testcase updates: * tests/Regression/second-command-not-captured * tests/Regression/python-probing --- tests/Install/upstream-systemtap/main.fmf | 51 +++++ tests/Install/upstream-systemtap/runtest.sh | 175 ++++++++++++++++++ tests/Regression/PR16166/main.fmf | 2 +- .../RHEL6Feature-cpp-backtraces/main.fmf | 2 +- .../RHEL6Feature-cpp-ctors-and-dtors/main.fmf | 2 +- .../RHEL6Feature-cpp-inheritance/main.fmf | 2 +- .../RHEL6Feature-cpp-methods/main.fmf | 2 +- .../main.fmf | 2 +- .../bz706185-various-build-and-run/main.fmf | 2 +- .../main.fmf | 2 +- .../main.fmf | 2 +- .../main.fmf | 2 +- tests/Regression/ipv6-tapset-support/main.fmf | 2 +- .../irq-vector-tracepoints/main.fmf | 2 +- tests/Regression/netdev-receive/main.fmf | 2 +- .../main.fmf | 2 +- tests/Regression/python-probing/main.fmf | 2 +- tests/Regression/python-probing/runtest.sh | 14 +- .../second-command-not-captured/main.fmf | 2 +- .../second-command-not-captured/runtest.sh | 12 ++ .../main.fmf | 2 +- .../semantic-errors-bz1062076/main.fmf | 2 +- .../semantic-errors-bz953776/main.fmf | 2 +- tests/Regression/small-tests/main.fmf | 2 +- .../main.fmf | 2 +- .../main.fmf | 2 +- .../Regression/suspicious-RCU-usage/main.fmf | 2 +- .../main.fmf | 2 +- .../main.fmf | 2 +- .../main.fmf | 2 +- tests/Regression/upstream-testsuite/main.fmf | 54 ++++++ .../my_environment_sanity.exp | 6 + .../Regression/upstream-testsuite/runtest.sh | 102 ++++++++++ tests/Regression/upstream-testsuite/trimsuite | 40 ++++ .../Regression/upstream-testsuite/watchdog.sh | 45 +++++ .../utrace-taskfinder-misses-events/main.fmf | 2 +- .../main.fmf | 2 +- .../byteman-java-methods-probing/main.fmf | 2 +- tests/Sanity/kernel-modules/main.fmf | 2 +- tests/Sanity/quick-smoke-test/main.fmf | 2 +- .../Sanity/stap-server-basic-sanity/main.fmf | 2 +- tests/Sanity/userspace-probes/main.fmf | 3 +- 42 files changed, 527 insertions(+), 39 deletions(-) create mode 100644 tests/Install/upstream-systemtap/main.fmf create mode 100755 tests/Install/upstream-systemtap/runtest.sh create mode 100644 tests/Regression/upstream-testsuite/main.fmf create mode 100644 tests/Regression/upstream-testsuite/my_environment_sanity.exp create mode 100755 tests/Regression/upstream-testsuite/runtest.sh create mode 100755 tests/Regression/upstream-testsuite/trimsuite create mode 100755 tests/Regression/upstream-testsuite/watchdog.sh diff --git a/tests/Install/upstream-systemtap/main.fmf b/tests/Install/upstream-systemtap/main.fmf new file mode 100644 index 0000000..2da67d7 --- /dev/null +++ b/tests/Install/upstream-systemtap/main.fmf @@ -0,0 +1,51 @@ +summary: Build fresh systemtap RPMs from gitcache +description: '' +contact: Martin Cermak +component: + - nothing +test: ./runtest.sh +framework: beakerlib +enabled: false +recommend: + - libstdc++ + - libstdc++-devel + - libstdc++-devel.x86_64 + - libgcc + - glibc-devel + - gcc-c++ + - kernel-devel + - kernel-headers + - git + - curl + - tar + - dejagnu + - elfutils-devel + - gettext + - gettext-devel + - nss-devel + - avahi-devel + - dyninst-devel + - libselinux-devel + - sqlite-devel + - json-c-devel + - ncurses-devel + - crash-devel + - rpm-devel + - rpm-build + - emacs + - jpackage-utils + - java-devel + - libvirt-devel + - libxml2-devel + - readline-devel + - python-devel + - python3-devel + - rpm-build + - python-setuptools + - python2-setuptools + - python2-pyparsing + - dyninst-devel + - elfutils-debuginfod-client-devel +duration: 8h +tag: fedora +order: 1 diff --git a/tests/Install/upstream-systemtap/runtest.sh b/tests/Install/upstream-systemtap/runtest.sh new file mode 100755 index 0000000..9c613a5 --- /dev/null +++ b/tests/Install/upstream-systemtap/runtest.sh @@ -0,0 +1,175 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Install/upstream-head +# Description: create RPMs from the upstream head and install them +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2014 Red Hat, Inc. +# +# This program is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation, either version 2 of +# the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see http://www.gnu.org/licenses/. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +PATCHURL=${PATCHURL:-https://147.251.27.2/~cermak} +PATCHNAME=${PATCHNAME:-PATCHPATCH7.patch} + +ORIGPWD=$( pwd ) + +# Allow use of debuginfod +# export DEBUGINFOD_URLS=http://debuginfod.usersys.redhat.com:3632/ +# export DEBUGINFOD_PROGRESS=1 + +# if [[ `arch` == *aarch* ]] || [[ `arch` == *s390* ]]; then +# # Definitely do not use debuginfod on aarch64 and s390 +# unset DEBUGINFOD_URLS +# fi + +# https://wiki.test.redhat.com/BaseOs/Tools/SystemTap +TARBALL='systemtap.tar.xz' +# GITCACHE="http://liver2.lab.eng.brq.redhat.com/mcermak/systemtap/gitcache/$TARBALL" +GITCACHE="http://10.43.134.134/systemtap/gitcache/$TARBALL" +export CLONE_CMD='git clone git://sourceware.org/git/systemtap.git' + +PKGMGR="yum --nogpgcheck --enablerepo=\*" +rpm -q dnf && PKGMGR="dnf --setopt=clean_requirements_on_remove=false --setopt=metadata_expire=99999999 --nobest --setopt=strict=0 --nogpgcheck --enablerepo=\*" + +PATCHSOURCES=no +echo $PWD | grep -qF 521-build-stap && PATCHSOURCES=yes +export PATCHSOURCES + +rlJournalStart + rlPhaseStartSetup + rlRun "MY_USER=stapbuilduser" + rlRun "getent passwd ${MY_USER} >/dev/null || useradd ${MY_USER}" + # Work around bz1936469 + rlRun "rpm -q python-unversioned-command && rpm -e python-unversioned-command ||:" + rlRun "env | sort" + rlLogInfo "PATCHSOURCES=$PATCHSOURCES" + rlPhaseEnd + + rlPhaseStart FAIL "Install deps" + rlRun "$PKGMGR clean all" + # rlRun "$PKGMGR -y update" + # rlRun "$PKGMGR -y install $RPM_REQS" + rlRun "$PKGMGR -y install --setopt=multilib_policy=all libgcc glibc-devel gcc-c++ libstdc++-devel" + rlPhaseEnd + + rlPhaseStart FAIL "Build RPMs and install them" + MY_HOME="/home/${MY_USER}" + MY_BUILD="${MY_HOME}/build" + rm -rf /tmp/stap-buildlog /tmp/stap-specfile /tmp/stap-rpms /tmp/stap-git-log +cat > ${MY_BUILD} <<-EOF +set -xe +echo '%_unpackaged_files_terminate_build 0' > ~/.rpmmacros +rm -rf systemtap +( echo attempt-1; $CLONE_CMD) || \ +( echo attempt-2; sleep 20; $CLONE_CMD ) || \ +( echo attempt-3; sleep 90; $CLONE_CMD ) +# tar -xJf /tmp/$TARBALL || curl $GITCACHE | tee /tmp/$TARBALL | tar -xJ +cd systemtap +if test -n "${CHECKOUT_COMMIT}"; then + echo "### ATTEMPTING TO CHECK OUT ${CHECKOUT_COMMIT} ###" + git checkout ${CHECKOUT_COMMIT} || exit 1 +else + echo "### NOT ATTEMPTING TO CHECK OUT SPECIFIC COMMIT ###" +fi +LASTCOMMIT=\$( git log -1 --format=format:'%ct.%h' ) +git log -20 --oneline > /tmp/stap-git-log +sed -i "s/%{?dist}/\.qetst\.\${LASTCOMMIT}%{?dist}/" systemtap.spec +sed -i "s/%{?release_override}//" systemtap.spec +sed -i 's/with_publican\ 1/with_publican\ 0/g' systemtap.spec +sed -i 's/with_docs\ 1/with_docs\ 0/g' systemtap.spec +sed -i 's/with_emacsvim\ 1/with_emacsvim\ 0/' systemtap.spec + +# NB: CONDITIONALLY APPLY THE PATCH +if [ "${PATCHSOURCES}" == "yes" ]; then + wget --no-check-certificate ${PATCHURL}/${PATCHNAME} + patch -p1 < ${PATCHNAME} +fi + +if [[ $(rpm --eval 0%{rhel}) -eq 7 ]]; then + # The upstream specfile tries to require dyninst-devel >= 10.1 on rhel7, which + # is not good for base rhel-7 package (devtoolset-9-dyninst is a special case). + # https://sourceware.org/git/gitweb.cgi?p=systemtap.git;a=blob;f=systemtap.spec;h=670e4010141f5c51e749743bace01815b5585213;hb=HEAD#l134 + sed -i 's/^BuildRequires: dyninst-devel.*/BuildRequires: dyninst-devel/' systemtap.spec + # RHEL-7 doesn't have dyninst on arches other than ppc64 (big endian) and x86_64. + if ! (arch | egrep -q '^(x86_64|ppc64)$'); then + # https://sourceware.org/git/gitweb.cgi?p=systemtap.git;a=blob;f=systemtap.spec;h=670e4010141f5c51e749743bace01815b5585213;hb=HEAD#l18 + sed -i 's/%{!?with_dyninst: %global with_dyninst 0.*/%{!?with_dyninst: %global with_dyninst 0}/' systemtap.spec + fi +fi +git config --global user.name "Martin Cermak" +git config --global user.email mcermak@redhat.com +git commit -am 'Disable publican and emacs, tweak Release.' +cat systemtap.spec > /tmp/stap-specfile +./configure --prefix=/dev/null +make rpm 2>&1 | tee /tmp/stap-buildlog +set +xe +EOF + rlRun "chown ${MY_USER}:${MY_USER} ${MY_BUILD}" + rlRun "su - ${MY_USER} -c 'bash ${MY_BUILD}'" || exit 1 + rlRun "RPMS=\"$( find ${MY_HOME}/rpmbuild/RPMS -type f -name '*rpm' -printf '%p ' )\"" + rlRun "mkdir -p /tmp/stap-rpms /home/stap-rpms" + rlRun "cp $RPMS /tmp/stap-rpms/" + rlRun "cp $RPMS /home/stap-rpms/" + rlRun "$PKGMGR remove -y systemtap-runtime-java systemtap-runtime-virthost \ + systemtap-testsuite systemtap-devel systemtap systemtap-initscript \ + systemtap-runtime systemtap-server systemtap-runtime-virtguest \ + systemtap-sdt-devel systemtap-client systemtap-debuginfo" 0,1 + rlRun "rm -rf /usr/share/systemtap" + rlRun "$PKGMGR clean all" + rlRun "$PKGMGR install -y ${RPMS}" + rlRun "rpm -qa | grep systemtap | sort" + # Test https://bugzilla.redhat.com/show_bug.cgi?id=2012907 + rlRun "rpm -V systemtap-runtime" + RPMVER=$(echo $RPMS | grep -o 'systemtap-[0-9]\+[^\ ]*' | grep -o '.*\.el[0-9]\+') + RPMDIR=/home/.systemtap-upstream-head-rpms/$RPMVER + rm -rf ${RPMDIR}; mkdir -p ${RPMDIR}; + rlRun "cp ${RPMS} ${RPMDIR}/" 0 "Keep built PRMS in ${RPMDIR}" + rlPhaseEnd + + rlPhaseStart WARN "Run stap-prep" + rlRun "rpm -qa | grep ^kernel | grep -v `uname -r` | grep -v headers | xargs rpm -e --nodeps" 0-255 + rlRun "stap-prep" 0-255 + rlPhaseEnd + + rlPhaseStart FAIL "Sanity Check" + rlRun "stap --version" + rlRun "which stap" + rlRun "stap -vve 'probe kernel.function(\"vfs_read\"){ log(\"hey!\"); exit() }'" + rlPhaseEnd + + rlPhaseStart WARN "Submit interesting bits" + rlFileSubmit '/tmp/stap-buildlog' + rlRun 'tar cf /tmp/stap-upstream-rpms.tar /tmp/stap-rpms' + rlRun 'xz /tmp/stap-upstream-rpms.tar' + rlFileSubmit '/tmp/stap-upstream-rpms.tar.xz' + rlRun "rm -rf /tmp/stap-upstream-rpms.tar.xz" + rlFileSubmit '/tmp/stap-specfile' + rlPhaseEnd + + rlPhaseStartCleanup + rlRun "userdel -f ${MY_USER}" + rlRun "rm -rf ${MY_HOME}" + rlPhaseEnd + +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/PR16166/main.fmf b/tests/Regression/PR16166/main.fmf index ea62246..43a9c05 100644 --- a/tests/Regression/PR16166/main.fmf +++ b/tests/Regression/PR16166/main.fmf @@ -13,4 +13,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1054962 extra-summary: /tools/systemtap/Regression/PR16166 extra-task: /tools/systemtap/Regression/PR16166 -tier: 1 +tag: fedora diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf b/tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf index 88d542d..e0b5ee9 100644 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf +++ b/tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf @@ -11,4 +11,4 @@ recommend: duration: 10m extra-summary: /tools/systemtap/Regression/RHEL6Feature-cpp-backtraces extra-task: /tools/systemtap/Regression/RHEL6Feature-cpp-backtraces -tier: 1 +tag: fedora diff --git a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/main.fmf b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/main.fmf index 880faad..940dae3 100644 --- a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/main.fmf +++ b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/main.fmf @@ -11,4 +11,4 @@ recommend: duration: 5m extra-summary: /tools/systemtap/Regression/RHEL6Feature-cpp-ctors-and-dtors extra-task: /tools/systemtap/Regression/RHEL6Feature-cpp-ctors-and-dtors -tier: 1 +tag: fedora diff --git a/tests/Regression/RHEL6Feature-cpp-inheritance/main.fmf b/tests/Regression/RHEL6Feature-cpp-inheritance/main.fmf index 901d4da..86d5648 100644 --- a/tests/Regression/RHEL6Feature-cpp-inheritance/main.fmf +++ b/tests/Regression/RHEL6Feature-cpp-inheritance/main.fmf @@ -11,4 +11,4 @@ recommend: duration: 10m extra-summary: /tools/systemtap/Regression/RHEL6Feature-cpp-inheritance extra-task: /tools/systemtap/Regression/RHEL6Feature-cpp-inheritance -tier: 1 +tag: fedora diff --git a/tests/Regression/RHEL6Feature-cpp-methods/main.fmf b/tests/Regression/RHEL6Feature-cpp-methods/main.fmf index 6e00402..e2d9c88 100644 --- a/tests/Regression/RHEL6Feature-cpp-methods/main.fmf +++ b/tests/Regression/RHEL6Feature-cpp-methods/main.fmf @@ -11,4 +11,4 @@ recommend: duration: 120m extra-summary: /tools/systemtap/Regression/RHEL6Feature-cpp-methods extra-task: /tools/systemtap/Regression/RHEL6Feature-cpp-methods -tier: 1 +tag: fedora diff --git a/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/main.fmf b/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/main.fmf index 5e7923c..7078911 100644 --- a/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/main.fmf +++ b/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/main.fmf @@ -12,4 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1572501 extra-summary: /tools/systemtap/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap extra-task: /tools/systemtap/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap -tier: 1 +tag: fedora diff --git a/tests/Regression/bz706185-various-build-and-run/main.fmf b/tests/Regression/bz706185-various-build-and-run/main.fmf index 147247a..44fc465 100644 --- a/tests/Regression/bz706185-various-build-and-run/main.fmf +++ b/tests/Regression/bz706185-various-build-and-run/main.fmf @@ -12,4 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=706185 extra-summary: /tools/systemtap/Regression/bz706185-various-build-and-run extra-task: /tools/systemtap/Regression/bz706185-various-build-and-run -tier: 1 +tag: fedora diff --git a/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/main.fmf b/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/main.fmf index ec48caf..5354545 100644 --- a/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/main.fmf +++ b/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/main.fmf @@ -13,4 +13,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=902739 extra-summary: /tools/systemtap/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code extra-task: /tools/systemtap/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code -tier: 1 +tag: fedora diff --git a/tests/Regression/elfutils-debuginfod-client-not-being-called/main.fmf b/tests/Regression/elfutils-debuginfod-client-not-being-called/main.fmf index 4d69c02..0b9f61b 100644 --- a/tests/Regression/elfutils-debuginfod-client-not-being-called/main.fmf +++ b/tests/Regression/elfutils-debuginfod-client-not-being-called/main.fmf @@ -12,4 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1778921 extra-summary: /tools/systemtap/Regression/elfutils-debuginfod-client-not-being-called extra-task: /tools/systemtap/Regression/elfutils-debuginfod-client-not-being-called -tier: 1 +tag: fedora diff --git a/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/main.fmf b/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/main.fmf index 371094d..370611b 100644 --- a/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/main.fmf +++ b/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/main.fmf @@ -12,4 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1810216 extra-summary: /tools/systemtap/Regression/ftrace-logging-tapset-not-working-as-expected-in extra-task: /tools/systemtap/Regression/ftrace-logging-tapset-not-working-as-expected-in -tier: 1 +tag: fedora diff --git a/tests/Regression/ipv6-tapset-support/main.fmf b/tests/Regression/ipv6-tapset-support/main.fmf index 48a9775..8104026 100644 --- a/tests/Regression/ipv6-tapset-support/main.fmf +++ b/tests/Regression/ipv6-tapset-support/main.fmf @@ -14,4 +14,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=822503 extra-summary: /tools/systemtap/Regression/ipv6-tapset-support extra-task: /tools/systemtap/Regression/ipv6-tapset-support -tier: 1 +tag: fedora diff --git a/tests/Regression/irq-vector-tracepoints/main.fmf b/tests/Regression/irq-vector-tracepoints/main.fmf index ff8a2c0..1093c2c 100644 --- a/tests/Regression/irq-vector-tracepoints/main.fmf +++ b/tests/Regression/irq-vector-tracepoints/main.fmf @@ -13,4 +13,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1020437 extra-summary: /tools/systemtap/Regression/irq-vector-tracepoints extra-task: /tools/systemtap/Regression/irq-vector-tracepoints -tier: 1 +tag: fedora diff --git a/tests/Regression/netdev-receive/main.fmf b/tests/Regression/netdev-receive/main.fmf index f0e45d8..a5e9730 100644 --- a/tests/Regression/netdev-receive/main.fmf +++ b/tests/Regression/netdev-receive/main.fmf @@ -12,4 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1518462 extra-summary: /tools/systemtap/Regression/netdev-receive extra-task: /tools/systemtap/Regression/netdev-receive -tier: 1 +tag: fedora diff --git a/tests/Regression/pass-4-failure-netfilter-examples/main.fmf b/tests/Regression/pass-4-failure-netfilter-examples/main.fmf index 4501cf6..b2fb5f9 100644 --- a/tests/Regression/pass-4-failure-netfilter-examples/main.fmf +++ b/tests/Regression/pass-4-failure-netfilter-examples/main.fmf @@ -14,4 +14,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1055778 extra-summary: /tools/systemtap/Regression/pass-4-failure-netfilter-examples extra-task: /tools/systemtap/Regression/pass-4-failure-netfilter-examples -tier: 1 +tag: fedora diff --git a/tests/Regression/python-probing/main.fmf b/tests/Regression/python-probing/main.fmf index f3abc74..4f5ca6b 100644 --- a/tests/Regression/python-probing/main.fmf +++ b/tests/Regression/python-probing/main.fmf @@ -19,4 +19,4 @@ recommend: duration: 15m extra-summary: /CoreOS/python/Sanity/systemtap extra-task: /CoreOS/python/Sanity/systemtap -tier: 1 +tag: fedora diff --git a/tests/Regression/python-probing/runtest.sh b/tests/Regression/python-probing/runtest.sh index 81ffd9e..c9cbc40 100755 --- a/tests/Regression/python-probing/runtest.sh +++ b/tests/Regression/python-probing/runtest.sh @@ -30,14 +30,11 @@ . /etc/os-release || exit 1 # Packages to be tested -PACKAGES="${PACKAGES:-python3}" +PACKAGES="${PACKAGES:-python2}" # Other required packages REQUIRES=${REQUIRES:-} # Binary name parametrized -PYTHON="${PYTHON:-python3}" - -package=$(rpm -qf --queryformat '%{name}\n' $(which $PYTHON)) -collection_path=$(which python | sed 's/\/usr\/bin\/python//') +PYTHON="${PYTHON:-python2}" rlJournalStart rlPhaseStartSetup @@ -57,7 +54,7 @@ rlJournalStart rlPhaseEnd rlPhaseStartTest "Verifying ELF file for presence of .probes section" - for lib in ${collection_path}/usr/lib*/libpython*.so.* ; do + for lib in /usr/lib*/libpython*.so.* ; do rlRun "eu-readelf -x .probes $lib" \ 0 "Checking for .probes section within $lib" done @@ -73,6 +70,11 @@ rlJournalStart rlRun "stap $script.stp -v -c \"$PYTHON test.py\" > $script" \ 0 "Testing with $script.stp" rlRun "tail -100 $script | col -b" 0 "Inspecting output" + # Checking for random in the list output (python3) + # stap -L 'process("/usr/lib*/libpython*.so*").mark("*")' + # no markers with python3. PViktori mentions that python3 + # is going to use JIT, and that will probably drop the + # markers entirely. rlRun "grep '/usr/lib.*python.*random.py' '$script'" \ 0 "Checking for random in the $script output" rlPhaseEnd diff --git a/tests/Regression/second-command-not-captured/main.fmf b/tests/Regression/second-command-not-captured/main.fmf index 5659f4b..6ade74e 100644 --- a/tests/Regression/second-command-not-captured/main.fmf +++ b/tests/Regression/second-command-not-captured/main.fmf @@ -14,4 +14,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1857749 extra-summary: /tools/systemtap/Regression/second-command-not-captured extra-task: /tools/systemtap/Regression/second-command-not-captured -tier: 1 +tag: fedora diff --git a/tests/Regression/second-command-not-captured/runtest.sh b/tests/Regression/second-command-not-captured/runtest.sh index 65a749f..3912665 100755 --- a/tests/Regression/second-command-not-captured/runtest.sh +++ b/tests/Regression/second-command-not-captured/runtest.sh @@ -31,6 +31,18 @@ PACKAGE="systemtap" rlJournalStart + rlPhaseStart "WARN" "Attempt to hack around possible ruby tapset problem" + rlRun "rpm -q ruby-libs" + if rpm -V ruby-libs; then + rlLogInfo "Skipping the hack attempt" + else + rlRun "dnf update ruby\* -y" + rlRun "dnf -y reinstall ruby-libs" + rlRun "rpm -q ruby-libs" + rlRun "rpm -V ruby-libs" + fi + rlPhaseEnd + rlPhaseStartTest rlLog "`which stap`" rlLog "`stap -V`" diff --git a/tests/Regression/semantic-error-nfs-proc-read_setup/main.fmf b/tests/Regression/semantic-error-nfs-proc-read_setup/main.fmf index 264e6e0..0ea2cab 100644 --- a/tests/Regression/semantic-error-nfs-proc-read_setup/main.fmf +++ b/tests/Regression/semantic-error-nfs-proc-read_setup/main.fmf @@ -12,4 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=884951 extra-summary: /tools/systemtap/Regression/semantic-error-nfs-proc-read_setup extra-task: /tools/systemtap/Regression/semantic-error-nfs-proc-read_setup -tier: 1 +tag: fedora diff --git a/tests/Regression/semantic-errors-bz1062076/main.fmf b/tests/Regression/semantic-errors-bz1062076/main.fmf index 4bf64fd..e5bcbbf 100644 --- a/tests/Regression/semantic-errors-bz1062076/main.fmf +++ b/tests/Regression/semantic-errors-bz1062076/main.fmf @@ -12,4 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1062076 extra-summary: /tools/systemtap/Regression/semantic-errors-bz1062076 extra-task: /tools/systemtap/Regression/semantic-errors-bz1062076 -tier: 1 +tag: fedora diff --git a/tests/Regression/semantic-errors-bz953776/main.fmf b/tests/Regression/semantic-errors-bz953776/main.fmf index 0fa8521..9dcb8c8 100644 --- a/tests/Regression/semantic-errors-bz953776/main.fmf +++ b/tests/Regression/semantic-errors-bz953776/main.fmf @@ -14,4 +14,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=953776 extra-summary: /tools/systemtap/Regression/semantic-errors-bz953776 extra-task: /tools/systemtap/Regression/semantic-errors-bz953776 -tier: 1 +tag: fedora diff --git a/tests/Regression/small-tests/main.fmf b/tests/Regression/small-tests/main.fmf index 1cad44e..4022009 100644 --- a/tests/Regression/small-tests/main.fmf +++ b/tests/Regression/small-tests/main.fmf @@ -12,4 +12,4 @@ recommend: duration: 100m extra-summary: /tools/systemtap/Regression/small-tests extra-task: /tools/systemtap/Regression/small-tests -tier: 1 +tag: fedora diff --git a/tests/Regression/stap-ERROR-Build-id-mismatch-with/main.fmf b/tests/Regression/stap-ERROR-Build-id-mismatch-with/main.fmf index 6e8560b..2a96a6c 100644 --- a/tests/Regression/stap-ERROR-Build-id-mismatch-with/main.fmf +++ b/tests/Regression/stap-ERROR-Build-id-mismatch-with/main.fmf @@ -12,4 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1566422 extra-summary: /tools/systemtap/Regression/stap-ERROR-Build-id-mismatch-with extra-task: /tools/systemtap/Regression/stap-ERROR-Build-id-mismatch-with -tier: 1 +tag: fedora diff --git a/tests/Regression/stapio-possible-circular-locking-dependency/main.fmf b/tests/Regression/stapio-possible-circular-locking-dependency/main.fmf index eb2003e..de6de2e 100644 --- a/tests/Regression/stapio-possible-circular-locking-dependency/main.fmf +++ b/tests/Regression/stapio-possible-circular-locking-dependency/main.fmf @@ -12,4 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1020207 extra-summary: /tools/systemtap/Regression/stapio-possible-circular-locking-dependency extra-task: /tools/systemtap/Regression/stapio-possible-circular-locking-dependency -tier: 1 +tag: fedora diff --git a/tests/Regression/suspicious-RCU-usage/main.fmf b/tests/Regression/suspicious-RCU-usage/main.fmf index ce7a968..aff4cb7 100644 --- a/tests/Regression/suspicious-RCU-usage/main.fmf +++ b/tests/Regression/suspicious-RCU-usage/main.fmf @@ -12,4 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1788662 extra-summary: /tools/systemtap/Regression/suspicious-RCU-usage extra-task: /tools/systemtap/Regression/suspicious-RCU-usage -tier: 1 +tag: fedora diff --git a/tests/Regression/syscall-get-arguments-returning-wrong-value/main.fmf b/tests/Regression/syscall-get-arguments-returning-wrong-value/main.fmf index 1199de4..12e3a31 100644 --- a/tests/Regression/syscall-get-arguments-returning-wrong-value/main.fmf +++ b/tests/Regression/syscall-get-arguments-returning-wrong-value/main.fmf @@ -13,4 +13,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1004059 extra-summary: /tools/systemtap/Regression/syscall-get-arguments-returning-wrong-value extra-task: /tools/systemtap/Regression/syscall-get-arguments-returning-wrong-value -tier: 1 +tag: fedora diff --git a/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/main.fmf b/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/main.fmf index 835c151..9713fb6 100644 --- a/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/main.fmf +++ b/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/main.fmf @@ -12,4 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1412691 extra-summary: /tools/systemtap/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak extra-task: /tools/systemtap/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak -tier: 1 +tag: fedora diff --git a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/main.fmf b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/main.fmf index ff05762..d3da75c 100644 --- a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/main.fmf +++ b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/main.fmf @@ -12,4 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1430861 extra-summary: /tools/systemtap/Regression/task-exe-file-results-in-an-file-struct-leak extra-task: /tools/systemtap/Regression/task-exe-file-results-in-an-file-struct-leak -tier: 1 +tag: fedora diff --git a/tests/Regression/upstream-testsuite/main.fmf b/tests/Regression/upstream-testsuite/main.fmf new file mode 100644 index 0000000..1bae9d8 --- /dev/null +++ b/tests/Regression/upstream-testsuite/main.fmf @@ -0,0 +1,54 @@ +summary: upstream-testsuite +enabled: true +component: + - systemtap +test: ./runtest.sh +framework: beakerlib +recommend: + - libstdc++ + - libstdc++-devel + - libgcc + - glibc-devel + - gcc-c++ + - kernel-devel + - kernel-headers + - git + - curl + - tar + - dejagnu + - elfutils-devel + - gettext + - gettext-devel + - nss-devel + - avahi-devel + - dyninst-devel + - libselinux-devel + - sqlite-devel + - json-c-devel + - ncurses-devel + - crash-devel + - rpm-devel + - emacs + - jpackage-utils + - java-devel + - libvirt-devel + - libxml2-devel + - readline-devel + - python-devel + - python3-devel + - rpm-build + - python-setuptools + - python2-setuptools + - python2-pyparsing + - dyninst-devel + - elfutils-debuginfod-client-devel +duration: 72h +tag: fedora +order: 9999 +# check: +# - how: watchdog +# interval: 2 +# reboot: true +# ping: true +# ping-packets: 1 +# ping-threshold: 3 diff --git a/tests/Regression/upstream-testsuite/my_environment_sanity.exp b/tests/Regression/upstream-testsuite/my_environment_sanity.exp new file mode 100644 index 0000000..0af241a --- /dev/null +++ b/tests/Regression/upstream-testsuite/my_environment_sanity.exp @@ -0,0 +1,6 @@ +set test "my_environment_sanity_test" + +environment_sanity_test +print_system_info + +pass $test diff --git a/tests/Regression/upstream-testsuite/runtest.sh b/tests/Regression/upstream-testsuite/runtest.sh new file mode 100755 index 0000000..2b7ba6d --- /dev/null +++ b/tests/Regression/upstream-testsuite/runtest.sh @@ -0,0 +1,102 @@ +#!/bin/bash +# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/systemtap/Regression/testsuite-upstream-raw +# Description: testsuite-upstream-raw +# Author: Martin Cermak +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2014 Red Hat, Inc. +# +# This program is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation, either version 2 of +# the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see http://www.gnu.org/licenses/. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +SUITERPM=${SUITERPM:-systemtap-testsuite} +SUITELOC=${SUITELOC:-/usr/share/systemtap/testsuite/} +PKGMGR=${PKGMGR:-dnf} +ORIGWD=$(pwd) + +export SUITELOC + +rlJournalStart + rlPhaseStart WARN "Install" + # Try to free disk space by uninstalling unneeded kernel packages + rlRun "rpm -qa | grep ^kernel | grep -v `uname -r` | grep -v headers | xargs rpm -e --nodeps" 0-255 + # https://github.com/teemtee/tmt/issues/2762 + # rlRun "$PKGMGR -y install --setopt=multilib_policy=all libstdc++ libgcc glibc-devel gcc-c++ libstdc++-devel" + rlRun "stap-prep" + rlPhaseEnd + + rlPhaseStartSetup + rlServiceStop firewalld + rlServiceStop iptables + rlServiceStop ip6tables + rlServiceStop kdump + rlServiceStart avahi-daemon + rlRun "sysctl -w kernel.panic=1" + rlRun "sysctl -w kernel.panic_on_oops=1" + rlPhaseEnd + + rlPhaseStart WARN "Info" + rlLogInfo "SUITERPM=${SUITERPM}" + rlLogInfo "SUITELOC=${SUITELOC}" + rlLogInfo "PKGMGR=${PKGMGR}" + rlRun "uname -a" + rlRun "rpm -q $SUITERPM" + rlRun "cat /etc/os-release" + rlRun "stap-report" + rlPhaseEnd + + rlPhaseStart FAIL "sanity check" + rlRun "stap -vve 'probe kernel.function(\"vfs_read\"){ log(\"hey!\"); exit() } probe timer.s(60){log(\"timeout\"); exit()}'" + rlPhaseEnd + + rlPhaseStartTest + rlRun "pushd $SUITELOC" + rlRun "$ORIGWD/trimsuite" + rm -f /tmp/stopwatchdog + $ORIGWD/watchdog.sh & + watchdog_pid=$! + + # Make sure we always have the system identification print_system_info() + # Work around removal of print_system_info() from environment_sanity.exp + rlRun "cp $ORIGWD/my_environment_sanity.exp $SUITELOC/systemtap/" + + # Test primary arch only. The CI test systems have notorious problems + # with repos having i686 and x86_64 packages whose NVRs do not match. + # It's a PITA. Work it around. + rlRun "sed -i '/^proc arch_compile_flags/,/^}/d' $SUITELOC/lib/compile_flags.exp" + rlRun "echo 'proc arch_compile_flags {} { return 1 }' >> $SUITELOC/lib/compile_flags.exp" + + rlRun "make installcheck 2>&1" 0-255 + touch /tmp/stopwatchdog + wait + rlPhaseEnd + + rlPhaseStartCleanup + rlServiceRestore firewalld + rlServiceRestore iptables + rlServiceRestore ip6tables + rlServiceRestore kdump + rlServiceRestore avahi-daemon + rlRun popd + rlPhaseEnd +rlJournalPrintText +rlJournalEnd diff --git a/tests/Regression/upstream-testsuite/trimsuite b/tests/Regression/upstream-testsuite/trimsuite new file mode 100755 index 0000000..a178cc0 --- /dev/null +++ b/tests/Regression/upstream-testsuite/trimsuite @@ -0,0 +1,40 @@ +#!/bin/bash + +set -xe + +cd /usr/share/systemtap/testsuite + +# Remove slow tests + +for i in systemtap.base/listing_mode_sanity.exp \ +systemtap.base/rlimit.exp \ +systemtap.onthefly/kprobes_onthefly.exp \ +systemtap.syscall/nd_syscall.exp \ +systemtap.syscall/tp_syscall.exp \ +systemtap.base/listing_mode.exp \ +systemtap.base/tracepoints_list.exp \ +systemtap.onthefly/hrtimer_onthefly.exp \ +systemtap.pass1-4/parse-semok.exp \ +systemtap.syscall/syscall.exp \ +systemtap.base/sdt_misc.exp \ +systemtap.base/sdt_buildid.exp \ +systemtap.pass1-4/buildok-interactive.exp \ +systemtap.unprivileged/unprivileged_myproc.exp \ +systemtap.pass1-4/buildok.exp \ +systemtap.examples/check.exp; do + rm -rf $i +done + +# # Remove whole directories +# +# for i in systemtap.analysis systemtap.apps systemtap.base systemtap.bpf \ +# systemtap.clone systemtap.context systemtap.examples systemtap.exelib \ +# systemtap.http_exporter systemtap.http_server systemtap.interactive \ +# systemtap.language_server systemtap.maps systemtap.onthefly systemtap.pass1-4 \ +# systemtap.printf systemtap.python systemtap.samples systemtap.server \ +# systemtap.speculate systemtap.stress systemtap.string systemtap.syscall \ +# systemtap.unprivileged; \ +# do +# echo $i | grep -q "systemtap.base" && continue +# rm -rf $i +# done diff --git a/tests/Regression/upstream-testsuite/watchdog.sh b/tests/Regression/upstream-testsuite/watchdog.sh new file mode 100755 index 0000000..c92de6d --- /dev/null +++ b/tests/Regression/upstream-testsuite/watchdog.sh @@ -0,0 +1,45 @@ +#!/bin/bash + +PROCESSES='stap staprun stapio' +TIMEOUT_MIN=17 +SUITELOC=${SUITELOC:-/root/build/testsuite} +LOG_PREFIX="WATCHDOG" +SIGNAL="-9" + +# set -x +killcount=0 +while true; do + date +"${LOG_PREFIX}: %a %F %H:%M: " | tr -d '\n' + echo "Alive (pid $$)" + for p in $PROCESSES; do + for pid in `pgrep $p`; do + test -f /proc/$pid/status || continue + grep -q "State.*zombie" /proc/$pid/status && continue + # echo "Checking process $p, pid $pid" + start_datetime=`ps --no-headers -o lstart -p $pid` + start_stamp=`date -d "$start_datetime" +"%s"` + now=`date +%s` + runtime=$(( (now - start_stamp) / 60 )) + # echo "Started $start_stamp, now is $now, tzn runtime=${runtime}min" + if test $runtime -ge $TIMEOUT_MIN; then + echo + grep '^Running' $SUITELOC/systemtap.sum | tail -3 | sed "s/.*/${LOG_PREFIX}: SUM:\ \0/" + tail -10 $SUITELOC/systemtap.log | sed "s/.*/${LOG_PREFIX}: LOG:\ \0/" + dmesg | tail -30 | sed "s/.*/${LOG_PREFIX}: DMESG:\ \0/" + date +"${LOG_PREFIX}: %a %F %H:%M: " | tr -d '\n' + echo -n "Checking process $p pid $pid, runtime $runtime min. " + if kill $SIGNAL $pid; then + killcount=$((killcount + 1)) + echo "Killed (killcount=$killcount)." + # Killing one process sometimes affects others, so + # we break and recollect the PIDs in next iteration. + break + else + echo "${LOG_PREFIX}: Kill attempted, but failed." + fi + fi + done + done + test -f /tmp/stopwatchdog && break + sleep 60 +done diff --git a/tests/Regression/utrace-taskfinder-misses-events/main.fmf b/tests/Regression/utrace-taskfinder-misses-events/main.fmf index 48771c2..a8fed74 100644 --- a/tests/Regression/utrace-taskfinder-misses-events/main.fmf +++ b/tests/Regression/utrace-taskfinder-misses-events/main.fmf @@ -14,4 +14,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=876848 extra-summary: /tools/systemtap/Regression/utrace-taskfinder-misses-events extra-task: /tools/systemtap/Regression/utrace-taskfinder-misses-events -tier: 1 +tag: fedora diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/main.fmf b/tests/Regression/wrong-data-returned-by-nfs-commit-done/main.fmf index fc2f518..2542286 100644 --- a/tests/Regression/wrong-data-returned-by-nfs-commit-done/main.fmf +++ b/tests/Regression/wrong-data-returned-by-nfs-commit-done/main.fmf @@ -12,4 +12,4 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=920444 extra-summary: /tools/systemtap/Regression/wrong-data-returned-by-nfs-commit-done extra-task: /tools/systemtap/Regression/wrong-data-returned-by-nfs-commit-done -tier: 1 +tag: fedora diff --git a/tests/Sanity/byteman-java-methods-probing/main.fmf b/tests/Sanity/byteman-java-methods-probing/main.fmf index 3717888..3e1dd29 100644 --- a/tests/Sanity/byteman-java-methods-probing/main.fmf +++ b/tests/Sanity/byteman-java-methods-probing/main.fmf @@ -10,4 +10,4 @@ recommend: duration: 15m extra-summary: /tools/systemtap/Sanity/byteman-java-methods-probing extra-task: /tools/systemtap/Sanity/byteman-java-methods-probing -tier: 1 +tag: fedora diff --git a/tests/Sanity/kernel-modules/main.fmf b/tests/Sanity/kernel-modules/main.fmf index b8d53e3..8fb98dc 100644 --- a/tests/Sanity/kernel-modules/main.fmf +++ b/tests/Sanity/kernel-modules/main.fmf @@ -15,4 +15,4 @@ recommend: duration: 10m extra-summary: /tools/systemtap/Sanity/kernel-modules extra-task: /tools/systemtap/Sanity/kernel-modules -tier: 1 +tag: fedora diff --git a/tests/Sanity/quick-smoke-test/main.fmf b/tests/Sanity/quick-smoke-test/main.fmf index 2b8ca3c..14f00ce 100644 --- a/tests/Sanity/quick-smoke-test/main.fmf +++ b/tests/Sanity/quick-smoke-test/main.fmf @@ -13,4 +13,4 @@ recommend: duration: 1h extra-summary: /tools/systemtap/Sanity/quick-smoke-test extra-task: /tools/systemtap/Sanity/quick-smoke-test -tier: 1 +tag: fedora diff --git a/tests/Sanity/stap-server-basic-sanity/main.fmf b/tests/Sanity/stap-server-basic-sanity/main.fmf index 7862ee2..84da959 100644 --- a/tests/Sanity/stap-server-basic-sanity/main.fmf +++ b/tests/Sanity/stap-server-basic-sanity/main.fmf @@ -15,4 +15,4 @@ recommend: duration: 45m extra-summary: /tools/systemtap/Sanity/stap-server-basic-sanity extra-task: /tools/systemtap/Sanity/stap-server-basic-sanity -tier: 1 +tag: fedora diff --git a/tests/Sanity/userspace-probes/main.fmf b/tests/Sanity/userspace-probes/main.fmf index a89344f..07fb48c 100644 --- a/tests/Sanity/userspace-probes/main.fmf +++ b/tests/Sanity/userspace-probes/main.fmf @@ -14,4 +14,5 @@ link: - relates: https://bugzilla.redhat.com/show_bug.cgi?id=855981 extra-summary: /CoreOS/systemtap/Sanity/userspace-probes extra-task: /CoreOS/systemtap/Sanity/userspace-probes -tier: 1 +enabled: true +tag: fedora From 87e8ee9d8801157148bc66d7108e662fe375ecbe Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Wed, 8 May 2024 08:04:34 +0200 Subject: [PATCH 057/101] CI tests: python probing: behave on rhel --- tests/Regression/python-probing/main.fmf | 30 +++++++++++++++--------- 1 file changed, 19 insertions(+), 11 deletions(-) diff --git a/tests/Regression/python-probing/main.fmf b/tests/Regression/python-probing/main.fmf index 4f5ca6b..de28f68 100644 --- a/tests/Regression/python-probing/main.fmf +++ b/tests/Regression/python-probing/main.fmf @@ -2,20 +2,28 @@ summary: Systemtap static probes test description: Systemtap static probes test contact: Petr Splichal component: -- python -- systemtap + - python + - systemtap test: ./runtest.sh framework: beakerlib recommend: -- python -- python-debuginfo -- python3-debuginfo -- python3.9-debuginfo -- systemtap -- python2 -- python3 -- elfutils -- yum-utils + - python + - python-debuginfo + - python3-debuginfo + - python3.9-debuginfo + - systemtap + - python2 + - python3 + - elfutils + - yum-utils +adjust: + - environment: + PYTHON: python + when: distro is defined and distro == rhel-9 + because: "Test with python (i.e. python3) on rhel-9" + - enabled: false + when: distro is defined and distro == rhel-10 + because: "Test not relevant for rhel10" duration: 15m extra-summary: /CoreOS/python/Sanity/systemtap extra-task: /CoreOS/python/Sanity/systemtap From 11f44c8ba2740c5c6632cbc808b585b6fe9611d7 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Wed, 8 May 2024 08:22:55 +0200 Subject: [PATCH 058/101] CI tests: Regression/small-tests update --- tests/Regression/small-tests/main.fmf | 1 + tests/Regression/small-tests/runtest.sh | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/tests/Regression/small-tests/main.fmf b/tests/Regression/small-tests/main.fmf index 4022009..ff53860 100644 --- a/tests/Regression/small-tests/main.fmf +++ b/tests/Regression/small-tests/main.fmf @@ -9,6 +9,7 @@ recommend: - systemtap - systemtap-testsuite - perf +- psmisc duration: 100m extra-summary: /tools/systemtap/Regression/small-tests extra-task: /tools/systemtap/Regression/small-tests diff --git a/tests/Regression/small-tests/runtest.sh b/tests/Regression/small-tests/runtest.sh index b7b1477..6204d75 100755 --- a/tests/Regression/small-tests/runtest.sh +++ b/tests/Regression/small-tests/runtest.sh @@ -211,5 +211,9 @@ rlJournalStart rlPhaseStart FAIL "test 19 missing-rpc-tracepoints" rlRun "stap -L 'kernel.trace(\"rpc*\")'" rlPhaseEnd + + rlPhaseStart WARN "Check for stuff we failed to clean up" + rlRun "pstree -p $$" + rlPhaseEnd rlJournalPrintText rlJournalEnd From 64a97036282244839850ded8c0056d53f9abf921 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Fri, 26 Apr 2024 18:15:05 -0400 Subject: [PATCH 059/101] release 5.1 --- .gitignore | 1 + RHEL-16549.patch | 59 ------------------------------------------------ sources | 2 +- systemtap.spec | 49 +++++++++++----------------------------- 4 files changed, 15 insertions(+), 96 deletions(-) delete mode 100644 RHEL-16549.patch diff --git a/.gitignore b/.gitignore index e64fe0a..0d59b35 100644 --- a/.gitignore +++ b/.gitignore @@ -97,3 +97,4 @@ /systemtap-5.1~pre17060399gb6abf4bd.tar.gz /systemtap-5.1~pre17062114g2604d135.tar.gz /systemtap-5.1~pre17062192g5fd8daba.tar.gz +/systemtap-5.1.tar.gz diff --git a/RHEL-16549.patch b/RHEL-16549.patch deleted file mode 100644 index 4469759..0000000 --- a/RHEL-16549.patch +++ /dev/null @@ -1,59 +0,0 @@ -commit 0fef0bd60ff4b359a32da52262855dfe82fe51ae -gpg: Signature made Tue 14 Nov 2023 03:20:12 PM EST -gpg: using RSA key 4B35DCD2EA45C4E0783135BC8094BE9C9F4696A1 -gpg: Can't check signature: No public key -Author: Yichun Zhang (agentzh) -Date: Fri Nov 10 21:51:56 2023 -0800 - - PR31051: memory and uprobe leaks in early uprobe registraton code when errors happen - -diff --git a/runtime/linux/uprobes-inode.c b/runtime/linux/uprobes-inode.c -index 997f4528d..289cce00b 100644 ---- a/runtime/linux/uprobes-inode.c -+++ b/runtime/linux/uprobes-inode.c -@@ -529,6 +529,16 @@ stapiu_init(struct stapiu_consumer *consumers, size_t nconsumers) - } - - if (unlikely(ret != 0)) { -+ for ( ;; ) { -+ struct stapiu_consumer *c = &consumers[i]; -+ // protect against conceivable stapiu_refresh() at same time -+ mutex_lock(& c->consumer_lock); -+ stapiu_consumer_unreg(c); -+ mutex_unlock(& c->consumer_lock); -+ if (i == 0) -+ break; -+ i--; -+ } - return ret; - } - -@@ -545,7 +555,27 @@ stapiu_init(struct stapiu_consumer *consumers, size_t nconsumers) - break; - } - } -- return ret; -+ -+ if (unlikely(ret != 0)) { -+ int j; -+ for (j = 0; j < nconsumers; ++j) { -+ struct stapiu_consumer *c = &consumers[j]; -+ // protect against conceivable stapiu_refresh() at same time -+ mutex_lock(& c->consumer_lock); -+ stapiu_consumer_unreg(c); -+ mutex_unlock(& c->consumer_lock); -+ } -+ for ( ;; ) { -+ struct stapiu_consumer *c = &consumers[i]; -+ stap_cleanup_task_finder_target(&c->finder); -+ if (i == 0) -+ break; -+ i--; -+ } -+ return ret; -+ } -+ -+ return 0; - } - - diff --git a/sources b/sources index 75bc5a4..b6cca60 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.1~pre17062192g5fd8daba.tar.gz) = 423b09c001a2446d807be9fb8b66226545dddb15e7e57af01780966b17af5e2d8c16f44ce3f77d9a884c4e64a379604f9fb493b2a0f5e6ae50d65de19d9af992 +SHA512 (systemtap-5.1.tar.gz) = da0fe237d2124031a5786d1221dbb420d90da5497376715fd43a7a9f61a354a229c1128e67ce6becbc012aa3796dc5d337149e239e3c1def0651b179e5bf199f diff --git a/systemtap.spec b/systemtap.spec index d22819b..3c192f6 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -92,7 +92,10 @@ \ g stapusr 156\ g stapsys 157\ -g stapdev 158 +g stapdev 158\ +g stapunpriv 159\ +u stapunpriv 159 "systemtap unprivileged user" /var/lib/stapunpriv /sbin/nologin\ +m stapunpriv stapunpriv %define _systemtap_server_preinstall \ # See systemd-sysusers(8) sysusers.d(5)\ @@ -117,7 +120,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.1~pre17062192g5fd8daba +Version: 5.1 Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -153,7 +156,7 @@ Release: 1%{?release_override}%{?dist} Summary: Programmable system-wide instrumentation system License: GPL-2.0-or-later URL: http://sourceware.org/systemtap/ -Source: %{name}-%{version}.tar.gz +Source: ftp://sourceware.org/pub/systemtap/releases/systemtap-%{version}.tar.gz # Build* BuildRequires: make @@ -842,6 +845,9 @@ echo '%_systemtap_runtime_preinstall' | systemd-sysusers --replace=%{_sysusersdi getent group stapusr >/dev/null || groupadd -f -g 156 -r stapusr getent group stapsys >/dev/null || groupadd -f -g 157 -r stapsys getent group stapdev >/dev/null || groupadd -f -g 158 -r stapdev +getent passwd stapunpriv >/dev/null || \ + useradd -c "Systemtap Unprivileged User" -u 159 -g stapunpriv -d %{_localstatedir}/lib/stapunpriv -r -s /sbin/nologin stapunpriv 2>/dev/null || \ + useradd -c "Systemtap Unprivileged User" -g stapunpriv -d %{_localstatedir}/lib/stapunpriv -r -s /sbin/nologin stapunpriv %endif exit 0 @@ -1304,44 +1310,15 @@ exit 0 # PRERELEASE %changelog -* Thu Jan 25 2024 Frank Ch. Eigler - 5.1-17062192g5fd8daba -- Automated weekly rawhide release -- Applied spec changes from upstream git - -* Thu Jan 25 2024 Frank Ch. Eigler - 5.1-17062114g2604d135 -- Automated weekly rawhide release -- Applied spec changes from upstream git - -* Tue Jan 23 2024 Frank Ch. Eigler - 5.1-17060399gb6abf4bd -- Automated weekly rawhide release -- Applied spec changes from upstream git - -* Mon Jan 22 2024 Frank Ch. Eigler - 5.1-17059382g67086c54 -- Automated weekly rawhide release -- Applied spec changes from upstream git - -* Thu Jan 18 2024 Frank Ch. Eigler - 5.1-17056139g6c0b92b3 -- Automated weekly rawhide release -- Applied spec changes from upstream git - -* Thu Jan 18 2024 Frank Ch. Eigler - 5.1-17056120g2ccc0c4c -- Automated weekly rawhide release -- Applied spec changes from upstream git - -* Thu Jan 18 2024 Jonathan Wakely - 5.0-4 -- Rebuilt for Boost 1.83 - -* Tue Nov 14 2023 Frank Ch. Eigler - 5.0-3 -- RHEL-16549 - -* Mon Nov 06 2023 Frank Ch. Eigler - 5.0-2 -- License header tweak +* Fri Apr 26 2024 Frank Ch. Eigler - 5.1-1 +- Upstream release, see wiki page below for detailed notes. + https://sourceware.org/systemtap/wiki/SystemTapReleases * Sat Nov 04 2023 Frank Ch. Eigler - 5.0-1 - Upstream release, see wiki page below for detailed notes. https://sourceware.org/systemtap/wiki/SystemTapReleases - migrated to SPDX license - + * Fri Apr 28 2023 Frank Ch. Eigler - 4.9-1 - Upstream release, see wiki page below for detailed notes. https://sourceware.org/systemtap/wiki/SystemTapReleases From 95a46ceb445de76f64555d4aeb82c7dd5f3072b4 Mon Sep 17 00:00:00 2001 From: Python Maint Date: Sat, 8 Jun 2024 22:34:35 +0200 Subject: [PATCH 060/101] Rebuilt for Python 3.13 --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index 3c192f6..28ca462 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -121,7 +121,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE Version: 5.1 -Release: 1%{?release_override}%{?dist} +Release: 2%{?release_override}%{?dist} # for version, see also configure.ac @@ -1310,6 +1310,9 @@ exit 0 # PRERELEASE %changelog +* Sat Jun 08 2024 Python Maint - 5.1-2 +- Rebuilt for Python 3.13 + * Fri Apr 26 2024 Frank Ch. Eigler - 5.1-1 - Upstream release, see wiki page below for detailed notes. https://sourceware.org/systemtap/wiki/SystemTapReleases From 4ae3ff215248db994254024e29127802941c7768 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Thu, 13 Jun 2024 12:15:54 +0200 Subject: [PATCH 061/101] CI Tests: Do not rely on python-unversioned-command.rpm --- tests/Regression/python-probing/main.fmf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/Regression/python-probing/main.fmf b/tests/Regression/python-probing/main.fmf index de28f68..c4afdea 100644 --- a/tests/Regression/python-probing/main.fmf +++ b/tests/Regression/python-probing/main.fmf @@ -18,7 +18,7 @@ recommend: - yum-utils adjust: - environment: - PYTHON: python + PYTHON: python3 when: distro is defined and distro == rhel-9 because: "Test with python (i.e. python3) on rhel-9" - enabled: false From 73bce465bd07266e956cffc552ccb9a9308a14d4 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Mon, 17 Jun 2024 18:42:00 +0200 Subject: [PATCH 062/101] CI Tests: Suppress selected rhel10/ppc64le error::dwarf problems --- .../semantic-errors-bz953776/runtest.sh | 20 ++++++++++----- tests/Regression/small-tests/runtest.sh | 25 +++++++++++-------- .../runtest.sh | 5 +++- 3 files changed, 33 insertions(+), 17 deletions(-) diff --git a/tests/Regression/semantic-errors-bz953776/runtest.sh b/tests/Regression/semantic-errors-bz953776/runtest.sh index f88d195..7ea0f29 100755 --- a/tests/Regression/semantic-errors-bz953776/runtest.sh +++ b/tests/Regression/semantic-errors-bz953776/runtest.sh @@ -107,9 +107,13 @@ EOF export p - rlPhaseStart FAIL 'case-1' - rlRun "stap $p -v -e 'probe syscall.close { println(fd); exit(); }'" - rlPhaseEnd + ( + # Work around rhel10 ppc64le specific error::dwarf + test $_rhelmajor -eq 10 && arch | fgrep ppc64le && exit + rlPhaseStart FAIL 'case-1' + rlRun "stap $p -v -e 'probe syscall.close { println(fd); exit(); }'" + rlPhaseEnd + ) # After fixing bz1657681, this constraint can be removed if [[ $(rpm --eval %rhel) -le 7 ]]; then @@ -130,9 +134,13 @@ EOF rlPhaseEnd ) - rlPhaseStart FAIL 'case-4' - rlRun "stap $p -v -e 'probe syscall.open, syscall.openat { if (\"open\" == execname()) println(argstr); exit() }'" - rlPhaseEnd + ( + # Work around rhel10 ppc64le specific error::dwarf + test $_rhelmajor -eq 10 && arch | fgrep ppc64le && exit + rlPhaseStart FAIL 'case-4' + rlRun "stap $p -v -e 'probe syscall.open, syscall.openat { if (\"open\" == execname()) println(argstr); exit() }'" + rlPhaseEnd + ) rlPhaseStart FAIL 'case-5' rlRun "stap $p -ve 'probe syscall.sigaltstack { println(name); exit() }' -c './sigaltstack || true'" diff --git a/tests/Regression/small-tests/runtest.sh b/tests/Regression/small-tests/runtest.sh index 6204d75..31be18b 100755 --- a/tests/Regression/small-tests/runtest.sh +++ b/tests/Regression/small-tests/runtest.sh @@ -31,6 +31,7 @@ PACKAGE="systemtap" +_rhelmajor=$(rpm --eval '%{rhel}') _arch=$(arch) function perf_probe_failed () @@ -82,17 +83,21 @@ rlJournalStart rlPhaseEnd # bz1153673 --------------------------------------------------- - rlPhaseStart FAIL "test 3 bz1153673" - _tested=0 - for _pkg in $( rpm -qa | grep systemtap-testsuite ); do - for _tc in $( rpm -ql $_pkg | grep 'alias_suffixes.stp$' ); do - stap -p4 $_tc && p="" || p="-P" - rlRun "stap $p -p4 $_tc" - _tested=1 + ( + # Work around rhel10 ppc64le specific error::dwarf + test $_rhelmajor -eq 10 && arch | fgrep ppc64le && exit + rlPhaseStart FAIL "test 3 bz1153673" + _tested=0 + for _pkg in $( rpm -qa | grep systemtap-testsuite ); do + for _tc in $( rpm -ql $_pkg | grep 'alias_suffixes.stp$' ); do + stap -p4 $_tc && p="" || p="-P" + rlRun "stap $p -p4 $_tc" + _tested=1 + done done - done - [[ $_tested -eq 0 ]] && rlFail "Not tested" - rlPhaseEnd + [[ $_tested -eq 0 ]] && rlFail "Not tested" + rlPhaseEnd + ) # bz1160837 --------------------------------------------------- ( diff --git a/tests/Regression/syscall-get-arguments-returning-wrong-value/runtest.sh b/tests/Regression/syscall-get-arguments-returning-wrong-value/runtest.sh index 2143280..3c81142 100755 --- a/tests/Regression/syscall-get-arguments-returning-wrong-value/runtest.sh +++ b/tests/Regression/syscall-get-arguments-returning-wrong-value/runtest.sh @@ -29,6 +29,7 @@ # Include Beaker environment . /usr/share/beakerlib/beakerlib.sh || exit 1 +_rhelmajor="0$(rpm --eval '%{rhel}')" ASMLINKAGE=''; uname -m | grep -E 'i[36]86' && \ @@ -66,8 +67,10 @@ function perf_probe_failed () rlJournalStart rlPhaseStartTest ( + # Work around rhel10 ppc64le specific error::dwarf + test $_rhelmajor -eq 10 && arch | fgrep ppc64le && exit perf_probe_failed "sys_open" && exit - stap -p4 $SCRIPT >&/dev/null && p="" || p='-P' + stap -p4 $SCRIPT >&/dev/null && p="" || p='-P' rlRun "stap $p -v $SCRIPT -c 'cat /dev/null'" ) rm $SCRIPT From dd61c2d29235e9313bec371db3983b8436d23f05 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Wed, 19 Jun 2024 10:47:10 +0200 Subject: [PATCH 063/101] CI Tests: Port backtrace test for kernel-6.10 Modern kernel-6.10 doesn't have function kmem_cache_alloc(), but we can test with another one, such as schedule(). --- .../RHEL7-5-backtraces-no-longer-work-with-systemtap/runtest.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/runtest.sh b/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/runtest.sh index a4b1a26..94cf2cc 100755 --- a/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/runtest.sh +++ b/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/runtest.sh @@ -36,7 +36,7 @@ rlJournalStart rlLogWarning "Test not relevant" else TEMPFILE=$(mktemp) - rlRun "stap --all-modules -vwe 'probe kernel.function(\"kmem_cache_alloc\") { print_backtrace(); exit() }' >& $TEMPFILE" + rlRun "stap --all-modules -vwe 'probe kernel.function(\"kmem_cache_alloc\")?, kernel.function(\"schedule\") { print_backtrace(); exit() }' >& $TEMPFILE" # since it's hard to find some reasonable pattern to grep for across arches in the backrtrace # we'll simply count the lines. We'll want at least 9 lines of output (6 as the results of -v, # and another at least three coming from the backtrace itself. From 897096ec80c69eb85468d52cf98eecfc66ca684d Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Thu, 20 Jun 2024 14:20:53 +0200 Subject: [PATCH 064/101] CI Tests: second-command-not-captured: raise STP_OVERLOAD_THRESHOLD for ppc64le In tests/Regression/second-command-not-captured raise the STP_OVERLOAD_THRESHOLD. In practice the original treshold 500000000LL was hit here and there, causing intermittent testcase failures. This was reproducible manually in cca 50% of tests. --- tests/Regression/second-command-not-captured/runtest.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tests/Regression/second-command-not-captured/runtest.sh b/tests/Regression/second-command-not-captured/runtest.sh index 3912665..6be076b 100755 --- a/tests/Regression/second-command-not-captured/runtest.sh +++ b/tests/Regression/second-command-not-captured/runtest.sh @@ -30,6 +30,9 @@ PACKAGE="systemtap" +STP_OVERLOAD_THRESHOLD='' +arch | grep -F ppc64le && STP_OVERLOAD_THRESHOLD='-DSTP_OVERLOAD_THRESHOLD=1000000000LL' + rlJournalStart rlPhaseStart "WARN" "Attempt to hack around possible ruby tapset problem" rlRun "rpm -q ruby-libs" @@ -46,7 +49,7 @@ rlJournalStart rlPhaseStartTest rlLog "`which stap`" rlLog "`stap -V`" - rlRun "stap -v ./ruby-exercise.stp -c ./test.sh -o stap.log" + rlRun "stap $STP_OVERLOAD_THRESHOLD -v ./ruby-exercise.stp -c ./test.sh -o stap.log" rlRun "grep 'Array::push' stap.log" || rlFileSubmit "stap.log" rlPhaseEnd From 36b1f19663312fd8f5cd7a2c5941d46736021b10 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Thu, 20 Jun 2024 14:36:31 +0200 Subject: [PATCH 065/101] CI tests: Regression/small-tests: extend test time --- tests/Regression/small-tests/main.fmf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/Regression/small-tests/main.fmf b/tests/Regression/small-tests/main.fmf index ff53860..43e6b7d 100644 --- a/tests/Regression/small-tests/main.fmf +++ b/tests/Regression/small-tests/main.fmf @@ -10,7 +10,7 @@ recommend: - systemtap-testsuite - perf - psmisc -duration: 100m +duration: 300m extra-summary: /tools/systemtap/Regression/small-tests extra-task: /tools/systemtap/Regression/small-tests tag: fedora From 956a4db3d952bbea12afecf730a6bf5a0ff01473 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Fri, 28 Jun 2024 13:02:36 +0200 Subject: [PATCH 066/101] CI Tests: ftrace-logging-tapset test: adjust expected output --- .../ftrace-logging-tapset-not-working-as-expected-in/runtest.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/runtest.sh b/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/runtest.sh index 4360d83..dc4c2a2 100755 --- a/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/runtest.sh +++ b/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/runtest.sh @@ -35,7 +35,7 @@ LOG2=$(mktemp) rlJournalStart rlPhaseStartTest - rlRun "mount | grep -F -i 'debugfs on'" + rlRun "mount | grep -F -i -e 'debugfs on' -e 'on /sys/kernel/debug type debugfs'" rlRun "cat /sys/kernel/debug/tracing/tracing_on | grep '^1$'" rlRun "journalctl > $LOG1" rlRun "stap -g -k -v hellotrace.stp" From f95124e787080ab398424dbe3de10db507d2b408 Mon Sep 17 00:00:00 2001 From: William Cohen Date: Wed, 10 Jul 2024 10:10:10 -0400 Subject: [PATCH 067/101] Automated weekly systemtap rawhide release: 5.1~pre17206206ge48abca5 --- .gitignore | 1 + sources | 2 +- systemtap.spec | 15 ++++++++------- 3 files changed, 10 insertions(+), 8 deletions(-) diff --git a/.gitignore b/.gitignore index 0d59b35..33eb01d 100644 --- a/.gitignore +++ b/.gitignore @@ -98,3 +98,4 @@ /systemtap-5.1~pre17062114g2604d135.tar.gz /systemtap-5.1~pre17062192g5fd8daba.tar.gz /systemtap-5.1.tar.gz +/systemtap-5.1~pre17206206ge48abca5.tar.gz diff --git a/sources b/sources index b6cca60..5291842 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.1.tar.gz) = da0fe237d2124031a5786d1221dbb420d90da5497376715fd43a7a9f61a354a229c1128e67ce6becbc012aa3796dc5d337149e239e3c1def0651b179e5bf199f +SHA512 (systemtap-5.1~pre17206206ge48abca5.tar.gz) = f1a3f53630bf01ffd59903ca82c66c7f2dff00c4737072337b20895448a4c277f8cf0696270d320fd54e73830de691d83d2d2ed824cd06cc0969f96ab81a9aa3 diff --git a/systemtap.spec b/systemtap.spec index 28ca462..80c787c 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -120,8 +120,8 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.1 -Release: 2%{?release_override}%{?dist} +Version: 5.1~pre17206206ge48abca5 +Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -156,7 +156,7 @@ Release: 2%{?release_override}%{?dist} Summary: Programmable system-wide instrumentation system License: GPL-2.0-or-later URL: http://sourceware.org/systemtap/ -Source: ftp://sourceware.org/pub/systemtap/releases/systemtap-%{version}.tar.gz +Source: %{name}-%{version}.tar.gz # Build* BuildRequires: make @@ -399,7 +399,7 @@ with the optional dtrace-compatibility preprocessor to process related %package testsuite Summary: Instrumentation System Testsuite -License: GPL-2.0-or-later AND GPL AND GPL-2.0-only AND GPL-3.0-or-later AND MIT +License: GPL-2.0-or-later AND GPL-2.0-only AND GPL-3.0-or-later AND MIT URL: http://sourceware.org/systemtap/ Requires: systemtap = %{version}-%{release} Requires: systemtap-sdt-devel = %{version}-%{release} @@ -727,9 +727,6 @@ find testsuite -type f -name '.gitignore' -print0 | xargs -0 rm -f # permissions back to 04110 in the %files section below. chmod 755 $RPM_BUILD_ROOT%{_bindir}/staprun -#install the useful stap-prep script -install -c -m 755 stap-prep $RPM_BUILD_ROOT%{_bindir}/stap-prep - # Copy over the testsuite cp -rp testsuite $RPM_BUILD_ROOT%{_datadir}/systemtap @@ -1310,6 +1307,10 @@ exit 0 # PRERELEASE %changelog +* Wed Jul 10 2024 William Cohen - 5.1-17206206ge48abca5 +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Sat Jun 08 2024 Python Maint - 5.1-2 - Rebuilt for Python 3.13 From 8c07a00957bc57e2cb33eea925ae2aacc42dd3a4 Mon Sep 17 00:00:00 2001 From: William Cohen Date: Wed, 10 Jul 2024 14:19:34 -0400 Subject: [PATCH 068/101] Automated weekly systemtap rawhide release: 5.2~pre17206355g1a07290a --- .gitignore | 1 + sources | 2 +- systemtap.spec | 6 +++++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 33eb01d..85b65e9 100644 --- a/.gitignore +++ b/.gitignore @@ -99,3 +99,4 @@ /systemtap-5.1~pre17062192g5fd8daba.tar.gz /systemtap-5.1.tar.gz /systemtap-5.1~pre17206206ge48abca5.tar.gz +/systemtap-5.2~pre17206355g1a07290a.tar.gz diff --git a/sources b/sources index 5291842..d638a67 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.1~pre17206206ge48abca5.tar.gz) = f1a3f53630bf01ffd59903ca82c66c7f2dff00c4737072337b20895448a4c277f8cf0696270d320fd54e73830de691d83d2d2ed824cd06cc0969f96ab81a9aa3 +SHA512 (systemtap-5.2~pre17206355g1a07290a.tar.gz) = 8b3083fd181dfc9d8d4e1cae2407865169ed171c5c4e3c70debb3b325639897bd3d06b1288e236d5cb28bfaf3e440383eee008b883cc8a658af7a9d2993f592c diff --git a/systemtap.spec b/systemtap.spec index 80c787c..8fdfba8 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -120,7 +120,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.1~pre17206206ge48abca5 +Version: 5.2~pre17206355g1a07290a Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -1307,6 +1307,10 @@ exit 0 # PRERELEASE %changelog +* Wed Jul 10 2024 William Cohen - 5.2-17206355g1a07290a +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Wed Jul 10 2024 William Cohen - 5.1-17206206ge48abca5 - Automated weekly rawhide release - Applied spec changes from upstream git From 93948388bc54cd7a4efb1806d9787291d26b33d6 Mon Sep 17 00:00:00 2001 From: Lumir Balhar Date: Tue, 9 Jul 2024 14:17:02 +0200 Subject: [PATCH 069/101] New sdt-dtrace subpackage for dtrace tool (rhbz#2296275) This is phase one of the approved self-contained change: https://fedoraproject.org/wiki/Changes/Separate_dtrace_package Phase two will be to switch all packages that need the dtrace tool to the new systemtap-sdt-drace and then we can remove the requirement from systemtap-sdt-devel package. --- systemtap.spec | 38 +++++++++++++++++++++++++++++--------- 1 file changed, 29 insertions(+), 9 deletions(-) diff --git a/systemtap.spec b/systemtap.spec index 8fdfba8..fee72ff 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -121,7 +121,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE Version: 5.2~pre17206355g1a07290a -Release: 1%{?release_override}%{?dist} +Release: 2%{?release_override}%{?dist} # for version, see also configure.ac @@ -133,7 +133,8 @@ Release: 1%{?release_override}%{?dist} # systemtap-runtime /usr/bin/staprun, /usr/bin/stapsh, /usr/bin/stapdyn # systemtap-client /usr/bin/stap, samples, docs, tapset(bonus), req:-runtime # systemtap-initscript /etc/init.d/systemtap, dracut module, req:systemtap -# systemtap-sdt-devel /usr/include/sys/sdt.h /usr/bin/dtrace +# systemtap-sdt-devel /usr/include/sys/sdt.h +# systemtap-sdt-dtrace /usr/bin/dtrace # systemtap-testsuite /usr/share/systemtap/testsuite*, req:systemtap, req:sdt-devel # systemtap-runtime-java libHelperSDT.so, HelperSDT.jar, stapbm, req:-runtime # systemtap-runtime-virthost /usr/bin/stapvirt, req:libvirt req:libxml2 @@ -375,9 +376,21 @@ boot-time probing if supported. %package sdt-devel -Summary: Static probe support tools +Summary: Static probe support header files License: GPL-2.0-or-later AND CC0-1.0 URL: http://sourceware.org/systemtap/ +Requires: systemtap-sdt-dtrace = %{version}-%{release} + +%description sdt-devel +This package includes the header file used for static +instrumentation compiled into userspace programs. + + +%package sdt-dtrace +Summary: Static probe support dtrace tool +License: GPL-2.0-or-later AND CC0-1.0 +URL: http://sourceware.org/systemtap/ +Provides: dtrace = %{version}-%{release} %if %{with_pyparsing} %if %{with_python3} Requires: python3-pyparsing @@ -390,11 +403,9 @@ Requires: python2-pyparsing %endif %endif -%description sdt-devel -This package includes the header file used for static -instrumentation compiled into userspace programs and libraries, along -with the optional dtrace-compatibility preprocessor to process related -.d files into tracing-macro-laden .h headers. +%description sdt-dtrace +This package includes the dtrace-compatibility preprocessor +to process related .d files into tracing-macro-laden .h headers. %package testsuite @@ -1225,7 +1236,6 @@ exit 0 %files sdt-devel -%{_bindir}/dtrace %{_includedir}/sys/sdt.h %{_includedir}/sys/sdt-config.h %{_mandir}/man1/dtrace.1* @@ -1235,6 +1245,12 @@ exit 0 %license COPYING +%files sdt-dtrace +%{_bindir}/dtrace +%doc README AUTHORS NEWS +%license COPYING + + %files testsuite %dir %{_datadir}/systemtap %{_datadir}/systemtap/testsuite @@ -1307,6 +1323,10 @@ exit 0 # PRERELEASE %changelog +* Wed Jul 17 2024 Lumír Balhar - 5.2~pre17206355g1a07290a-2 +- New sdt-dtrace subpackage for dtrace tool (rhbz#2296275) + https://fedoraproject.org/wiki/Changes/Separate_dtrace_package + * Wed Jul 10 2024 William Cohen - 5.2-17206355g1a07290a - Automated weekly rawhide release - Applied spec changes from upstream git From eedaf37e14640b0be71c88fefd6fed75b86752ff Mon Sep 17 00:00:00 2001 From: William Cohen Date: Wed, 31 Jul 2024 09:27:17 -0400 Subject: [PATCH 070/101] Automated weekly systemtap rawhide release: 5.2~pre17224323g98d1ea34 --- .gitignore | 1 + sources | 2 +- systemtap.spec | 19 ++++++------------- 3 files changed, 8 insertions(+), 14 deletions(-) diff --git a/.gitignore b/.gitignore index 85b65e9..eab5424 100644 --- a/.gitignore +++ b/.gitignore @@ -100,3 +100,4 @@ /systemtap-5.1.tar.gz /systemtap-5.1~pre17206206ge48abca5.tar.gz /systemtap-5.2~pre17206355g1a07290a.tar.gz +/systemtap-5.2~pre17224323g98d1ea34.tar.gz diff --git a/sources b/sources index d638a67..a2109b7 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.2~pre17206355g1a07290a.tar.gz) = 8b3083fd181dfc9d8d4e1cae2407865169ed171c5c4e3c70debb3b325639897bd3d06b1288e236d5cb28bfaf3e440383eee008b883cc8a658af7a9d2993f592c +SHA512 (systemtap-5.2~pre17224323g98d1ea34.tar.gz) = e8b1b11daf966e753fddb3f330a330061726b9fc0222b45f403ee33eab6fe48670fd4378de2756375a43ee2e3fbbe4541731d0fb3d4a744a2d07553ccc03fe3b diff --git a/systemtap.spec b/systemtap.spec index fee72ff..7f988d7 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -120,8 +120,8 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.2~pre17206355g1a07290a -Release: 2%{?release_override}%{?dist} +Version: 5.2~pre17224323g98d1ea34 +Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -1323,21 +1323,14 @@ exit 0 # PRERELEASE %changelog +* Wed Jul 31 2024 William Cohen - 5.2-17224323g98d1ea34 +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Wed Jul 17 2024 Lumír Balhar - 5.2~pre17206355g1a07290a-2 - New sdt-dtrace subpackage for dtrace tool (rhbz#2296275) https://fedoraproject.org/wiki/Changes/Separate_dtrace_package -* Wed Jul 10 2024 William Cohen - 5.2-17206355g1a07290a -- Automated weekly rawhide release -- Applied spec changes from upstream git - -* Wed Jul 10 2024 William Cohen - 5.1-17206206ge48abca5 -- Automated weekly rawhide release -- Applied spec changes from upstream git - -* Sat Jun 08 2024 Python Maint - 5.1-2 -- Rebuilt for Python 3.13 - * Fri Apr 26 2024 Frank Ch. Eigler - 5.1-1 - Upstream release, see wiki page below for detailed notes. https://sourceware.org/systemtap/wiki/SystemTapReleases From d0c648ee8c80ba1051cc349ad06d0c85c9530d04 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Fri, 9 Aug 2024 13:30:01 +0200 Subject: [PATCH 071/101] CI Tests: Mark Sanity/quick-smoke-test as 'tier 1' --- tests/Sanity/quick-smoke-test/main.fmf | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/Sanity/quick-smoke-test/main.fmf b/tests/Sanity/quick-smoke-test/main.fmf index 14f00ce..f40c03b 100644 --- a/tests/Sanity/quick-smoke-test/main.fmf +++ b/tests/Sanity/quick-smoke-test/main.fmf @@ -14,3 +14,4 @@ duration: 1h extra-summary: /tools/systemtap/Sanity/quick-smoke-test extra-task: /tools/systemtap/Sanity/quick-smoke-test tag: fedora +tier: 1 From 20b4dc7947b0a1197c48b0b26821ae698ba1902d Mon Sep 17 00:00:00 2001 From: Lumir Balhar Date: Thu, 8 Aug 2024 13:31:35 +0200 Subject: [PATCH 072/101] Final split of sdt-dtrace and sdt-devel (rhbz#2296275) https://fedoraproject.org/wiki/Changes/Separate_dtrace_package --- systemtap.spec | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/systemtap.spec b/systemtap.spec index 7f988d7..89a474c 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -121,7 +121,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE Version: 5.2~pre17224323g98d1ea34 -Release: 1%{?release_override}%{?dist} +Release: 2%{?release_override}%{?dist} # for version, see also configure.ac @@ -379,7 +379,6 @@ boot-time probing if supported. Summary: Static probe support header files License: GPL-2.0-or-later AND CC0-1.0 URL: http://sourceware.org/systemtap/ -Requires: systemtap-sdt-dtrace = %{version}-%{release} %description sdt-devel This package includes the header file used for static @@ -1323,6 +1322,10 @@ exit 0 # PRERELEASE %changelog +* Thu Aug 08 2024 Lumír Balhar - 5.2-17224323g98d1ea34-2 +- Final split of sdt-dtrace and sdt-devel (rhbz#2296275) + https://fedoraproject.org/wiki/Changes/Separate_dtrace_package + * Wed Jul 31 2024 William Cohen - 5.2-17224323g98d1ea34 - Automated weekly rawhide release - Applied spec changes from upstream git From 91da2bdd2e3d57f14750f0008013cc847bb0a68d Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Fri, 16 Aug 2024 17:20:03 +0200 Subject: [PATCH 073/101] CI Tests: Regression/small-tests: provide TESTS var to specify tests to run --- tests/Regression/small-tests/runtest.sh | 344 +++++++++++++++--------- 1 file changed, 215 insertions(+), 129 deletions(-) diff --git a/tests/Regression/small-tests/runtest.sh b/tests/Regression/small-tests/runtest.sh index 31be18b..60b7658 100755 --- a/tests/Regression/small-tests/runtest.sh +++ b/tests/Regression/small-tests/runtest.sh @@ -26,24 +26,61 @@ # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ # Include Beaker environment +# shellcheck disable=SC1091 . /usr/share/beakerlib/beakerlib.sh || exit 1 . /etc/os-release ||: -PACKAGE="systemtap" - _rhelmajor=$(rpm --eval '%{rhel}') _arch=$(arch) +# Specify which tests to run e.g. "1,3,5-6,8-11" or "ALL" +TESTS="${TESTS:-ALL}" +TESTS="${TESTS//,/\ }" + +function run_test () +{ + [ "$TESTS" == "ALL" ] && return 0 + digits=4 + test_no=$(printf "%0${digits}g\n" "$1") + + for spec in $TESTS; do + case $spec in + [0-9]*-[0-9]*) + n1=$(echo "$spec" | awk -F- '{print $1}') + n2=$(echo "$spec" | awk -F- '{print $2}') + for id in $(seq -f "%0${digits}g" "$n1" "$n2"); do + if [ "$test_no" == "$id" ]; then + return 0 + fi + done + ;; + [0-9]*) + id=$(printf "%0${digits}g\n" "$spec") + if [ "$test_no" == "$id" ]; then + return 0 + fi + ;; + *) + echo "ERROR: TESTS=\"$TESTS\". That is not parseable." + return 1 + esac + done + return 1 +} + + function perf_probe_failed () { probe=$1 - perf probe -d $probe ||: - perf probe --add $probe + perf probe -d "$probe" ||: + perf probe --add "$probe" retval=$? - test $retval -eq 0 && \ - rlLogInfo "Running perf probe --add $probe PASSED" || \ + if test $retval -eq 0; then + rlLogInfo "Running perf probe --add $probe PASSED" + else rlLogInfo "Running perf probe --add $probe FAILED" - perf probe -d $probe ||: + fi + perf probe -d "$probe" ||: if test $retval -eq 0; then return 1 else @@ -55,7 +92,7 @@ function perf_found_none_of () { ret=0 for f in "$@"; do - perf_probe_failed $f || ret=1 + perf_probe_failed "$f" || ret=1 done return $ret } @@ -68,154 +105,203 @@ rlJournalStart rlRun "perf --version" rlLogInfo "DEBUGINFOD_URLS=$DEBUGINFOD_URLS" rlLogInfo "DEBUGINFOD_TIMEOUT=$DEBUGINFOD_TIMEOUT" + rlLogInfo "TESTS=$TESTS" rlPhaseEnd # bz1162939 --------------------------------------------------- ( + run_test 1 || exit perf_probe_failed "vfs_read" && exit rlPhaseStart FAIL "test 1 bz1162939" rlRun "stap -e 'probe vfs.read{println(\"hit\"); exit()}' -c 'head -1 /etc/hosts' | grep -F hit" rlPhaseEnd ) - # bz1119335 --------------------------------------------------- - rlPhaseStart FAIL "test 2 bz1119335" - rlRun "man 8 staprun | grep 'STAP_FIPS_OVERRIDE'" - rlPhaseEnd - # bz1153673 --------------------------------------------------- - ( - # Work around rhel10 ppc64le specific error::dwarf - test $_rhelmajor -eq 10 && arch | fgrep ppc64le && exit - rlPhaseStart FAIL "test 3 bz1153673" - _tested=0 - for _pkg in $( rpm -qa | grep systemtap-testsuite ); do - for _tc in $( rpm -ql $_pkg | grep 'alias_suffixes.stp$' ); do - stap -p4 $_tc && p="" || p="-P" - rlRun "stap $p -p4 $_tc" - _tested=1 - done - done - [[ $_tested -eq 0 ]] && rlFail "Not tested" - rlPhaseEnd - ) + # bz1119335 --------------------------------------------------- + ( + run_test 2 || exit + rlPhaseStart FAIL "test 2 bz1119335" + rlRun "man 8 staprun | grep 'STAP_FIPS_OVERRIDE'" + rlPhaseEnd + ) - # bz1160837 --------------------------------------------------- - ( - perf_probe_failed "sd_init_command" && exit - rlPhaseStart FAIL "test 4 bz1160837" - _tested=0 - _prologue_search='' - for _pkg in $( rpm -qa | grep systemtap-testsuite ); do - for _tc in $( rpm -ql $_pkg | grep 'iostat-scsi.stp$' ); do - test $_arch = ppc64le && _prologue_search='-P' - rlRun "stap -g $_prologue_search $_tc 1 -c 'sleep 1'" - _tested=1 - done - done - [[ $_tested -eq 0 ]] && rlFail "Not tested" - rlPhaseEnd - ) + # bz1153673 --------------------------------------------------- + ( + run_test 3 || exit + # Work around rhel10 ppc64le specific error::dwarf + test "$_rhelmajor" -eq 10 && arch | grep -F ppc64le && exit + rlPhaseStart FAIL "test 3 bz1153673" + _tested=0 + for _pkg in $( rpm -qa | grep systemtap-testsuite ); do + for _tc in $( rpm -ql "$_pkg" | grep 'alias_suffixes.stp$' ); do + stap -p4 "$_tc" && p="" || p="-P" + rlRun "stap $p -p4 $_tc" + _tested=1 + done + done + [[ $_tested -eq 0 ]] && rlFail "Not tested" + rlPhaseEnd + ) - # bz1203808 --------------------------------------------------- - rlPhaseStart FAIL "test 5 bz1203808" - _tested=0 - for _pkg in $( rpm -qa | grep systemtap-testsuite ); do - for _tc in $( rpm -ql $_pkg | grep 'vfs-all-probes.stp$' ); do - stap -wp4 $_tc && p="" || p="-P" - rlRun "stap $p -w -p4 $_tc" - _tested=1 - done - done - [[ $_tested -eq 0 ]] && rlFail "Not tested" - rlPhaseEnd + # bz1160837 --------------------------------------------------- + ( + run_test 4 || exit + perf_probe_failed "sd_init_command" && exit + rlPhaseStart FAIL "test 4 bz1160837" + _tested=0 + _prologue_search='' + for _pkg in $( rpm -qa | grep systemtap-testsuite ); do + for _tc in $( rpm -ql "$_pkg" | grep 'iostat-scsi.stp$' ); do + test "$_arch" = ppc64le && _prologue_search='-P' + rlRun "stap -g $_prologue_search $_tc 1 -c 'sleep 1'" + _tested=1 + done + done + [[ $_tested -eq 0 ]] && rlFail "Not tested" + rlPhaseEnd + ) - # bz1269062 --------------------------------------------------- - rlPhaseStart FAIL "test 6 bz1269062" - rlRun "stap -c sync --suppress-handler-errors -e 'probe ioscheduler.elv_add_request{println(elevator_name) exit()}'" - rlPhaseEnd + # bz1203808 --------------------------------------------------- + ( + run_test 5 || exit + rlPhaseStart FAIL "test 5 bz1203808" + _tested=0 + for _pkg in $( rpm -qa | grep systemtap-testsuite ); do + for _tc in $( rpm -ql "$_pkg" | grep 'vfs-all-probes.stp$' ); do + stap -wp4 "$_tc" && p="" || p="-P" + rlRun "stap $p -w -p4 $_tc" + _tested=1 + done + done + [[ $_tested -eq 0 ]] && rlFail "Not tested" + rlPhaseEnd + ) - # bz528792 --------------------------------------------------- - ( - # Not relevant on rhel-9 because of kernel commit cad6967ac10843a70842cd39c7b53412901dd21f that removes - # _do_fork() and replaces it with new kernel_clone() - perf_found_none_of "_do_fork" "do_fork" "sys_clone" && exit + # bz1269062 --------------------------------------------------- + ( + run_test 6 || exit + rlPhaseStart FAIL "test 6 bz1269062" + rlRun "stap -c sync --suppress-handler-errors -e 'probe ioscheduler.elv_add_request{println(elevator_name) exit()}'" + rlPhaseEnd + ) - rlPhaseStart FAIL "test 7 bz528792" - if test $_arch = ppc64le; then - # https://bugzilla.redhat.com/show_bug.cgi?id=1652740#c4 - We can not reach any function parameters, namely $clone_flags - rlRun "stap -ve 'probe kernel.function(\"_do_fork\")!, kernel.function(\"do_fork\")!, kernel.function(\"sys_clone\") { println(pp()) exit() }' -c \"bash -c 'while sleep 1; do /bin/true; done'\"" - else - rlRun "stap -ve 'probe kernel.function(\"_do_fork\")!, kernel.function(\"do_fork\")!, kernel.function(\"sys_clone\") { printf(\"%x\n\",\$clone_flags) exit() }' -c \"bash -c 'while sleep 1; do /bin/true; done'\"" - fi - rlPhaseEnd - ) + # bz528792 --------------------------------------------------- + ( + run_test 7 || exit + # Not relevant on rhel-9 because of kernel commit cad6967ac10843a70842cd39c7b53412901dd21f that removes + # _do_fork() and replaces it with new kernel_clone() + perf_found_none_of "_do_fork" "do_fork" "sys_clone" && exit - # bz1890702 --------------------------------------------------- - ( - perf_probe_failed "vfs_open" && exit - rlPhaseStart FAIL "test 8 bz1890702" - rlRun "stap -g --suppress-time-limits -e 'probe kernel.function(\"vfs_open\") { printf(\"%s(path: %s)\", ppfunc(), \$path\$) ; exit() }' -c 'cat /etc/hosts'" - rlPhaseEnd - ) + rlPhaseStart FAIL "test 7 bz528792" + if test "$_arch" = ppc64le; then + # https://bugzilla.redhat.com/show_bug.cgi?id=1652740#c4 - We can not reach any function parameters, namely $clone_flags + rlRun "stap -ve 'probe kernel.function(\"_do_fork\")!, kernel.function(\"do_fork\")!, kernel.function(\"sys_clone\") { println(pp()) exit() }' -c \"bash -c 'while sleep 1; do /bin/true; done'\"" + else + rlRun "stap -ve 'probe kernel.function(\"_do_fork\")!, kernel.function(\"do_fork\")!, kernel.function(\"sys_clone\") { printf(\"%x\n\",\$clone_flags) exit() }' -c \"bash -c 'while sleep 1; do /bin/true; done'\"" + fi + rlPhaseEnd + ) - # bz1904216 --------------------------------------------------- - rlPhaseStart FAIL "test 9 bz1904216" - rlRun "stap -p4 -DSTP_NO_OVERLOAD -t -c 'sleep 0.25' -e 'probe kernel.trace(\"bcache:bcache_btree_set_root\") { if (pid() == 0) printf(\"probe hit\n\"); }'" - rlPhaseEnd + # bz1890702 --------------------------------------------------- + ( + run_test 8 || exit + perf_probe_failed "vfs_open" && exit + rlPhaseStart FAIL "test 8 bz1890702" + rlRun "stap -g --suppress-time-limits -e 'probe kernel.function(\"vfs_open\") { printf(\"%s(path: %s)\", ppfunc(), \$path\$) ; exit() }' -c 'cat /etc/hosts'" + rlPhaseEnd + ) - # bz1940804 --------------------------------------------------- - rlPhaseStart FAIL "test 10 bz1940804" - rlRun "stap -e 'probe process(\"/bin/bash\").function(\"main\") {println(pn()) }' -c '/bin/bash --help'" - rlPhaseEnd + # bz1904216 --------------------------------------------------- + ( + run_test 9 || exit + rlPhaseStart FAIL "test 9 bz1904216" + rlRun "stap -p4 -DSTP_NO_OVERLOAD -t -c 'sleep 0.25' -e 'probe kernel.trace(\"bcache:bcache_btree_set_root\") { if (pid() == 0) printf(\"probe hit\n\"); }'" + rlPhaseEnd + ) - # bz1940945 --------------------------------------------------- - rlPhaseStart FAIL "test 11 bz1940945" - rlRun "stap -c sync --suppress-handler-errors -e 'probe ioscheduler.elv_add_request{println(elevator_name) exit()}'" - rlPhaseEnd + # bz1940804 --------------------------------------------------- + ( + run_test 10 || exit + rlPhaseStart FAIL "test 10 bz1940804" + rlRun "stap -e 'probe process(\"/bin/bash\").function(\"main\") {println(pn()) }' -c '/bin/bash --help'" + rlPhaseEnd + ) - # bz1940761 --------------------------------------------------- - rlPhaseStart FAIL "test 12 bz1940761" - rlRun "stap -v /usr/share/systemtap/examples/process/strace.stp -w -c \"echo hello world\"" - rlPhaseEnd + # bz1940945 --------------------------------------------------- + ( + run_test 11 || exit + rlPhaseStart FAIL "test 11 bz1940945" + rlRun "stap -c sync --suppress-handler-errors -e 'probe ioscheduler.elv_add_request{println(elevator_name) exit()}'" + rlPhaseEnd + ) - # broken-tapset-print-ubacktrace ------------------------------ - rlPhaseStart FAIL "test 13 broken-tapset-print-ubacktrace" - rlRun "stap -p4 -e 'probe begin { print_ubacktrace() }'" - rlPhaseEnd + # bz1940761 --------------------------------------------------- + ( + run_test 12 || exit + rlPhaseStart FAIL "test 12 bz1940761" + rlRun "stap -v /usr/share/systemtap/examples/process/strace.stp -w -c \"echo hello world\"" + rlPhaseEnd + ) - # Protected from elision -------------------------------------- - rlPhaseStart FAIL "test 14 protected from elision" - rlRun "stap -v -e 'probe nfs.fop.fsync {} probe begin {print(\"Protected from elision\")}' -c true |\ - grep -F 'Protected from elision'" - rlPhaseEnd + # broken-tapset-print-ubacktrace ------------------------------ + ( + run_test 13 || exit + rlPhaseStart FAIL "test 13 broken-tapset-print-ubacktrace" + rlRun "stap -p4 -e 'probe begin { print_ubacktrace() }'" + rlPhaseEnd + ) - # bz544207 ---------------------------------------------------- - rlPhaseStart FAIL "test 15 bz544207" - extra_opts="" - stap -vp4 -e 'probe nfs.proc.write_setup{ println(how) }' || extra_opts="-P" - rlRun "stap $extra_opts -vp4 -e 'probe nfs.proc.write_setup{ println(how) }'" - rlPhaseEnd + # Protected from elision -------------------------------------- + ( + run_test 14 || exit + rlPhaseStart FAIL "test 14 protected from elision" + rlRun "stap -v -e 'probe nfs.fop.fsync {} probe begin {print(\"Protected from elision\")}' -c true |\ + grep -F 'Protected from elision'" + rlPhaseEnd + ) - # bz544209 ---------------------------------------------------- - rlPhaseStart FAIL "test 16 bz544209" - rlRun "stap -vp2 -e 'probe sunrpc.clnt.create_client.return {}'" - rlPhaseEnd + # bz544207 ---------------------------------------------------- + ( + run_test 15 || exit + rlPhaseStart FAIL "test 15 bz544207" + extra_opts="" + stap -vp4 -e 'probe nfs.proc.write_setup{ println(how) }' || extra_opts="-P" + rlRun "stap $extra_opts -vp4 -e 'probe nfs.proc.write_setup{ println(how) }'" + rlPhaseEnd + ) - # bz592830 ---------------------------------------------------- - rlPhaseStart FAIL "test 17 bz592830" - rlRun "stap -vp2 -e 'probe signal.check_ignored.return {println(1)}'" - rlPhaseEnd + # bz544209 ---------------------------------------------------- + ( + run_test 16 || exit + rlPhaseStart FAIL "test 16 bz544209" + rlRun "stap -vp2 -e 'probe sunrpc.clnt.create_client.return {}'" + rlPhaseEnd + ) - # caller-does-not-work ---------------------------------------- - rlPhaseStart FAIL "test 18 caller-does-not-work" - rlRun "stap -ve 'probe kernel.function(\"vfs_read\") \ - { printf(\"%s\n\", caller()); exit() }' 2>&1 | tee strace.log" - rlPhaseEnd + # bz592830 ---------------------------------------------------- + ( + run_test 17 || exit + rlPhaseStart FAIL "test 17 bz592830" + rlRun "stap -vp2 -e 'probe signal.check_ignored.return {println(1)}'" + rlPhaseEnd + ) - # missing-rpc-tracepoints ------------------------------------- - rlPhaseStart FAIL "test 19 missing-rpc-tracepoints" - rlRun "stap -L 'kernel.trace(\"rpc*\")'" - rlPhaseEnd + # caller-does-not-work ---------------------------------------- + ( + run_test 18 || exit + rlPhaseStart FAIL "test 18 caller-does-not-work" + rlRun "stap -ve 'probe kernel.function(\"vfs_read\") \ + { printf(\"%s\n\", caller()); exit() }' 2>&1 | tee strace.log" + rlPhaseEnd + ) + + # missing-rpc-tracepoints ------------------------------------- + ( + run_test 19 || exit + rlPhaseStart FAIL "test 19 missing-rpc-tracepoints" + rlRun "stap -L 'kernel.trace(\"rpc*\")'" + rlPhaseEnd + ) rlPhaseStart WARN "Check for stuff we failed to clean up" rlRun "pstree -p $$" From 4bf1177f47d8bc3c4049725facffee5c2fcc73ee Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Fri, 16 Aug 2024 18:02:50 +0200 Subject: [PATCH 074/101] CI Tests: Regression/small-tests: run each subtest as a separate testcase --- tests/Regression/small-tests-wrapper-001/main.fmf | 12 ++++++++++++ tests/Regression/small-tests-wrapper-001/runtest.sh | 8 ++++++++ tests/Regression/small-tests-wrapper-002 | 1 + tests/Regression/small-tests-wrapper-003 | 1 + tests/Regression/small-tests-wrapper-004 | 1 + tests/Regression/small-tests-wrapper-005 | 1 + tests/Regression/small-tests-wrapper-006 | 1 + tests/Regression/small-tests-wrapper-007 | 1 + tests/Regression/small-tests-wrapper-008 | 1 + tests/Regression/small-tests-wrapper-009 | 1 + tests/Regression/small-tests-wrapper-010 | 1 + tests/Regression/small-tests-wrapper-011 | 1 + tests/Regression/small-tests-wrapper-012 | 1 + tests/Regression/small-tests-wrapper-013 | 1 + tests/Regression/small-tests-wrapper-014 | 1 + tests/Regression/small-tests-wrapper-015 | 1 + tests/Regression/small-tests-wrapper-016 | 1 + tests/Regression/small-tests-wrapper-017 | 1 + tests/Regression/small-tests-wrapper-018 | 1 + tests/Regression/small-tests-wrapper-019 | 1 + 20 files changed, 38 insertions(+) create mode 100644 tests/Regression/small-tests-wrapper-001/main.fmf create mode 100755 tests/Regression/small-tests-wrapper-001/runtest.sh create mode 120000 tests/Regression/small-tests-wrapper-002 create mode 120000 tests/Regression/small-tests-wrapper-003 create mode 120000 tests/Regression/small-tests-wrapper-004 create mode 120000 tests/Regression/small-tests-wrapper-005 create mode 120000 tests/Regression/small-tests-wrapper-006 create mode 120000 tests/Regression/small-tests-wrapper-007 create mode 120000 tests/Regression/small-tests-wrapper-008 create mode 120000 tests/Regression/small-tests-wrapper-009 create mode 120000 tests/Regression/small-tests-wrapper-010 create mode 120000 tests/Regression/small-tests-wrapper-011 create mode 120000 tests/Regression/small-tests-wrapper-012 create mode 120000 tests/Regression/small-tests-wrapper-013 create mode 120000 tests/Regression/small-tests-wrapper-014 create mode 120000 tests/Regression/small-tests-wrapper-015 create mode 120000 tests/Regression/small-tests-wrapper-016 create mode 120000 tests/Regression/small-tests-wrapper-017 create mode 120000 tests/Regression/small-tests-wrapper-018 create mode 120000 tests/Regression/small-tests-wrapper-019 diff --git a/tests/Regression/small-tests-wrapper-001/main.fmf b/tests/Regression/small-tests-wrapper-001/main.fmf new file mode 100644 index 0000000..5046850 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-001/main.fmf @@ -0,0 +1,12 @@ +summary: Small tests wrapper +component: +- systemtap +test: ./runtest.sh +framework: beakerlib +recommend: +- systemtap +- systemtap-testsuite +- perf +- psmisc +duration: 300m +tag: fedora diff --git a/tests/Regression/small-tests-wrapper-001/runtest.sh b/tests/Regression/small-tests-wrapper-001/runtest.sh new file mode 100755 index 0000000..9f44eef --- /dev/null +++ b/tests/Regression/small-tests-wrapper-001/runtest.sh @@ -0,0 +1,8 @@ +#!/bin/bash + +ID=$(pwd | awk -F- '{print $NF}') + +export TESTS=$(printf "%d" $ID) + +../small-tests/runtest.sh + diff --git a/tests/Regression/small-tests-wrapper-002 b/tests/Regression/small-tests-wrapper-002 new file mode 120000 index 0000000..7d35367 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-002 @@ -0,0 +1 @@ +small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-003 b/tests/Regression/small-tests-wrapper-003 new file mode 120000 index 0000000..7d35367 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-003 @@ -0,0 +1 @@ +small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-004 b/tests/Regression/small-tests-wrapper-004 new file mode 120000 index 0000000..7d35367 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-004 @@ -0,0 +1 @@ +small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-005 b/tests/Regression/small-tests-wrapper-005 new file mode 120000 index 0000000..7d35367 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-005 @@ -0,0 +1 @@ +small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-006 b/tests/Regression/small-tests-wrapper-006 new file mode 120000 index 0000000..7d35367 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-006 @@ -0,0 +1 @@ +small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-007 b/tests/Regression/small-tests-wrapper-007 new file mode 120000 index 0000000..7d35367 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-007 @@ -0,0 +1 @@ +small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-008 b/tests/Regression/small-tests-wrapper-008 new file mode 120000 index 0000000..7d35367 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-008 @@ -0,0 +1 @@ +small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-009 b/tests/Regression/small-tests-wrapper-009 new file mode 120000 index 0000000..7d35367 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-009 @@ -0,0 +1 @@ +small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-010 b/tests/Regression/small-tests-wrapper-010 new file mode 120000 index 0000000..7d35367 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-010 @@ -0,0 +1 @@ +small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-011 b/tests/Regression/small-tests-wrapper-011 new file mode 120000 index 0000000..7d35367 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-011 @@ -0,0 +1 @@ +small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-012 b/tests/Regression/small-tests-wrapper-012 new file mode 120000 index 0000000..7d35367 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-012 @@ -0,0 +1 @@ +small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-013 b/tests/Regression/small-tests-wrapper-013 new file mode 120000 index 0000000..7d35367 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-013 @@ -0,0 +1 @@ +small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-014 b/tests/Regression/small-tests-wrapper-014 new file mode 120000 index 0000000..7d35367 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-014 @@ -0,0 +1 @@ +small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-015 b/tests/Regression/small-tests-wrapper-015 new file mode 120000 index 0000000..7d35367 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-015 @@ -0,0 +1 @@ +small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-016 b/tests/Regression/small-tests-wrapper-016 new file mode 120000 index 0000000..7d35367 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-016 @@ -0,0 +1 @@ +small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-017 b/tests/Regression/small-tests-wrapper-017 new file mode 120000 index 0000000..7d35367 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-017 @@ -0,0 +1 @@ +small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-018 b/tests/Regression/small-tests-wrapper-018 new file mode 120000 index 0000000..7d35367 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-018 @@ -0,0 +1 @@ +small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-019 b/tests/Regression/small-tests-wrapper-019 new file mode 120000 index 0000000..7d35367 --- /dev/null +++ b/tests/Regression/small-tests-wrapper-019 @@ -0,0 +1 @@ +small-tests-wrapper-001 \ No newline at end of file From 6ba46a9a0419cf7d6c31f0fe40eb773fc5374c9f Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Fri, 16 Aug 2024 18:27:34 +0200 Subject: [PATCH 075/101] CI Tests: Regression/stap-ERROR-Build-id-mismatch-with: Skip on rhel9 (known RHEL-50105) --- .../stap-ERROR-Build-id-mismatch-with/runtest.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/tests/Regression/stap-ERROR-Build-id-mismatch-with/runtest.sh b/tests/Regression/stap-ERROR-Build-id-mismatch-with/runtest.sh index f026393..be97cea 100755 --- a/tests/Regression/stap-ERROR-Build-id-mismatch-with/runtest.sh +++ b/tests/Regression/stap-ERROR-Build-id-mismatch-with/runtest.sh @@ -26,14 +26,17 @@ # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ # Include Beaker environment +# shellcheck disable=SC1091 . /usr/share/beakerlib/beakerlib.sh || exit 1 - -PACKAGE="systemtap" +. /etc/os-release || exit 1 rlJournalStart rlPhaseStartTest if arch | grep -q s390x; then rlLogWarning "Test not relevant" + elif test ${VERSION_ID%.*} -eq 9; then + rlLogInfo "Known problem https://issues.redhat.com/browse/RHEL-50105" + rlLogInfo 'Probing module("igb").function("igb_exit_module") crashes the rhel9 kernel' else rlRun "sudo modprobe igb" rlRun "stap -e 'probe module(\"igb\").function(\"igb_*_module\") { printf(\"%s: %s.\n\", ctime(gettimeofday_s()), ppfunc()); }' -c \"bash -c 'sudo rmmod igb; sudo modprobe igb'\"" From e42e009a44114e08976d61b36cd099d4549a2eda Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Mon, 19 Aug 2024 17:50:12 +0200 Subject: [PATCH 076/101] CI Tests: Move systemtap tests to separate git repo * Move systemtap tests to separate tests repo: https://src.fedoraproject.org/tests/systemtap * For automated CI gating purposes use: https://src.fedoraproject.org/tests/systemtap-gating --- plans/ci.fmf | 14 +- tests/Install/upstream-systemtap/main.fmf | 51 --- tests/Install/upstream-systemtap/runtest.sh | 175 ---------- tests/Regression/PR16166/main.fmf | 16 - tests/Regression/PR16166/runtest.sh | 67 ---- tests/Regression/PR16166/towers.c | 155 --------- .../RHEL6Feature-cpp-backtraces/README | 31 -- .../backtrackator.stp | 15 - .../RHEL6Feature-cpp-backtraces/classes.cpp | 43 --- .../RHEL6Feature-cpp-backtraces/classes.hpp | 16 - .../RHEL6Feature-cpp-backtraces/golden.out | 77 ----- .../RHEL6Feature-cpp-backtraces/main.cpp | 10 - .../RHEL6Feature-cpp-backtraces/main.fmf | 14 - .../RHEL6Feature-cpp-backtraces/runtest.sh | 66 ---- .../classes.cpp | 39 --- .../golden.out | 16 - .../RHEL6Feature-cpp-ctors-and-dtors/main.fmf | 14 - .../runtest.sh | 52 --- .../tracker.stp | 23 -- .../RHEL6Feature-cpp-inheritance/classes.cpp | 56 ---- .../RHEL6Feature-cpp-inheritance/main.fmf | 14 - .../RHEL6Feature-cpp-inheritance/runtest.sh | 56 ---- .../RHEL6Feature-cpp-inheritance/tracker.stp | 6 - .../RHEL6Feature-cpp-methods/classes.cpp | 71 ---- .../golden_summary.out | 13 - .../RHEL6Feature-cpp-methods/main.fmf | 14 - .../RHEL6Feature-cpp-methods/runtest.sh | 72 ---- .../RHEL6Feature-cpp-methods/tracker.stp | 162 --------- .../main.fmf | 15 - .../runtest.sh | 49 --- .../bz544960-no-cfa_ops-supplied/README | 63 ---- .../bz544960-no-cfa_ops-supplied/bdflush.stp | 8 - .../bz544960-no-cfa_ops-supplied/main.fmf | 14 - .../readpages.stp | 21 -- .../bz544960-no-cfa_ops-supplied/runtest.sh | 49 --- .../tcp.sendmsg.stp | 7 - .../bz706185-various-build-and-run/main.fmf | 15 - .../bz706185-various-build-and-run/runtest.sh | 87 ----- .../softirq.run | 1 - .../softirq.stp | 3 - .../main.fmf | 16 - .../runtest.sh | 57 ---- .../dotest.sh | 28 -- .../main.fmf | 15 - .../runtest.sh | 52 --- .../hellotrace.stp | 8 - .../main.fmf | 15 - .../runtest.sh | 47 --- tests/Regression/ipv6-tapset-support/main.fmf | 17 - .../ipv6-tapset-support/nfsd.proc.lookup.stp | 12 - .../Regression/ipv6-tapset-support/runtest.sh | 79 ----- .../irq-vector-tracepoints/main.fmf | 16 - .../irq-vector-tracepoints/runtest.sh | 74 ----- tests/Regression/netdev-receive/main.fmf | 15 - tests/Regression/netdev-receive/runtest.sh | 42 --- .../main.fmf | 17 - .../runtest.sh | 55 ---- tests/Regression/python-probing/list.stp | 22 -- tests/Regression/python-probing/main.fmf | 30 -- tests/Regression/python-probing/runtest.sh | 88 ----- tests/Regression/python-probing/test.py | 3 - tests/Regression/python-probing/top.stp | 19 -- .../second-command-not-captured/main.fmf | 17 - .../ruby-exercise.stp | 9 - .../second-command-not-captured/runtest.sh | 57 ---- .../second-command-not-captured/test.sh | 7 - .../main.fmf | 15 - .../nfs.proc.read_setup.stp | 5 - .../runtest.sh | 45 --- .../semantic-errors-bz1062076/main.fmf | 15 - .../semantic-errors-bz1062076/runtest.sh | 41 --- .../semantic-errors-bz1062076/script.stp | 3 - .../semantic-errors-bz953776/main.fmf | 17 - .../semantic-errors-bz953776/runtest.sh | 169 ---------- .../small-tests-wrapper-001/main.fmf | 12 - .../small-tests-wrapper-001/runtest.sh | 8 - tests/Regression/small-tests-wrapper-002 | 1 - tests/Regression/small-tests-wrapper-003 | 1 - tests/Regression/small-tests-wrapper-004 | 1 - tests/Regression/small-tests-wrapper-005 | 1 - tests/Regression/small-tests-wrapper-006 | 1 - tests/Regression/small-tests-wrapper-007 | 1 - tests/Regression/small-tests-wrapper-008 | 1 - tests/Regression/small-tests-wrapper-009 | 1 - tests/Regression/small-tests-wrapper-010 | 1 - tests/Regression/small-tests-wrapper-011 | 1 - tests/Regression/small-tests-wrapper-012 | 1 - tests/Regression/small-tests-wrapper-013 | 1 - tests/Regression/small-tests-wrapper-014 | 1 - tests/Regression/small-tests-wrapper-015 | 1 - tests/Regression/small-tests-wrapper-016 | 1 - tests/Regression/small-tests-wrapper-017 | 1 - tests/Regression/small-tests-wrapper-018 | 1 - tests/Regression/small-tests-wrapper-019 | 1 - tests/Regression/small-tests/main.fmf | 16 - tests/Regression/small-tests/runtest.sh | 310 ------------------ .../main.fmf | 15 - .../runtest.sh | 46 --- .../main.fmf | 15 - .../runtest.sh | 74 ----- .../Regression/suspicious-RCU-usage/main.fmf | 15 - .../suspicious-RCU-usage/runtest.sh | 49 --- .../main.fmf | 16 - .../runtest.sh | 79 ----- .../main.fmf | 15 - .../reproducer.stp | 10 - .../runtest.sh | 46 --- .../trigger.sh | 7 - .../main.fmf | 15 - .../reproducer.stp | 6 - .../reproducer2.stp | 5 - .../runtest.sh | 45 --- .../trigger.sh | 7 - tests/Regression/upstream-testsuite/main.fmf | 54 --- .../my_environment_sanity.exp | 6 - .../Regression/upstream-testsuite/runtest.sh | 102 ------ tests/Regression/upstream-testsuite/trimsuite | 40 --- .../Regression/upstream-testsuite/watchdog.sh | 45 --- .../utrace-taskfinder-misses-events/main.fmf | 17 - .../pthreadtestcase.cpp | 35 -- .../pthreadtestcase.stp | 28 -- .../runtest.sh | 77 ----- .../main.fmf | 15 - .../nfs.proc.commit_done.c | 84 ----- .../nfs.proc.commit_done.stp | 3 - .../runtest.sh | 78 ----- .../ThreadedExample.java | 60 ---- .../ThreadedExample.stp | 18 - .../byteman-java-methods-probing/main.fmf | 13 - .../byteman-java-methods-probing/runtest.sh | 83 ----- tests/Sanity/kernel-modules/Makefile.template | 3 - tests/Sanity/kernel-modules/main.fmf | 18 - tests/Sanity/kernel-modules/module.c | 20 -- tests/Sanity/kernel-modules/runtest.sh | 123 ------- tests/Sanity/quick-smoke-test/main.fmf | 17 - tests/Sanity/quick-smoke-test/runtest.sh | 20 -- .../Sanity/stap-server-basic-sanity/main.fmf | 18 - .../stap-server-basic-sanity/runtest.sh | 97 ------ tests/Sanity/userspace-probes/hello.c | 7 - tests/Sanity/userspace-probes/main.fmf | 18 - tests/Sanity/userspace-probes/runtest.sh | 89 ----- tests/Sanity/userspace-probes/testcase1.sh | 3 - tests/Sanity/userspace-probes/testcase2.sh | 4 - 143 files changed, 3 insertions(+), 4838 deletions(-) delete mode 100644 tests/Install/upstream-systemtap/main.fmf delete mode 100755 tests/Install/upstream-systemtap/runtest.sh delete mode 100644 tests/Regression/PR16166/main.fmf delete mode 100755 tests/Regression/PR16166/runtest.sh delete mode 100644 tests/Regression/PR16166/towers.c delete mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/README delete mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/backtrackator.stp delete mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/classes.cpp delete mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/classes.hpp delete mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/golden.out delete mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/main.cpp delete mode 100644 tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf delete mode 100755 tests/Regression/RHEL6Feature-cpp-backtraces/runtest.sh delete mode 100644 tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/classes.cpp delete mode 100644 tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/golden.out delete mode 100644 tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/main.fmf delete mode 100755 tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/runtest.sh delete mode 100644 tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/tracker.stp delete mode 100644 tests/Regression/RHEL6Feature-cpp-inheritance/classes.cpp delete mode 100644 tests/Regression/RHEL6Feature-cpp-inheritance/main.fmf delete mode 100755 tests/Regression/RHEL6Feature-cpp-inheritance/runtest.sh delete mode 100644 tests/Regression/RHEL6Feature-cpp-inheritance/tracker.stp delete mode 100644 tests/Regression/RHEL6Feature-cpp-methods/classes.cpp delete mode 100644 tests/Regression/RHEL6Feature-cpp-methods/golden_summary.out delete mode 100644 tests/Regression/RHEL6Feature-cpp-methods/main.fmf delete mode 100755 tests/Regression/RHEL6Feature-cpp-methods/runtest.sh delete mode 100644 tests/Regression/RHEL6Feature-cpp-methods/tracker.stp delete mode 100644 tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/main.fmf delete mode 100755 tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/runtest.sh delete mode 100644 tests/Regression/bz544960-no-cfa_ops-supplied/README delete mode 100644 tests/Regression/bz544960-no-cfa_ops-supplied/bdflush.stp delete mode 100644 tests/Regression/bz544960-no-cfa_ops-supplied/main.fmf delete mode 100644 tests/Regression/bz544960-no-cfa_ops-supplied/readpages.stp delete mode 100755 tests/Regression/bz544960-no-cfa_ops-supplied/runtest.sh delete mode 100644 tests/Regression/bz544960-no-cfa_ops-supplied/tcp.sendmsg.stp delete mode 100644 tests/Regression/bz706185-various-build-and-run/main.fmf delete mode 100755 tests/Regression/bz706185-various-build-and-run/runtest.sh delete mode 100644 tests/Regression/bz706185-various-build-and-run/softirq.run delete mode 100644 tests/Regression/bz706185-various-build-and-run/softirq.stp delete mode 100644 tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/main.fmf delete mode 100755 tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/runtest.sh delete mode 100644 tests/Regression/elfutils-debuginfod-client-not-being-called/dotest.sh delete mode 100644 tests/Regression/elfutils-debuginfod-client-not-being-called/main.fmf delete mode 100755 tests/Regression/elfutils-debuginfod-client-not-being-called/runtest.sh delete mode 100644 tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/hellotrace.stp delete mode 100644 tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/main.fmf delete mode 100755 tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/runtest.sh delete mode 100644 tests/Regression/ipv6-tapset-support/main.fmf delete mode 100755 tests/Regression/ipv6-tapset-support/nfsd.proc.lookup.stp delete mode 100755 tests/Regression/ipv6-tapset-support/runtest.sh delete mode 100644 tests/Regression/irq-vector-tracepoints/main.fmf delete mode 100755 tests/Regression/irq-vector-tracepoints/runtest.sh delete mode 100644 tests/Regression/netdev-receive/main.fmf delete mode 100755 tests/Regression/netdev-receive/runtest.sh delete mode 100644 tests/Regression/pass-4-failure-netfilter-examples/main.fmf delete mode 100755 tests/Regression/pass-4-failure-netfilter-examples/runtest.sh delete mode 100755 tests/Regression/python-probing/list.stp delete mode 100644 tests/Regression/python-probing/main.fmf delete mode 100755 tests/Regression/python-probing/runtest.sh delete mode 100755 tests/Regression/python-probing/test.py delete mode 100755 tests/Regression/python-probing/top.stp delete mode 100644 tests/Regression/second-command-not-captured/main.fmf delete mode 100644 tests/Regression/second-command-not-captured/ruby-exercise.stp delete mode 100755 tests/Regression/second-command-not-captured/runtest.sh delete mode 100755 tests/Regression/second-command-not-captured/test.sh delete mode 100644 tests/Regression/semantic-error-nfs-proc-read_setup/main.fmf delete mode 100644 tests/Regression/semantic-error-nfs-proc-read_setup/nfs.proc.read_setup.stp delete mode 100755 tests/Regression/semantic-error-nfs-proc-read_setup/runtest.sh delete mode 100644 tests/Regression/semantic-errors-bz1062076/main.fmf delete mode 100755 tests/Regression/semantic-errors-bz1062076/runtest.sh delete mode 100644 tests/Regression/semantic-errors-bz1062076/script.stp delete mode 100644 tests/Regression/semantic-errors-bz953776/main.fmf delete mode 100755 tests/Regression/semantic-errors-bz953776/runtest.sh delete mode 100644 tests/Regression/small-tests-wrapper-001/main.fmf delete mode 100755 tests/Regression/small-tests-wrapper-001/runtest.sh delete mode 120000 tests/Regression/small-tests-wrapper-002 delete mode 120000 tests/Regression/small-tests-wrapper-003 delete mode 120000 tests/Regression/small-tests-wrapper-004 delete mode 120000 tests/Regression/small-tests-wrapper-005 delete mode 120000 tests/Regression/small-tests-wrapper-006 delete mode 120000 tests/Regression/small-tests-wrapper-007 delete mode 120000 tests/Regression/small-tests-wrapper-008 delete mode 120000 tests/Regression/small-tests-wrapper-009 delete mode 120000 tests/Regression/small-tests-wrapper-010 delete mode 120000 tests/Regression/small-tests-wrapper-011 delete mode 120000 tests/Regression/small-tests-wrapper-012 delete mode 120000 tests/Regression/small-tests-wrapper-013 delete mode 120000 tests/Regression/small-tests-wrapper-014 delete mode 120000 tests/Regression/small-tests-wrapper-015 delete mode 120000 tests/Regression/small-tests-wrapper-016 delete mode 120000 tests/Regression/small-tests-wrapper-017 delete mode 120000 tests/Regression/small-tests-wrapper-018 delete mode 120000 tests/Regression/small-tests-wrapper-019 delete mode 100644 tests/Regression/small-tests/main.fmf delete mode 100755 tests/Regression/small-tests/runtest.sh delete mode 100644 tests/Regression/stap-ERROR-Build-id-mismatch-with/main.fmf delete mode 100755 tests/Regression/stap-ERROR-Build-id-mismatch-with/runtest.sh delete mode 100644 tests/Regression/stapio-possible-circular-locking-dependency/main.fmf delete mode 100755 tests/Regression/stapio-possible-circular-locking-dependency/runtest.sh delete mode 100644 tests/Regression/suspicious-RCU-usage/main.fmf delete mode 100755 tests/Regression/suspicious-RCU-usage/runtest.sh delete mode 100644 tests/Regression/syscall-get-arguments-returning-wrong-value/main.fmf delete mode 100755 tests/Regression/syscall-get-arguments-returning-wrong-value/runtest.sh delete mode 100644 tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/main.fmf delete mode 100644 tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/reproducer.stp delete mode 100755 tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/runtest.sh delete mode 100755 tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/trigger.sh delete mode 100644 tests/Regression/task-exe-file-results-in-an-file-struct-leak/main.fmf delete mode 100644 tests/Regression/task-exe-file-results-in-an-file-struct-leak/reproducer.stp delete mode 100644 tests/Regression/task-exe-file-results-in-an-file-struct-leak/reproducer2.stp delete mode 100755 tests/Regression/task-exe-file-results-in-an-file-struct-leak/runtest.sh delete mode 100755 tests/Regression/task-exe-file-results-in-an-file-struct-leak/trigger.sh delete mode 100644 tests/Regression/upstream-testsuite/main.fmf delete mode 100644 tests/Regression/upstream-testsuite/my_environment_sanity.exp delete mode 100755 tests/Regression/upstream-testsuite/runtest.sh delete mode 100755 tests/Regression/upstream-testsuite/trimsuite delete mode 100755 tests/Regression/upstream-testsuite/watchdog.sh delete mode 100644 tests/Regression/utrace-taskfinder-misses-events/main.fmf delete mode 100644 tests/Regression/utrace-taskfinder-misses-events/pthreadtestcase.cpp delete mode 100644 tests/Regression/utrace-taskfinder-misses-events/pthreadtestcase.stp delete mode 100755 tests/Regression/utrace-taskfinder-misses-events/runtest.sh delete mode 100644 tests/Regression/wrong-data-returned-by-nfs-commit-done/main.fmf delete mode 100644 tests/Regression/wrong-data-returned-by-nfs-commit-done/nfs.proc.commit_done.c delete mode 100644 tests/Regression/wrong-data-returned-by-nfs-commit-done/nfs.proc.commit_done.stp delete mode 100755 tests/Regression/wrong-data-returned-by-nfs-commit-done/runtest.sh delete mode 100644 tests/Sanity/byteman-java-methods-probing/ThreadedExample.java delete mode 100644 tests/Sanity/byteman-java-methods-probing/ThreadedExample.stp delete mode 100644 tests/Sanity/byteman-java-methods-probing/main.fmf delete mode 100755 tests/Sanity/byteman-java-methods-probing/runtest.sh delete mode 100644 tests/Sanity/kernel-modules/Makefile.template delete mode 100644 tests/Sanity/kernel-modules/main.fmf delete mode 100644 tests/Sanity/kernel-modules/module.c delete mode 100755 tests/Sanity/kernel-modules/runtest.sh delete mode 100644 tests/Sanity/quick-smoke-test/main.fmf delete mode 100755 tests/Sanity/quick-smoke-test/runtest.sh delete mode 100644 tests/Sanity/stap-server-basic-sanity/main.fmf delete mode 100755 tests/Sanity/stap-server-basic-sanity/runtest.sh delete mode 100644 tests/Sanity/userspace-probes/hello.c delete mode 100644 tests/Sanity/userspace-probes/main.fmf delete mode 100755 tests/Sanity/userspace-probes/runtest.sh delete mode 100755 tests/Sanity/userspace-probes/testcase1.sh delete mode 100755 tests/Sanity/userspace-probes/testcase2.sh diff --git a/plans/ci.fmf b/plans/ci.fmf index c4e22c1..7009e4e 100644 --- a/plans/ci.fmf +++ b/plans/ci.fmf @@ -1,17 +1,9 @@ summary: CI Gating Plan -adjust: - - when: distro == fedora - discover+: - filter: 'tier: 1' - environment+: - DEBUGINFOD_URLS: https://debuginfod.fedoraproject.org/ - DEBUGINFOD_TIMEOUT: 300 - - when: distro == rhel - environment+: - DEBUGINFOD_URLS: https://debuginfod.usersys.redhat.com/ - DEBUGINFOD_TIMEOUT: 300 discover: how: fmf + url: https://src.fedoraproject.org/tests/systemtap-gating.git + ref: main + directory: tests prepare: - name: prepare how: shell diff --git a/tests/Install/upstream-systemtap/main.fmf b/tests/Install/upstream-systemtap/main.fmf deleted file mode 100644 index 2da67d7..0000000 --- a/tests/Install/upstream-systemtap/main.fmf +++ /dev/null @@ -1,51 +0,0 @@ -summary: Build fresh systemtap RPMs from gitcache -description: '' -contact: Martin Cermak -component: - - nothing -test: ./runtest.sh -framework: beakerlib -enabled: false -recommend: - - libstdc++ - - libstdc++-devel - - libstdc++-devel.x86_64 - - libgcc - - glibc-devel - - gcc-c++ - - kernel-devel - - kernel-headers - - git - - curl - - tar - - dejagnu - - elfutils-devel - - gettext - - gettext-devel - - nss-devel - - avahi-devel - - dyninst-devel - - libselinux-devel - - sqlite-devel - - json-c-devel - - ncurses-devel - - crash-devel - - rpm-devel - - rpm-build - - emacs - - jpackage-utils - - java-devel - - libvirt-devel - - libxml2-devel - - readline-devel - - python-devel - - python3-devel - - rpm-build - - python-setuptools - - python2-setuptools - - python2-pyparsing - - dyninst-devel - - elfutils-debuginfod-client-devel -duration: 8h -tag: fedora -order: 1 diff --git a/tests/Install/upstream-systemtap/runtest.sh b/tests/Install/upstream-systemtap/runtest.sh deleted file mode 100755 index 9c613a5..0000000 --- a/tests/Install/upstream-systemtap/runtest.sh +++ /dev/null @@ -1,175 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Install/upstream-head -# Description: create RPMs from the upstream head and install them -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2014 Red Hat, Inc. -# -# This program is free software: you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 2 of -# the License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see http://www.gnu.org/licenses/. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -PATCHURL=${PATCHURL:-https://147.251.27.2/~cermak} -PATCHNAME=${PATCHNAME:-PATCHPATCH7.patch} - -ORIGPWD=$( pwd ) - -# Allow use of debuginfod -# export DEBUGINFOD_URLS=http://debuginfod.usersys.redhat.com:3632/ -# export DEBUGINFOD_PROGRESS=1 - -# if [[ `arch` == *aarch* ]] || [[ `arch` == *s390* ]]; then -# # Definitely do not use debuginfod on aarch64 and s390 -# unset DEBUGINFOD_URLS -# fi - -# https://wiki.test.redhat.com/BaseOs/Tools/SystemTap -TARBALL='systemtap.tar.xz' -# GITCACHE="http://liver2.lab.eng.brq.redhat.com/mcermak/systemtap/gitcache/$TARBALL" -GITCACHE="http://10.43.134.134/systemtap/gitcache/$TARBALL" -export CLONE_CMD='git clone git://sourceware.org/git/systemtap.git' - -PKGMGR="yum --nogpgcheck --enablerepo=\*" -rpm -q dnf && PKGMGR="dnf --setopt=clean_requirements_on_remove=false --setopt=metadata_expire=99999999 --nobest --setopt=strict=0 --nogpgcheck --enablerepo=\*" - -PATCHSOURCES=no -echo $PWD | grep -qF 521-build-stap && PATCHSOURCES=yes -export PATCHSOURCES - -rlJournalStart - rlPhaseStartSetup - rlRun "MY_USER=stapbuilduser" - rlRun "getent passwd ${MY_USER} >/dev/null || useradd ${MY_USER}" - # Work around bz1936469 - rlRun "rpm -q python-unversioned-command && rpm -e python-unversioned-command ||:" - rlRun "env | sort" - rlLogInfo "PATCHSOURCES=$PATCHSOURCES" - rlPhaseEnd - - rlPhaseStart FAIL "Install deps" - rlRun "$PKGMGR clean all" - # rlRun "$PKGMGR -y update" - # rlRun "$PKGMGR -y install $RPM_REQS" - rlRun "$PKGMGR -y install --setopt=multilib_policy=all libgcc glibc-devel gcc-c++ libstdc++-devel" - rlPhaseEnd - - rlPhaseStart FAIL "Build RPMs and install them" - MY_HOME="/home/${MY_USER}" - MY_BUILD="${MY_HOME}/build" - rm -rf /tmp/stap-buildlog /tmp/stap-specfile /tmp/stap-rpms /tmp/stap-git-log -cat > ${MY_BUILD} <<-EOF -set -xe -echo '%_unpackaged_files_terminate_build 0' > ~/.rpmmacros -rm -rf systemtap -( echo attempt-1; $CLONE_CMD) || \ -( echo attempt-2; sleep 20; $CLONE_CMD ) || \ -( echo attempt-3; sleep 90; $CLONE_CMD ) -# tar -xJf /tmp/$TARBALL || curl $GITCACHE | tee /tmp/$TARBALL | tar -xJ -cd systemtap -if test -n "${CHECKOUT_COMMIT}"; then - echo "### ATTEMPTING TO CHECK OUT ${CHECKOUT_COMMIT} ###" - git checkout ${CHECKOUT_COMMIT} || exit 1 -else - echo "### NOT ATTEMPTING TO CHECK OUT SPECIFIC COMMIT ###" -fi -LASTCOMMIT=\$( git log -1 --format=format:'%ct.%h' ) -git log -20 --oneline > /tmp/stap-git-log -sed -i "s/%{?dist}/\.qetst\.\${LASTCOMMIT}%{?dist}/" systemtap.spec -sed -i "s/%{?release_override}//" systemtap.spec -sed -i 's/with_publican\ 1/with_publican\ 0/g' systemtap.spec -sed -i 's/with_docs\ 1/with_docs\ 0/g' systemtap.spec -sed -i 's/with_emacsvim\ 1/with_emacsvim\ 0/' systemtap.spec - -# NB: CONDITIONALLY APPLY THE PATCH -if [ "${PATCHSOURCES}" == "yes" ]; then - wget --no-check-certificate ${PATCHURL}/${PATCHNAME} - patch -p1 < ${PATCHNAME} -fi - -if [[ $(rpm --eval 0%{rhel}) -eq 7 ]]; then - # The upstream specfile tries to require dyninst-devel >= 10.1 on rhel7, which - # is not good for base rhel-7 package (devtoolset-9-dyninst is a special case). - # https://sourceware.org/git/gitweb.cgi?p=systemtap.git;a=blob;f=systemtap.spec;h=670e4010141f5c51e749743bace01815b5585213;hb=HEAD#l134 - sed -i 's/^BuildRequires: dyninst-devel.*/BuildRequires: dyninst-devel/' systemtap.spec - # RHEL-7 doesn't have dyninst on arches other than ppc64 (big endian) and x86_64. - if ! (arch | egrep -q '^(x86_64|ppc64)$'); then - # https://sourceware.org/git/gitweb.cgi?p=systemtap.git;a=blob;f=systemtap.spec;h=670e4010141f5c51e749743bace01815b5585213;hb=HEAD#l18 - sed -i 's/%{!?with_dyninst: %global with_dyninst 0.*/%{!?with_dyninst: %global with_dyninst 0}/' systemtap.spec - fi -fi -git config --global user.name "Martin Cermak" -git config --global user.email mcermak@redhat.com -git commit -am 'Disable publican and emacs, tweak Release.' -cat systemtap.spec > /tmp/stap-specfile -./configure --prefix=/dev/null -make rpm 2>&1 | tee /tmp/stap-buildlog -set +xe -EOF - rlRun "chown ${MY_USER}:${MY_USER} ${MY_BUILD}" - rlRun "su - ${MY_USER} -c 'bash ${MY_BUILD}'" || exit 1 - rlRun "RPMS=\"$( find ${MY_HOME}/rpmbuild/RPMS -type f -name '*rpm' -printf '%p ' )\"" - rlRun "mkdir -p /tmp/stap-rpms /home/stap-rpms" - rlRun "cp $RPMS /tmp/stap-rpms/" - rlRun "cp $RPMS /home/stap-rpms/" - rlRun "$PKGMGR remove -y systemtap-runtime-java systemtap-runtime-virthost \ - systemtap-testsuite systemtap-devel systemtap systemtap-initscript \ - systemtap-runtime systemtap-server systemtap-runtime-virtguest \ - systemtap-sdt-devel systemtap-client systemtap-debuginfo" 0,1 - rlRun "rm -rf /usr/share/systemtap" - rlRun "$PKGMGR clean all" - rlRun "$PKGMGR install -y ${RPMS}" - rlRun "rpm -qa | grep systemtap | sort" - # Test https://bugzilla.redhat.com/show_bug.cgi?id=2012907 - rlRun "rpm -V systemtap-runtime" - RPMVER=$(echo $RPMS | grep -o 'systemtap-[0-9]\+[^\ ]*' | grep -o '.*\.el[0-9]\+') - RPMDIR=/home/.systemtap-upstream-head-rpms/$RPMVER - rm -rf ${RPMDIR}; mkdir -p ${RPMDIR}; - rlRun "cp ${RPMS} ${RPMDIR}/" 0 "Keep built PRMS in ${RPMDIR}" - rlPhaseEnd - - rlPhaseStart WARN "Run stap-prep" - rlRun "rpm -qa | grep ^kernel | grep -v `uname -r` | grep -v headers | xargs rpm -e --nodeps" 0-255 - rlRun "stap-prep" 0-255 - rlPhaseEnd - - rlPhaseStart FAIL "Sanity Check" - rlRun "stap --version" - rlRun "which stap" - rlRun "stap -vve 'probe kernel.function(\"vfs_read\"){ log(\"hey!\"); exit() }'" - rlPhaseEnd - - rlPhaseStart WARN "Submit interesting bits" - rlFileSubmit '/tmp/stap-buildlog' - rlRun 'tar cf /tmp/stap-upstream-rpms.tar /tmp/stap-rpms' - rlRun 'xz /tmp/stap-upstream-rpms.tar' - rlFileSubmit '/tmp/stap-upstream-rpms.tar.xz' - rlRun "rm -rf /tmp/stap-upstream-rpms.tar.xz" - rlFileSubmit '/tmp/stap-specfile' - rlPhaseEnd - - rlPhaseStartCleanup - rlRun "userdel -f ${MY_USER}" - rlRun "rm -rf ${MY_HOME}" - rlPhaseEnd - -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/PR16166/main.fmf b/tests/Regression/PR16166/main.fmf deleted file mode 100644 index 43a9c05..0000000 --- a/tests/Regression/PR16166/main.fmf +++ /dev/null @@ -1,16 +0,0 @@ -summary: Test for BZ#1054962 (Backport PR16166 stap -vvv causes SIGSEGV when) -description: Backport PR16166 -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - valgrind - - systemtap -duration: 15m -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1054962 -extra-summary: /tools/systemtap/Regression/PR16166 -extra-task: /tools/systemtap/Regression/PR16166 -tag: fedora diff --git a/tests/Regression/PR16166/runtest.sh b/tests/Regression/PR16166/runtest.sh deleted file mode 100755 index b2b2258..0000000 --- a/tests/Regression/PR16166/runtest.sh +++ /dev/null @@ -1,67 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/PR16166 -# Description: Test for BZ#1054962 (Backport PR16166 stap -vvv causes SIGSEGV when) -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2014 Red Hat, Inc. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -rlJournalStart - rlPhaseStartSetup - rlRun "TMPDIR=\$(mktemp -d)" - rlRun "cp towers.c $TMPDIR/" - rlRun "pushd $TMPDIR" - - rlRun "gcc -g towers.c -o towers.x" - - cat > script.stp <<-EOF -global x - -probe perf.hw.cpu_cycles.process("towers.x").counter("a") {} - -probe process("towers.x").function("main") -{ - # wrong type - x = "b" . @perf("a") -} -EOF - rlRun "which valgrind" - rlRun "valgrind --version" - rlPhaseEnd - - rlPhaseStartTest - # following is expected to fail - rlRun "valgrind --log-file=output.txt stap -vvv script.stp" 1 - # ... but not to segfault - rlRun "grep SIGSEGV output.txt" 1 - rlPhaseEnd - - rlPhaseStartCleanup - rlRun "popd" - rlRun "rm -r $TMPDIR" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/PR16166/towers.c b/tests/Regression/PR16166/towers.c deleted file mode 100644 index f8a5a20..0000000 --- a/tests/Regression/PR16166/towers.c +++ /dev/null @@ -1,155 +0,0 @@ -# include -# include - -#define towersbase 2.39 - -/* Towers */ -#define maxcells 18 -#define stackrange 3 -#define true 1 -#define false 0 - -struct element -{ - int discsize; - int next; -}; - -/* Towers */ -int stack[stackrange + 1]; -struct element cellspace[maxcells + 1]; -int freelist, movesdone; - -/* Program to Solve the Towers of Hanoi */ - -void -error (emsg) - char *emsg; -{ - printf ("Error in Towers: %s\n", emsg); -} - -void -makenull (int s) -{ - stack[s] = 0; -} - -int -get_element () -{ - int temp; - if (freelist > 0) - { - temp = freelist; - freelist = cellspace[freelist].next; - } - else - error ("out of space "); - return (temp); -} - -void -push (i, s) - int i, s; -{ - int errorfound, localel; - errorfound = false; - if (stack[s] > 0) - if (cellspace[stack[s]].discsize <= i) - { - errorfound = true; - error ("disc size error"); - }; - if (!errorfound) - { - localel = get_element (); - cellspace[localel].next = stack[s]; - stack[s] = localel; - cellspace[localel].discsize = i; - } -} - -void -init (s, n) - int s, n; -{ - int discctr; - makenull (s); - for (discctr = n; discctr >= 1; discctr--) - push (discctr, s); -} - -int -pop (s) - int s; -{ - int temp, temp1; - if (stack[s] > 0) - { - temp1 = cellspace[stack[s]].discsize; - temp = cellspace[stack[s]].next; - cellspace[stack[s]].next = freelist; - freelist = stack[s]; - stack[s] = temp; - return (temp1); - } - else - error ("nothing to pop "); - return 0; -} - -void -move (s1, s2) - int s1, s2; -{ - push (pop (s1), s2); - movesdone = movesdone + 1; -} - -void -tower (i, j, k) - int i, j, k; -{ - int other; - if (k == 1) - move (i, j); - else - { - other = 6 - i - j; - tower (i, other, k - 1); - move (i, j); - tower (other, j, k - 1); - } -} - - -void -towers () -{ - int i; - for (i = 1; i <= maxcells; i++) - cellspace[i].next = i - 1; - freelist = maxcells; - init (1, 14); - makenull (2); - makenull (3); - movesdone = 0; - tower (1, 2, 14); - if (movesdone != 16383) - printf (" error in Towers.\n"); -} - -#ifndef LOOP -#define LOOP 500 -#endif - -int -main () -{ - int i; - for (i= 0; i < LOOP; i++) - towers(); - return 0; -} - diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/README b/tests/Regression/RHEL6Feature-cpp-backtraces/README deleted file mode 100644 index 3211489..0000000 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/README +++ /dev/null @@ -1,31 +0,0 @@ - -With 5.18.0-0.rc5.20220504git107c948d1d3e61d.42.fc37.x86_64 we have - - - ----------------------8<-------------------------------------------------------- -:: [ 08:26:39 ] :: [ BEGIN ] :: Running 'stap --skip-badvars --ldd backtrackator.stp -c ./classes > output.out' -In file included from /usr/share/systemtap/runtime/linux/../regs.c:20, - from /usr/share/systemtap/runtime/linux/runtime.h:270, - from /usr/share/systemtap/runtime/runtime.h:26, - from /tmp/stap7hYYpn/stap_9beffd9064cc2c18ddd2daf7f47a7e44_5966_src.c:21: -/usr/share/systemtap/runtime/stack.c: In function ‘_stp_stack_unwind_one_kernel’: -/usr/share/systemtap/runtime/linux/../linux/regs.c:23:32: error: ‘struct kretprobe_instance’ has no member named ‘ret_addr’ - 23 | #define _stp_ret_addr_r(ri) (ri->ret_addr) - | ^~ -/usr/share/systemtap/runtime/stack.c:358:47: note: in expansion of macro ‘_stp_ret_addr_r’ - 358 | return (unsigned long)_stp_ret_addr_r(c->ips.krp.pi); - | ^~~~~~~~~~~~~~~ -make[1]: *** [scripts/Makefile.build:288: /tmp/stap7hYYpn/stap_9beffd9064cc2c18ddd2daf7f47a7e44_5966_src.o] Error 1 -make[1]: *** Waiting for unfinished jobs.... -make: *** [Makefile:1844: /tmp/stap7hYYpn] Error 2 -WARNING: kbuild exited with status: 2 -Pass 4: compilation failed. [man error::pass4] -:: [ 08:26:59 ] :: [ FAIL ] :: Command 'stap --skip-badvars --ldd backtrackator.stp -c ./classes > output.out' (Expected 0, got 1) ----------------------8<-------------------------------------------------------- - - -Related to CONFIG_KRETPROBE_ON_RETHOOK https://elixir.bootlin.com/linux/v5.18-rc5/source/include/linux/kprobes.h#L163 - - -Needs fixing on the stap side. diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/backtrackator.stp b/tests/Regression/RHEL6Feature-cpp-backtraces/backtrackator.stp deleted file mode 100644 index 18a4248..0000000 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/backtrackator.stp +++ /dev/null @@ -1,15 +0,0 @@ -function mypr:long(){ - printf("================================================================================\n"); - printf("Probed function: [%s]\n\n", probefunc()); - printf ("Backtrace:\n"); - - print_ubacktrace(); - return 0; -} - - - -probe process("classes").function("public*") { mypr(); } -probe process("classes").function("private*") { mypr(); } -probe process("classes").function("recursive*") { mypr(); } -probe process("classes").function("main*") { mypr(); } diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/classes.cpp b/tests/Regression/RHEL6Feature-cpp-backtraces/classes.cpp deleted file mode 100644 index 1c42084..0000000 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/classes.cpp +++ /dev/null @@ -1,43 +0,0 @@ -#include "classes.hpp" -#include - -void A::privateA1(){ - std::cout << "privateA1" << std::endl; - this->privateA2(); - -} - -void A::privateA2(){ - std::cout << "privateA2" << std::endl; - this->recursiveA1(3); - -} - -void A::recursiveA1(int count){ - std::cout << "recursiveA1: " << count << std::endl; - if (count == 0) - return; - this->recursiveA1(count-1); - return; -} - -void A::publicA1(){ - std::cout << "publicA1" << std::endl; - this->publicA2(); -} - -void A::publicA2(){ - std::cout << "publicA2" << std::endl; - this->privateA1(); -} - - -void B::privateB1(A a){ - std::cout << "privateB1" << std::endl; - a.publicA1(); -} - -void B::publicB1(A a){ - std::cout << "publicB1" << std::endl; - this->privateB1(a); -} diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/classes.hpp b/tests/Regression/RHEL6Feature-cpp-backtraces/classes.hpp deleted file mode 100644 index 0846ae2..0000000 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/classes.hpp +++ /dev/null @@ -1,16 +0,0 @@ -class A{ - private: - void privateA1(); - void privateA2(); - void recursiveA1(int); - public: - void publicA1(); - void publicA2(); -}; - -class B{ - private: - void privateB1(A); - public: - void publicB1(A); -}; diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.out b/tests/Regression/RHEL6Feature-cpp-backtraces/golden.out deleted file mode 100644 index 9f643d6..0000000 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/golden.out +++ /dev/null @@ -1,77 +0,0 @@ -================================================================================ -Probed function: [main] -================================================================================ -Probed function: [publicB1] -publicB1 -================================================================================ -Probed function: [privateB1] -privateB1 -publicB1 -================================================================================ -Probed function: [publicA1] -publicA1 -privateB1 -publicB1 -================================================================================ -Probed function: [publicA2] -publicA2 -publicA1 -privateB1 -publicB1 -================================================================================ -Probed function: [privateA1] -privateA1 -publicA2 -publicA1 -privateB1 -publicB1 -================================================================================ -Probed function: [privateA2] -privateA2 -privateA1 -publicA2 -publicA1 -privateB1 -publicB1 -================================================================================ -Probed function: [recursiveA1] -recursiveA1 -privateA2 -privateA1 -publicA2 -publicA1 -privateB1 -publicB1 -================================================================================ -Probed function: [recursiveA1] -recursiveA1 -recursiveA1 -privateA2 -privateA1 -publicA2 -publicA1 -privateB1 -publicB1 -================================================================================ -Probed function: [recursiveA1] -recursiveA1 -recursiveA1 -recursiveA1 -privateA2 -privateA1 -publicA2 -publicA1 -privateB1 -publicB1 -================================================================================ -Probed function: [recursiveA1] -recursiveA1 -recursiveA1 -recursiveA1 -recursiveA1 -privateA2 -privateA1 -publicA2 -publicA1 -privateB1 -publicB1 diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/main.cpp b/tests/Regression/RHEL6Feature-cpp-backtraces/main.cpp deleted file mode 100644 index 69ae514..0000000 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/main.cpp +++ /dev/null @@ -1,10 +0,0 @@ -#include "classes.hpp" - -int main(){ - A a; - B b; - - b.publicB1(a); - return 0; -} - diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf b/tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf deleted file mode 100644 index e0b5ee9..0000000 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/main.fmf +++ /dev/null @@ -1,14 +0,0 @@ -summary: Tests backtracking in C++ programs -description: '' -contact: Petr Muller -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap - - gcc-c++ -duration: 10m -extra-summary: /tools/systemtap/Regression/RHEL6Feature-cpp-backtraces -extra-task: /tools/systemtap/Regression/RHEL6Feature-cpp-backtraces -tag: fedora diff --git a/tests/Regression/RHEL6Feature-cpp-backtraces/runtest.sh b/tests/Regression/RHEL6Feature-cpp-backtraces/runtest.sh deleted file mode 100755 index 629c082..0000000 --- a/tests/Regression/RHEL6Feature-cpp-backtraces/runtest.sh +++ /dev/null @@ -1,66 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/RHEL6Feature-cpp-backtraces -# Description: Tests backtracking in C++ programs -# Author: Petr Muller -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2010 Red Hat, Inc. All rights reserved. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include rhts environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 -. /etc/os-release || exit 1 - -PACKAGE="systemtap" - -rlJournalStart - -rlPhaseStartSetup - rlRun "g++ classes.cpp main.cpp -g -o classes" - rlRun "stap-prep" 0-255 -rlPhaseEnd - -rlPhaseStartTest - rlRun "stap --ldd backtrackator.stp -c ./classes -o output.out" - rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*publicA1[A-Za-z0-9]*/publicA1/g' output.out" - rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*publicA2[A-Za-z0-9]*/publicA2/g' output.out" - rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*privateA1[A-Za-z0-9]*/privateA1/g' output.out" - rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*privateA2[A-Za-z0-9]*/privateA2/g' output.out" - rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*recursiveA1[A-Za-z0-9]*/recursiveA1/g' output.out" - rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*publicB1[A-Za-z0-9]*/publicB1/g' output.out" - rlRun "sed -i -r -e 's/_[_A-Za-z0-9]*privateB1[A-Za-z0-9]*/privateB1/g' output.out" - rlRun "grep -o -e publicA1 -e publicA2 -e privateA1 -e privateA2 -e recursiveA1 \ - -e publicB1 -e privateB1 -e 'Probed function:.*' -e '=*' \ - output.out > output.processed" - rlRun "diff output.processed golden.out" -rlPhaseEnd - -rlPhaseStartCleanup - rlFileSubmit output.out - rlFileSubmit output.processed - rlFileSubmit golden.out - rlRun "rm -f output.out output.processed" -rlPhaseEnd - -rlJournalPrintText - -rlJournalEnd diff --git a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/classes.cpp b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/classes.cpp deleted file mode 100644 index cd488c5..0000000 --- a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/classes.cpp +++ /dev/null @@ -1,39 +0,0 @@ -#include - -class Explicit{ - public: - int data; - Explicit(); - Explicit(int argument); - Explicit(const Explicit &original); - ~Explicit(); -}; - -class Implicit{ - public: - int data; -}; - -Explicit::Explicit() { this->data=0; } -Explicit::Explicit(int a) {this->data=0; } -Explicit::Explicit(const Explicit &orig){this->data = orig.data;} -Explicit::~Explicit(){} - -int main(){ - Explicit e1; //static ctor call - Explicit *e2; - - e2 = new Explicit(); //dynamic ctor call - delete e2; //dynamic dtor call - - e2 = new Explicit(2); //dynamic ctor call - Explicit e3 = *e2; //copy ctor - delete e2; //dtor - - Implicit i1; //ctor - Implicit *i2 = new Implicit(); //ctor - Implicit i3 = *i2; //implicit copy ctor - delete i2; //dtor - - return 0; // dtor e1, e3, i1, i3 -} diff --git a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/golden.out b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/golden.out deleted file mode 100644 index f45ff90..0000000 --- a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/golden.out +++ /dev/null @@ -1,16 +0,0 @@ -Explicit constructor start -Explicit constructor end -Explicit constructor start -Explicit constructor end -Explicit destructor start -Explicit destructor end -Explicit constructor start -Explicit constructor end -Explicit constructor start -Explicit constructor end -Explicit destructor start -Explicit destructor end -Explicit destructor start -Explicit destructor end -Explicit destructor start -Explicit destructor end diff --git a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/main.fmf b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/main.fmf deleted file mode 100644 index 940dae3..0000000 --- a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/main.fmf +++ /dev/null @@ -1,14 +0,0 @@ -summary: Tests probing constructors and destructors -description: '' -contact: Petr Muller -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap - - gcc-c++ -duration: 5m -extra-summary: /tools/systemtap/Regression/RHEL6Feature-cpp-ctors-and-dtors -extra-task: /tools/systemtap/Regression/RHEL6Feature-cpp-ctors-and-dtors -tag: fedora diff --git a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/runtest.sh b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/runtest.sh deleted file mode 100755 index fc72f6b..0000000 --- a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/runtest.sh +++ /dev/null @@ -1,52 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/RHEL6Feature-cpp-ctors-and-dtors -# Description: Tests probing constructors and destructors -# Author: Petr Muller -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2010 Red Hat, Inc. All rights reserved. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include rhts environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -PACKAGE="systemtap" - -rlJournalStart - -rlPhaseStartSetup - rlRun "g++ classes.cpp -g -o classes" -rlPhaseEnd - -rlPhaseStartTest - rlRun "stap -c ./classes tracker.stp -o output.out" - rlAssertNotDiffer golden.out output.out -rlPhaseEnd - -rlPhaseStartCleanup - rlFileSubmit "output.out" - rlFileSubmit "golden.out" - rlRun "rm -rf classes output.out" -rlPhaseEnd - -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/tracker.stp b/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/tracker.stp deleted file mode 100644 index 8ff0bb1..0000000 --- a/tests/Regression/RHEL6Feature-cpp-ctors-and-dtors/tracker.stp +++ /dev/null @@ -1,23 +0,0 @@ -probe process("classes").function("Explicit::Explicit"){ - printf("Explicit constructor start\n"); -} - -probe process("classes").function("Explicit::~Explicit"){ - printf("Explicit destructor start\n"); -} - -probe process("classes").function("Explicit::Explicit").return{ - printf("Explicit constructor end\n"); -} - -probe process("classes").function("Explicit::~Explicit").return{ - printf("Explicit destructor end\n"); -} - -//probe process("classes").function("Implicit::Implicit"){ -// printf("Implicitconstructor\n"); -//} - -//probe process("classes").function("Implicit::Implicit"){ -// printf("Implicit constructor\n"); -//} diff --git a/tests/Regression/RHEL6Feature-cpp-inheritance/classes.cpp b/tests/Regression/RHEL6Feature-cpp-inheritance/classes.cpp deleted file mode 100644 index 2ab3e54..0000000 --- a/tests/Regression/RHEL6Feature-cpp-inheritance/classes.cpp +++ /dev/null @@ -1,56 +0,0 @@ -#include - -class A{ - public: - void one(){ std::cout << "A::one" << std::endl; } - void two(){ std::cout << "A::two" << std::endl; } - virtual void three() { std::cout << "A::three" << std::endl; } - virtual void four() { std::cout << "A::four" << std::endl; } -}; - -class B : public A{ - public: - void one() { std::cout << "B::one" << std::endl; } - int one(int a) { std::cout << "B::one" << std::endl; } - - virtual void three() { std::cout << "B::three" << std::endl; } -}; - -int main(){ - A a; - B b; - - A *ap = new A(); - A *apb = new B(); - - B *bp = new B(); - - - a.one(); - a.two(); - a.three(); - a.four(); - - b.one(); - b.two(); - b.three(); - b.four(); - - ap->one(); - ap->two(); - ap->three(); - ap->four(); - - apb->one(); - apb->two(); - apb->three(); - apb->four(); - - bp->one(); - bp->two(); - bp->three(); - bp->four(); - - - return 0; -} diff --git a/tests/Regression/RHEL6Feature-cpp-inheritance/main.fmf b/tests/Regression/RHEL6Feature-cpp-inheritance/main.fmf deleted file mode 100644 index 86d5648..0000000 --- a/tests/Regression/RHEL6Feature-cpp-inheritance/main.fmf +++ /dev/null @@ -1,14 +0,0 @@ -summary: Tests systemtap handling inheritance -description: '' -contact: Petr Muller -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap - - gcc-c++ -duration: 10m -extra-summary: /tools/systemtap/Regression/RHEL6Feature-cpp-inheritance -extra-task: /tools/systemtap/Regression/RHEL6Feature-cpp-inheritance -tag: fedora diff --git a/tests/Regression/RHEL6Feature-cpp-inheritance/runtest.sh b/tests/Regression/RHEL6Feature-cpp-inheritance/runtest.sh deleted file mode 100755 index deec9ce..0000000 --- a/tests/Regression/RHEL6Feature-cpp-inheritance/runtest.sh +++ /dev/null @@ -1,56 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/RHEL6Feature-cpp-inheritance -# Description: Tests systemtap handling inheritance -# Author: Petr Muller -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2010 Red Hat, Inc. All rights reserved. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include rhts environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -# if this testcase caused kernel crash and reboot, don't try to rerun it -[[ $REBOOTCOUNT -gt 0 ]] && exit 1 - -PACKAGE="systemtap" - -rlJournalStart - -rlPhaseStartSetup - rlRun "g++ classes.cpp -o classes -g" - rlRun "./classes > program.out" 0 "Preparing the golden output" -rlPhaseEnd - -rlPhaseStartTest - rlRun "stap -c ./classes tracker.stp -o stap.out" - rlAssertNotDiffer program.out stap.out -rlPhaseEnd - -rlPhaseStartCleanup - rlFileSubmit program.out - rlFileSubmit stap.out - rlRun "rm -f classes stap.out program.out" -rlPhaseEnd - -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/RHEL6Feature-cpp-inheritance/tracker.stp b/tests/Regression/RHEL6Feature-cpp-inheritance/tracker.stp deleted file mode 100644 index 525ced5..0000000 --- a/tests/Regression/RHEL6Feature-cpp-inheritance/tracker.stp +++ /dev/null @@ -1,6 +0,0 @@ -probe process("classes").function("A::one"){printf("A::one\n");} -probe process("classes").function("A::two"){printf("A::two\n");} -probe process("classes").function("A::three"){printf("A::three\n");} -probe process("classes").function("A::four"){printf("A::four\n");} -probe process("classes").function("B::one"){printf("B::one\n");} -probe process("classes").function("B::three"){printf("B::three\n");} diff --git a/tests/Regression/RHEL6Feature-cpp-methods/classes.cpp b/tests/Regression/RHEL6Feature-cpp-methods/classes.cpp deleted file mode 100644 index e947234..0000000 --- a/tests/Regression/RHEL6Feature-cpp-methods/classes.cpp +++ /dev/null @@ -1,71 +0,0 @@ -__attribute__((noinline)) void StandaloneFunction(){ - -} - -class CLASS1{ - private: - void prMethod() {}; - public: - void puMethod() {this->prMethod();}; - static void stMethod() {}; -}; - -namespace inner{ - void StandaloneFunction(){ - } - - class CLASS1{ - private: - void prMethod() {}; - public: - void puMethod() {this->prMethod();}; - static void stMethod() {}; - }; -}; - -namespace moreinner{ - void StandaloneFunction(){ - } - - class CLASS1{ - private: - __attribute__((noinline)) void prMethod() {}; - public: - __attribute__((noinline)) void puMethod() {this->prMethod();}; - __attribute__((noinline)) static void stMethod() {}; - }; -}; - -int main(){ - StandaloneFunction(); - inner::StandaloneFunction(); - moreinner::StandaloneFunction(); - - CLASS1 A; - inner::CLASS1 B; - moreinner::CLASS1 C; - - CLASS1* pA = new CLASS1(); - inner::CLASS1 *pB = new inner::CLASS1(); - moreinner::CLASS1 *pC = new moreinner::CLASS1(); - - A.puMethod(); - A.stMethod(); - - B.puMethod(); - B.stMethod(); - - C.puMethod(); - C.stMethod(); - - pA->puMethod(); - pA->stMethod(); - - pB->puMethod(); - pB->stMethod(); - - pC->puMethod(); - pC->stMethod(); - - return 0; -} diff --git a/tests/Regression/RHEL6Feature-cpp-methods/golden_summary.out b/tests/Regression/RHEL6Feature-cpp-methods/golden_summary.out deleted file mode 100644 index 4072ed7..0000000 --- a/tests/Regression/RHEL6Feature-cpp-methods/golden_summary.out +++ /dev/null @@ -1,13 +0,0 @@ -__hitcount=70 -__inner_CLASS1_prMethod=0 -__inner_CLASS1_puMethod=0 -__inner_CLASS1_stMethod=0 -__inner_StandaloneFunction=0 -__moreinner_StandaloneFunction=0 -__moreinner_star_prMethod=0 -__moreinner_star_puMethod=0 -__moreinner_star_stMethod=0 -__prMethod=0 -__puMethod=0 -__StandaloneFunction=0 -__stMethod=0 diff --git a/tests/Regression/RHEL6Feature-cpp-methods/main.fmf b/tests/Regression/RHEL6Feature-cpp-methods/main.fmf deleted file mode 100644 index e2d9c88..0000000 --- a/tests/Regression/RHEL6Feature-cpp-methods/main.fmf +++ /dev/null @@ -1,14 +0,0 @@ -summary: Tests C++ methods -description: '' -contact: Petr Muller -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap - - gcc-c++ -duration: 120m -extra-summary: /tools/systemtap/Regression/RHEL6Feature-cpp-methods -extra-task: /tools/systemtap/Regression/RHEL6Feature-cpp-methods -tag: fedora diff --git a/tests/Regression/RHEL6Feature-cpp-methods/runtest.sh b/tests/Regression/RHEL6Feature-cpp-methods/runtest.sh deleted file mode 100755 index a019d7a..0000000 --- a/tests/Regression/RHEL6Feature-cpp-methods/runtest.sh +++ /dev/null @@ -1,72 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/RHEL6Feature-cpp-methods -# Description: Tests C++ methods -# Author: Petr Muller -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2010 Red Hat, Inc. All rights reserved. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include rhts environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -PACKAGE="systemtap" -export LANG=C - -rlJournalStart - -rlPhaseStartSetup - rlRun "stap-prep" 0-255 - rlRun "g++ -O0 classes.cpp -o classes -g" -rlPhaseEnd - -rlPhaseStartTest - rlRun "stap $COMPAT -c ./classes tracker.stp -o output.out" - # Stop comparing literally against a golden file, - # do a sanity check instead. The literal golden file check - # sort of regressed between rhel-8.2 and rhel-8.3 - # rlRun "diff golden.out output.out" - rlRun "grep ^__ output.out | sort > summary.out" - - # The way sort works across test systems may differ - # esp wrt whether capitals go first or not, so let's sort - # the golden_summary.out first using actual defaults - # slash LANG etc... - rlRun "sort golden_summary.out > golden_summary.sort" - - # RHEL6: covert hex to dec: - rlRun "sed -i 's/0x0/0/' summary.out" - rlRun "sed -i 's/0x46/70/' summary.out" - - # Sanity check - rlRun "diff golden_summary.sort summary.out" || ( - rlRun "cat golden_summary.out" - rlRun "cat summary.out" - ) -rlPhaseEnd - -rlPhaseStartCleanup - rlRun "rm -f golden_summary.sort output.out summary.out classes" -rlPhaseEnd - -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/RHEL6Feature-cpp-methods/tracker.stp b/tests/Regression/RHEL6Feature-cpp-methods/tracker.stp deleted file mode 100644 index 54e15b3..0000000 --- a/tests/Regression/RHEL6Feature-cpp-methods/tracker.stp +++ /dev/null @@ -1,162 +0,0 @@ -global __hitcount = 0 -global __StandaloneFunction = 0 -global __inner_StandaloneFunction = 0 -global __moreinner_StandaloneFunction = 0 -global __stMethod = 0 -global __inner_CLASS1_stMethod = 0 -global __moreinner_star_stMethod = 0 -global __prMethod = 0 -global __inner_CLASS1_prMethod = 0 -global __moreinner_star_prMethod = 0 -global __puMethod = 0 -global __inner_CLASS1_puMethod = 0 -global __moreinner_star_puMethod = 0 - -probe process("classes").function("StandaloneFunction").call{ - __StandaloneFunction++ - __hitcount++ - printf("StandaloneFunction start: %s\n", probefunc()); -} - -probe process("classes").function("StandaloneFunction").return{ - __StandaloneFunction-- - __hitcount++ - printf("StandaloneFunction end: %s\n", probefunc()); -} - -probe process("classes").function("inner::StandaloneFunction").call{ - __inner_StandaloneFunction++ - __hitcount++ - printf("inner::StandaloneFunction start: %s\n", probefunc()); -} - -probe process("classes").function("inner::StandaloneFunction").return{ - __inner_StandaloneFunction-- - __hitcount++ - printf("inner::StandaloneFunction end: %s\n", probefunc()); -} - -probe process("classes").function("moreinner::StandaloneFunction").call{ - __moreinner_StandaloneFunction++ - __hitcount++ - printf("moreinner::StandaloneFunction start: %s\n", probefunc()); -} - -probe process("classes").function("moreinner::StandaloneFunction").return{ - __moreinner_StandaloneFunction-- - __hitcount++ - printf("moreinner::StandaloneFunction end: %s\n", probefunc()); -} -// ============================================================================ -probe process("classes").function("stMethod").call{ - __stMethod++ - __hitcount++ - printf("stMethod start: %s\n", probefunc()); -} - -probe process("classes").function("stMethod").return{ - __stMethod-- - __hitcount++ - printf("stMethod end: %s\n", probefunc()); -} - -probe process("classes").function("inner::CLASS1::stMethod").call{ - __inner_CLASS1_stMethod++ - __hitcount++ - printf("inner::stMethod start: %s\n", probefunc()); -} - -probe process("classes").function("inner::CLASS1::stMethod").return{ - __inner_CLASS1_stMethod-- - __hitcount++ - printf("inner::stMethod end: %s\n", probefunc()); -} - -probe process("classes").function("moreinner::*::stMethod").call{ - __moreinner_star_stMethod++ - __hitcount++ - printf("moreinner::stMethod start: %s\n", probefunc()); -} - -probe process("classes").function("moreinner::*::stMethod").return{ - __moreinner_star_stMethod-- - __hitcount++ - printf("moreinner::stMethod end: %s\n", probefunc()); -} -//============================================================================= - -probe process("classes").function("prMethod").call{ - __prMethod++ - __hitcount++ - printf("prMethod start: %s\n", probefunc()); -} - -probe process("classes").function("prMethod").return{ - __prMethod-- - __hitcount++ - printf("prMethod end: %s\n", probefunc()); -} - -probe process("classes").function("inner::CLASS1::prMethod").call{ - __inner_CLASS1_prMethod++ - __hitcount++ - printf("inner::prMethod start: %s\n", probefunc()); -} - -probe process("classes").function("inner::CLASS1::prMethod").return{ - __inner_CLASS1_prMethod-- - __hitcount++ - printf("inner::prMethod end: %s\n", probefunc()); -} - -probe process("classes").function("moreinner::*::prMethod").call{ - __moreinner_star_prMethod++ - __hitcount++ - printf("moreinner::prMethod start: %s\n", probefunc()); -} - -probe process("classes").function("moreinner::*::prMethod").return{ - __moreinner_star_prMethod-- - __hitcount++ - printf("moreinner::prMethod end: %s\n", probefunc()); -} - -//============================================================================= - -probe process("classes").function("puMethod").call{ - __puMethod++ - __hitcount++ - printf("puMethod start: %s\n", probefunc()); -} - -probe process("classes").function("puMethod").return{ - __puMethod-- - __hitcount++ - printf("puMethod end: %s\n", probefunc()); -} - -probe process("classes").function("inner::CLASS1::puMethod").call{ - __inner_CLASS1_puMethod++ - __hitcount++ - printf("inner::puMethod start: %s\n", probefunc()); -} - -probe process("classes").function("inner::CLASS1::puMethod").return{ - __inner_CLASS1_puMethod-- - __hitcount++ - printf("inner::puMethod end: %s\n", probefunc()); -} - -probe process("classes").function("moreinner::*::puMethod").call{ - __moreinner_star_puMethod++ - __hitcount++ - printf("moreinner::puMethod start: %s\n", probefunc()); -} - -probe process("classes").function("moreinner::*::puMethod").return{ - __moreinner_star_puMethod-- - __hitcount++ - printf("moreinner::puMethod end: %s\n", probefunc()); -} - - diff --git a/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/main.fmf b/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/main.fmf deleted file mode 100644 index 7078911..0000000 --- a/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/main.fmf +++ /dev/null @@ -1,15 +0,0 @@ -summary: Test for BZ#1572501 (RHEL7.5 - backtraces no longer work with systemtap) -description: Test for BZ#1572501 -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap -duration: 48h -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1572501 -extra-summary: /tools/systemtap/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap -extra-task: /tools/systemtap/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap -tag: fedora diff --git a/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/runtest.sh b/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/runtest.sh deleted file mode 100755 index 94cf2cc..0000000 --- a/tests/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap/runtest.sh +++ /dev/null @@ -1,49 +0,0 @@ -#!/bin/bash -# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/RHEL7-5-backtraces-no-longer-work-with-systemtap -# Description: Test for BZ#1572501 (RHEL7.5 - backtraces no longer work with systemtap) -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2018 Red Hat, Inc. -# -# This program is free software: you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 2 of -# the License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see http://www.gnu.org/licenses/. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -PACKAGE="systemtap" - -rlJournalStart - rlPhaseStartTest - if arch | grep -q s390x; then - rlLogWarning "Test not relevant" - else - TEMPFILE=$(mktemp) - rlRun "stap --all-modules -vwe 'probe kernel.function(\"kmem_cache_alloc\")?, kernel.function(\"schedule\") { print_backtrace(); exit() }' >& $TEMPFILE" - # since it's hard to find some reasonable pattern to grep for across arches in the backrtrace - # we'll simply count the lines. We'll want at least 9 lines of output (6 as the results of -v, - # and another at least three coming from the backtrace itself. - rlRun "cat $TEMPFILE" - rlRun "test 9 -le $(wc -l $TEMPFILE | awk '{print $1}')" - rm $TEMPFILE - fi - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/bz544960-no-cfa_ops-supplied/README b/tests/Regression/bz544960-no-cfa_ops-supplied/README deleted file mode 100644 index f1152ea..0000000 --- a/tests/Regression/bz544960-no-cfa_ops-supplied/README +++ /dev/null @@ -1,63 +0,0 @@ -Kernel porting needed. - -:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -:: Test -:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: - -:: [ 09:22:47 ] :: [ INFO ] :: Checking whether we might want to try prologue search. -:: [ 09:23:10 ] :: [ BEGIN ] :: Running 'stap -P -vp4 readpages.stp' -Pass 1: parsed user script and 484 library scripts using 122428virt/95036res/15532shr/79120data kb, in 200usr/110sys/315real ms. -WARNING: never-assigned local variable 'nr_pages' (similar: rpages, __page, dev, name, file): identifier 'nr_pages' at readpages.stp:5:26 - source: printf("nr_pages=%d\n", nr_pages); - ^ -WARNING: never-assigned local variable 'rpages' (similar: nr_pages, __page, dev, name, rsize): identifier 'rpages' at :7:24 - source: printf("rpages=%d\n", rpages); - ^ -Pass 2: analyzed script: 2 probes, 17 functions, 3 embeds, 0 globals using 351676virt/327836res/19060shr/308368data kb, in 2880usr/1970sys/4927real ms. -Pass 3: translated to C into "/tmp/stapWU958g/stap_f189533513b6d61221ada924fedfc9c4_6369_src.c" using 351692virt/327964res/19188shr/308384data kb, in 490usr/800sys/1301real ms. -In file included from /usr/share/systemtap/runtime/linux/../regs.c:16, - from /usr/share/systemtap/runtime/linux/runtime.h:270, - from /usr/share/systemtap/runtime/runtime.h:26, - from /tmp/stapWU958g/stap_f189533513b6d61221ada924fedfc9c4_6369_src.c:21: -/tmp/stapWU958g/stap_f189533513b6d61221ada924fedfc9c4_6369_src.c: In function ‘enter_kretprobe_common’: -/tmp/stapWU958g/stap_f189533513b6d61221ada924fedfc9c4_6369_src.c:2499:45: error: ‘struct kretprobe_instance’ has no member named ‘ret_addr’ - 2499 | SET_REG_IP(regs, (unsigned long)inst->ret_addr); - | ^~ -/usr/share/systemtap/runtime/linux/../regs.h:85:44: note: in definition of macro ‘SET_REG_IP’ - 85 | #define SET_REG_IP(regs, x) REG_IP(regs) = x - | ^ -make[1]: *** [scripts/Makefile.build:288: /tmp/stapWU958g/stap_f189533513b6d61221ada924fedfc9c4_6369_src.o] Error 1 -make: *** [Makefile:1844: /tmp/stapWU958g] Error 2 -WARNING: kbuild exited with status: 2 -Pass 4: compiled C into "stap_f189533513b6d61221ada924fedfc9c4_6369.ko" in 1150usr/1910sys/2659real ms. -Pass 4: compilation failed. [man error::pass4] -:: [ 09:23:20 ] :: [ FAIL ] :: Command 'stap -P -vp4 readpages.stp' (Expected 0, got 1) -:: [ 09:23:20 ] :: [ BEGIN ] :: Running 'stap -P -vp4 tcp.sendmsg.stp' -Pass 1: parsed user script and 484 library scripts using 122428virt/95044res/15536shr/79120data kb, in 180usr/130sys/316real ms. -Pass 2: analyzed script: 5 probes, 2 functions, 4 embeds, 3 globals using 202292virt/178300res/19224shr/158984data kb, in 1720usr/1750sys/3531real ms. -Pass 3: translated to C into "/tmp/stapzXlpka/stap_c98d0598383a49c9b0a715336e876a54_18911_src.c" using 202308virt/178492res/19416shr/159000data kb, in 160usr/720sys/899real ms. -In file included from /usr/share/systemtap/runtime/linux/../regs.c:16, - from /usr/share/systemtap/runtime/linux/runtime.h:270, - from /usr/share/systemtap/runtime/runtime.h:26, - from /tmp/stapzXlpka/stap_c98d0598383a49c9b0a715336e876a54_18911_src.c:21: -/tmp/stapzXlpka/stap_c98d0598383a49c9b0a715336e876a54_18911_src.c: In function ‘enter_kretprobe_common’: -/tmp/stapzXlpka/stap_c98d0598383a49c9b0a715336e876a54_18911_src.c:2190:45: error: ‘struct kretprobe_instance’ has no member named ‘ret_addr’ - 2190 | SET_REG_IP(regs, (unsigned long)inst->ret_addr); - | ^~ -/usr/share/systemtap/runtime/linux/../regs.h:85:44: note: in definition of macro ‘SET_REG_IP’ - 85 | #define SET_REG_IP(regs, x) REG_IP(regs) = x - | ^ -make[1]: *** [scripts/Makefile.build:288: /tmp/stapzXlpka/stap_c98d0598383a49c9b0a715336e876a54_18911_src.o] Error 1 -make: *** [Makefile:1844: /tmp/stapzXlpka] Error 2 -WARNING: kbuild exited with status: 2 -Pass 4: compiled C into "stap_c98d0598383a49c9b0a715336e876a54_18911.ko" in 1250usr/1900sys/2762real ms. -Pass 4: compilation failed. [man error::pass4] -:: [ 09:23:28 ] :: [ FAIL ] :: Command 'stap -P -vp4 tcp.sendmsg.stp' (Expected 0, got 1) -:: [ 09:23:28 ] :: [ BEGIN ] :: Running 'stap -P -vp4 bdflush.stp' -Pass 1: parsed user script and 484 library scripts using 122428virt/94968res/15468shr/79120data kb, in 180usr/130sys/317real ms. -Pass 2: analyzed script: 3 probes, 5 functions, 98 embeds, 4 globals using 198116virt/174376res/18956shr/154808data kb, in 1930usr/2660sys/4689real ms. -/root/.systemtap/cache/87/stap_8728db2fdfe761c96d8963fd0c4fffd2_71969.ko -Pass 3: using cached /root/.systemtap/cache/87/stap_8728db2fdfe761c96d8963fd0c4fffd2_71969.c -Pass 4: using cached /root/.systemtap/cache/87/stap_8728db2fdfe761c96d8963fd0c4fffd2_71969.ko -:: [ 09:23:33 ] :: [ PASS ] :: Command 'stap -P -vp4 bdflush.stp' (Expected 0, got 0) - diff --git a/tests/Regression/bz544960-no-cfa_ops-supplied/bdflush.stp b/tests/Regression/bz544960-no-cfa_ops-supplied/bdflush.stp deleted file mode 100644 index e38c685..0000000 --- a/tests/Regression/bz544960-no-cfa_ops-supplied/bdflush.stp +++ /dev/null @@ -1,8 +0,0 @@ -probe syscall.bdflush { - printf("%s\n", name) - printf("%s\n", argstr) -} - -probe syscall.bdflush.return { - printf("%s\n", name) -} diff --git a/tests/Regression/bz544960-no-cfa_ops-supplied/main.fmf b/tests/Regression/bz544960-no-cfa_ops-supplied/main.fmf deleted file mode 100644 index bab475f..0000000 --- a/tests/Regression/bz544960-no-cfa_ops-supplied/main.fmf +++ /dev/null @@ -1,14 +0,0 @@ -summary: bz544960-no-cfa_ops-supplied -description: '' -contact: Martin Hatina -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap -duration: 30m -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=544960 -extra-summary: /tools/systemtap/Regression/bz544960-no-cfa_ops-supplied -extra-task: /tools/systemtap/Regression/bz544960-no-cfa_ops-supplied diff --git a/tests/Regression/bz544960-no-cfa_ops-supplied/readpages.stp b/tests/Regression/bz544960-no-cfa_ops-supplied/readpages.stp deleted file mode 100644 index 9410376..0000000 --- a/tests/Regression/bz544960-no-cfa_ops-supplied/readpages.stp +++ /dev/null @@ -1,21 +0,0 @@ -probe nfs.aop.readpages !, nfs.aop.readpage ? { - log(name); - printf("dev=%d\n", dev); - printf("ino=%d\n", ino); - printf("nr_pages=%d\n", nr_pages); - printf("file=%d\n", file); - printf("rpages=%d\n", rpages); - printf("rsize=%d\n", rsize); - printf("argstr=%s\n", argstr); - printf("size=%d\n", size); - printf("units=%s\n", units); -} - -probe nfs.aop.readpages.return !, nfs.aop.readpage.return ? { - log(name); - printf("retstr=%s\n", retstr); - printf("size=%d\n", size); - printf("units=%s\n", units); -} - -probe oneshot { log("hey!") } diff --git a/tests/Regression/bz544960-no-cfa_ops-supplied/runtest.sh b/tests/Regression/bz544960-no-cfa_ops-supplied/runtest.sh deleted file mode 100755 index 9b31b30..0000000 --- a/tests/Regression/bz544960-no-cfa_ops-supplied/runtest.sh +++ /dev/null @@ -1,49 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/bz544960-no-cfa_ops-supplied -# Description: What the test does -# Author: Martin Hatina -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2013 Red Hat, Inc. All rights reserved. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - - -PACKAGE="systemtap" -_SCRIPTS="readpages.stp tcp.sendmsg.stp bdflush.stp" - -rlJournalStart - rlPhaseStartTest - rlLogInfo "Checking whether we might want to try prologue search." - p="" - for s in $_SCRIPTS; do - stap -vp4 $s >& /dev/null || p="-P" - done - - for s in $_SCRIPTS; do - rlRun "stap $p -vp4 $s" - done - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/bz544960-no-cfa_ops-supplied/tcp.sendmsg.stp b/tests/Regression/bz544960-no-cfa_ops-supplied/tcp.sendmsg.stp deleted file mode 100644 index 1cb95b3..0000000 --- a/tests/Regression/bz544960-no-cfa_ops-supplied/tcp.sendmsg.stp +++ /dev/null @@ -1,7 +0,0 @@ -probe tcp.sendmsg { - printf("%d\n", size) -} - -probe tcp.sendmsg.return { - printf("%d\n", size) -} diff --git a/tests/Regression/bz706185-various-build-and-run/main.fmf b/tests/Regression/bz706185-various-build-and-run/main.fmf deleted file mode 100644 index 44fc465..0000000 --- a/tests/Regression/bz706185-various-build-and-run/main.fmf +++ /dev/null @@ -1,15 +0,0 @@ -summary: bz706185-various-build-and-run -description: bz706185-various-build-and-run -contact: Petr Muller -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap -duration: 20m -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=706185 -extra-summary: /tools/systemtap/Regression/bz706185-various-build-and-run -extra-task: /tools/systemtap/Regression/bz706185-various-build-and-run -tag: fedora diff --git a/tests/Regression/bz706185-various-build-and-run/runtest.sh b/tests/Regression/bz706185-various-build-and-run/runtest.sh deleted file mode 100755 index 447c049..0000000 --- a/tests/Regression/bz706185-various-build-and-run/runtest.sh +++ /dev/null @@ -1,87 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/bz706185-various-build-and-run -# Description: Test containing several build and run testcases. -# Author: Petr Muller -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2011 Red Hat, Inc. All rights reserved. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh - -PACKAGE="systemtap" - -rlJournalStart -rlPhaseStartSetup - rlRun "rpm -qf $(which stap)" - rlRun "uname -r" -rlPhaseEnd - -rlPhaseStartTest "Build testcases" - export STAPOUT=`mktemp` - export TRACOUT=`mktemp` - for testcase in *.stp - do - rlLog "Testcase: $testcase" - rlRun "stap -v -p4 $testcase -m testcase --poison-cache &>$STAPOUT" 0 "Building testcase: $testcase" - if [ $? -ne 0 ] - then - rlLog "=== systemtap output start" - while read line - do - rlLog "$line" - done < $STAPOUT - rlLog "=== systemtap output end" - fi - rm -f testcase.ko - rm -f $STAPOUT - done -rlPhaseEnd - -rlPhaseStartTest "Run testcases" - for testcase in *.run - do - rlLog "Testcase: $testcase" - COMMAND="`cat $testcase`" - COMMAND="$COMMAND -o $TRACOUT $testcase --poison-cache &>$STAPOUT" - rlLog "Assembled command: [$COMMAND]" - rlRun "$COMMAND" 0 "Running testcase: $testcase" - if [ $? -ne 0 ] - then - rlLog "=== systemtap output start" - while read line; do rlLog "$line"; done < $STAPOUT - rlLog "=== systemtap output end" - rlLog "" - rlLog "=== tracing output start" - while read line; do rlLog "$line"; done < $TRACOUT - rlLog "=== tracing output end" - fi - rm -f $STAPOUT $TRACOUT - done -rlPhaseEnd - -rlPhaseStartCleanup - rlRun "rm -f $STAPOUT $TRACOUT" -rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/bz706185-various-build-and-run/softirq.run b/tests/Regression/bz706185-various-build-and-run/softirq.run deleted file mode 100644 index e609cd5..0000000 --- a/tests/Regression/bz706185-various-build-and-run/softirq.run +++ /dev/null @@ -1 +0,0 @@ -stap -v softirq.stp diff --git a/tests/Regression/bz706185-various-build-and-run/softirq.stp b/tests/Regression/bz706185-various-build-and-run/softirq.stp deleted file mode 100644 index 347b840..0000000 --- a/tests/Regression/bz706185-various-build-and-run/softirq.stp +++ /dev/null @@ -1,3 +0,0 @@ -probe softirq.entry { println(">>> softirq") } -probe softirq.exit { println("<<< softirq")} -probe timer.ms(5000) { exit() } diff --git a/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/main.fmf b/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/main.fmf deleted file mode 100644 index 5354545..0000000 --- a/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/main.fmf +++ /dev/null @@ -1,16 +0,0 @@ -summary: dtrace-create-Wall-Wextra-pedantic-clean-code -description: dtrace-create-Wall-Wextra-pedantic-clean-code -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap - - systemtap-sdt-devel -duration: 5m -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=902739 -extra-summary: /tools/systemtap/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code -extra-task: /tools/systemtap/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code -tag: fedora diff --git a/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/runtest.sh b/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/runtest.sh deleted file mode 100755 index d76f4c5..0000000 --- a/tests/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code/runtest.sh +++ /dev/null @@ -1,57 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/dtrace-create-Wall-Wextra-pedantic-clean-code -# Description: dtrace-create-Wall-Wextra-pedantic-clean-code -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2013 Red Hat, Inc. All rights reserved. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -rlJournalStart - rlPhaseStartSetup - rlRun "TMPDIR=$(mktemp -d)" - rlRun "pushd $TMPDIR" - rlPhaseEnd - - rlPhaseStart WARN "Info" - rlRun "which dtrace" - rlPhaseEnd - - rlPhaseStartTest - rlRun "printf \"provider xxx { probe xxx(); };\n\" > xxx" - rlRun "dtrace -G -k -s xxx &> dtrace.out" - rlRun "cat dtrace.out" - rlRun "CF=$( awk '/^source:/ {print $2}' dtrace.out )" - rlRun "gcc -c -Wall -Wextra -pedantic $CF 2>&1 | tee gcc.out" - rlRun "grep -i warning gcc.out" 1 - rlRun "grep -i error gcc.out" 1 - rlPhaseEnd - - rlPhaseStartCleanup - rlRun "popd" - rlRun "rm -r $TMPDIR" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/elfutils-debuginfod-client-not-being-called/dotest.sh b/tests/Regression/elfutils-debuginfod-client-not-being-called/dotest.sh deleted file mode 100644 index a1d48fb..0000000 --- a/tests/Regression/elfutils-debuginfod-client-not-being-called/dotest.sh +++ /dev/null @@ -1,28 +0,0 @@ -#!/bin/bash - -set -xe - -rm -rf ~/.cache/debuginfod_client ~/.systemtap ||: - -debuginfod -p 8008 -d $(mktemp) -vvvvv >& debuginfod.log & -PID=$! - -sleep 5 - -export SYSTEMTAP_DEBUGINFO_PATH=/tmp -export DEBUGINFOD_URLS="http://127.0.0.1:8008" - -# The following doesn't work on aarch64 and s390x because of: -# https://sourceware.org/bugzilla/show_bug.cgi?id=25498 -# stap -p2 -e 'probe kernel.function("vfs_read") {println(pp())}' ||: - -stap -p2 -e 'probe process("/bin/true").function("main") {println(pp())}' -c /bin/true ||: - -sleep 5 - -kill -9 $PID - -grep 'started http server on' debuginfod.log -grep 'searching for buildid=[a-z0-9]* artifacttype=debuginfo' debuginfod.log - - diff --git a/tests/Regression/elfutils-debuginfod-client-not-being-called/main.fmf b/tests/Regression/elfutils-debuginfod-client-not-being-called/main.fmf deleted file mode 100644 index 0b9f61b..0000000 --- a/tests/Regression/elfutils-debuginfod-client-not-being-called/main.fmf +++ /dev/null @@ -1,15 +0,0 @@ -summary: elfutils-debuginfod-client-not-being-called -description: '' -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - elfutils-debuginfod -duration: 48h -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1778921 -extra-summary: /tools/systemtap/Regression/elfutils-debuginfod-client-not-being-called -extra-task: /tools/systemtap/Regression/elfutils-debuginfod-client-not-being-called -tag: fedora diff --git a/tests/Regression/elfutils-debuginfod-client-not-being-called/runtest.sh b/tests/Regression/elfutils-debuginfod-client-not-being-called/runtest.sh deleted file mode 100755 index 79d9197..0000000 --- a/tests/Regression/elfutils-debuginfod-client-not-being-called/runtest.sh +++ /dev/null @@ -1,52 +0,0 @@ -#!/bin/bash -# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/elfutils-debuginfod-client-not-being-called -# Description: elfutils-debuginfod-client-not-being-called -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2020 Red Hat, Inc. -# -# This program is free software: you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 2 of -# the License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see http://www.gnu.org/licenses/. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -PACKAGE="systemtap" - -rlJournalStart - rlPhaseStartSetup - rlAssertRpm $PACKAGE - rlRun "TMP=$(mktemp -d)" - rlRun "cp dotest.sh $TMP/" - rlRun "pushd $TMP" - rlPhaseEnd - - rlPhaseStartTest - rlRun "bash dotest.sh" || - rlRun "cat debuginfod.log" - rlFileSubmit debuginfod.log - rlPhaseEnd - - rlPhaseStartCleanup - rlRun "popd" - rlRun "rm -r $TMP" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/hellotrace.stp b/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/hellotrace.stp deleted file mode 100644 index e390200..0000000 --- a/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/hellotrace.stp +++ /dev/null @@ -1,8 +0,0 @@ -probe begin -{ - printf ( "hello trace : printf\n") - printk (20,"hello trace : printk") - ftrace ( "hello trace : ftrace\n") - exit () -} - diff --git a/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/main.fmf b/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/main.fmf deleted file mode 100644 index 370611b..0000000 --- a/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/main.fmf +++ /dev/null @@ -1,15 +0,0 @@ -summary: ftrace-logging-tapset-not-working-as-expected-in -description: ftrace-logging-tapset-not-working-as-expected-in -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap -duration: 48h -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1810216 -extra-summary: /tools/systemtap/Regression/ftrace-logging-tapset-not-working-as-expected-in -extra-task: /tools/systemtap/Regression/ftrace-logging-tapset-not-working-as-expected-in -tag: fedora diff --git a/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/runtest.sh b/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/runtest.sh deleted file mode 100755 index dc4c2a2..0000000 --- a/tests/Regression/ftrace-logging-tapset-not-working-as-expected-in/runtest.sh +++ /dev/null @@ -1,47 +0,0 @@ -#!/bin/bash -# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/ftrace-logging-tapset-not-working-as-expected-in -# Description: ftrace-logging-tapset-not-working-as-expected-in -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2020 Red Hat, Inc. -# -# This program is free software: you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 2 of -# the License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see http://www.gnu.org/licenses/. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -PACKAGE="systemtap" - -LOG1=$(mktemp) -LOG2=$(mktemp) - -rlJournalStart - rlPhaseStartTest - rlRun "mount | grep -F -i -e 'debugfs on' -e 'on /sys/kernel/debug type debugfs'" - rlRun "cat /sys/kernel/debug/tracing/tracing_on | grep '^1$'" - rlRun "journalctl > $LOG1" - rlRun "stap -g -k -v hellotrace.stp" - rlRun "journalctl > $LOG2" - rlRun "diff $LOG1 $LOG2 | grep '^>.*hello trace : printk'" - rlRun "rm $LOG1 $LOG2" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/ipv6-tapset-support/main.fmf b/tests/Regression/ipv6-tapset-support/main.fmf deleted file mode 100644 index 8104026..0000000 --- a/tests/Regression/ipv6-tapset-support/main.fmf +++ /dev/null @@ -1,17 +0,0 @@ -summary: Test for BZ#822503 (ipv6 tapset support) -description: ipv6 tapset support -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap - - nfs-utils - - setup -duration: 50m -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=822503 -extra-summary: /tools/systemtap/Regression/ipv6-tapset-support -extra-task: /tools/systemtap/Regression/ipv6-tapset-support -tag: fedora diff --git a/tests/Regression/ipv6-tapset-support/nfsd.proc.lookup.stp b/tests/Regression/ipv6-tapset-support/nfsd.proc.lookup.stp deleted file mode 100755 index 86db264..0000000 --- a/tests/Regression/ipv6-tapset-support/nfsd.proc.lookup.stp +++ /dev/null @@ -1,12 +0,0 @@ -#!/usr/bin/stap - -# http://sourceware.org/systemtap/examples/network/nfsdtop.stp - -probe nfsd.proc.lookup { - printf("%s %s\n", client_ip, filename); -} - -probe timer.ms(100000) { - exit (); -} - diff --git a/tests/Regression/ipv6-tapset-support/runtest.sh b/tests/Regression/ipv6-tapset-support/runtest.sh deleted file mode 100755 index a05d136..0000000 --- a/tests/Regression/ipv6-tapset-support/runtest.sh +++ /dev/null @@ -1,79 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/ipv6-tapset-support -# Description: Test for BZ#822503 (ipv6 tapset support) -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2013 Red Hat, Inc. All rights reserved. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 -. /etc/os-release || exit 1 - -rlJournalStart - rlPhaseStartSetup - rlLogInfo "Related bugs: Fedora rawhide 6.2.0-0.rc8.57.fc39.x86_64 bz2177192" - rlAssertRpm nfs-utils - rlRun "uname -r" - rlRun "which stap" - - rlRun "TMPD=$(mktemp -d --tmpdir=$HOME tmp.XXXXXXX)" - rlRun "mkdir $TMPD/{A,B}" - rlRun "chmod --recursive 0777 $TMPD" - rlRun "STAPLOG=$(mktemp)" - - rlServiceStart rpcbind - sleep 5 - NFS_SERVICE=nfs - rlIsRHEL '>=8' && NFS_SERVICE=nfs-server - [ $ID == 'fedora' ] && test $VERSION_ID -ge 38 && NFS_SERVICE=nfs-server - rlServiceStart $NFS_SERVICE - sleep 10 - rlRun "exportfs -ua" - rlRun "exportfs -i -o 'rw,no_root_squash' *:$TMPD/A" - rlPhaseEnd - - rlPhaseStartTest - # ======= work around bz1605574 - rlLogInfo "Let's check if we can compile the module." - rlLogInfo "In case we can't, we'll go ahead with prologue searching." - set -x - EXTRA_SWITCHES='' - stap -p4 nfsd.proc.lookup.stp || EXTRA_SWITCHES="-P" - set +x - # ============================= - - # mount is sufficient to invoke nfsd.proc.lookup - rlRun "stap $EXTRA_SWITCHES -v -c 'mount -t nfs -v [::1]:$TMPD/A $TMPD/B' nfsd.proc.lookup.stp |& tee $STAPLOG" - rlRun "umount $TMPD/B" - rlRun "grep 'Unsupported Address Family' $STAPLOG" 1 - rlRun "grep -E '^\[0000:0000:0000:0000:0000:0000:0000:0001\]:[0-9]+.*$(basename $TMPD)' $STAPLOG" - rlPhaseEnd - - rlPhaseStartCleanup - rlServiceRestore $NFS_SERVICE - rlServiceRestore rpcbind - rlRun "rm -rf $TMPD $STAPLOG" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/irq-vector-tracepoints/main.fmf b/tests/Regression/irq-vector-tracepoints/main.fmf deleted file mode 100644 index 1093c2c..0000000 --- a/tests/Regression/irq-vector-tracepoints/main.fmf +++ /dev/null @@ -1,16 +0,0 @@ -summary: irq-vector-tracepoints -description: irq-vector-tracepoints -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap-devel - - kernel-debuginfo -duration: 15m -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1020437 -extra-summary: /tools/systemtap/Regression/irq-vector-tracepoints -extra-task: /tools/systemtap/Regression/irq-vector-tracepoints -tag: fedora diff --git a/tests/Regression/irq-vector-tracepoints/runtest.sh b/tests/Regression/irq-vector-tracepoints/runtest.sh deleted file mode 100755 index 6f11faa..0000000 --- a/tests/Regression/irq-vector-tracepoints/runtest.sh +++ /dev/null @@ -1,74 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/irq-vector-tracepoints -# Description: irq-vector-tracepoints -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2013 Red Hat, Inc. All rights reserved. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -rlJournalStart - rlPhaseStartSetup - rlRun "TMPDIR=$(mktemp -d)" - rlRun "pushd $TMPDIR" - rlRun "mount -t debugfs /dev/null /sys/kernel/debug" 0-255 - rlRun "test -d /sys/kernel/debug/tracing/events" - rlPhaseEnd - - rlPhaseStart FAIL "Systemtap sanity check" - rlRun "stap --version" - rlRun "stap -v -e 'probe kernel.function(\"vfs_read\"){ exit() }'" - rlPhaseEnd - - rlPhaseStart FAIL "Create list of all kernel tracepoints known to stap" - rlRun "stap -l 'kernel.trace(\"*\")' > tracepoints" - rlFileSubmit tracepoints - rlPhaseEnd - - rlPhaseStart FAIL "Check irq_vectors" - dir='/sys/kernel/debug/tracing/events/irq_vectors' - if test -d $dir; then - for p in $( find $dir -mindepth 1 -type d | awk -F\/ '{print $NF}' ); do - rlLogInfo "Checking $p" - rlRun "grep -q $p tracepoints" - done - # additional checks - rlRun "stap -vp4 -e 'probe kernel.trace(\"local_timer_entry\") {println(pp())}'" - rlRun "stap -vp4 -e 'probe kernel.trace(\"reschedule_entry\") {println(pp())}'" - else - if arch | grep -E 'x86_64|i[36]86'; then - rlLogError "$dir does not exist" - else - rlLogInfo "$dir does not exist" - fi - fi - rlPhaseEnd - - rlPhaseStartCleanup - rlRun "popd" - rlRun "rm -r $TMPDIR" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/netdev-receive/main.fmf b/tests/Regression/netdev-receive/main.fmf deleted file mode 100644 index a5e9730..0000000 --- a/tests/Regression/netdev-receive/main.fmf +++ /dev/null @@ -1,15 +0,0 @@ -summary: netdev.receive -description: bz1518462 netdev.receive -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap -duration: 15m -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1518462 -extra-summary: /tools/systemtap/Regression/netdev-receive -extra-task: /tools/systemtap/Regression/netdev-receive -tag: fedora diff --git a/tests/Regression/netdev-receive/runtest.sh b/tests/Regression/netdev-receive/runtest.sh deleted file mode 100755 index b294186..0000000 --- a/tests/Regression/netdev-receive/runtest.sh +++ /dev/null @@ -1,42 +0,0 @@ -#!/bin/bash -# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/netdev-receive -# Description: netdev.receive -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2017 Red Hat, Inc. -# -# This program is free software: you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 2 of -# the License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see http://www.gnu.org/licenses/. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -PACKAGE="systemtap" - -rlJournalStart - rlPhaseStartTest - rlRun "TMPFILE=$(mktemp)" - rlRun "stap -o $TMPFILE -ve 'probe netdev.receive{log(\"HIT\") exit()}' -c 'ping -c1 localhost'" - rlRun "cat $TMPFILE" - rlRun "grep HIT $TMPFILE" - rlRun "rm $TMPFILE" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/pass-4-failure-netfilter-examples/main.fmf b/tests/Regression/pass-4-failure-netfilter-examples/main.fmf deleted file mode 100644 index b2fb5f9..0000000 --- a/tests/Regression/pass-4-failure-netfilter-examples/main.fmf +++ /dev/null @@ -1,17 +0,0 @@ -summary: Test for BZ#1055778 (Pass 4 failure on RHEL7 for examples) -description: Test for BZ#1055778 (Pass 4 failure on RHEL7 for examples) -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - valgrind - - systemtap - - systemtap-testsuite -duration: 30m -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1055778 -extra-summary: /tools/systemtap/Regression/pass-4-failure-netfilter-examples -extra-task: /tools/systemtap/Regression/pass-4-failure-netfilter-examples -tag: fedora diff --git a/tests/Regression/pass-4-failure-netfilter-examples/runtest.sh b/tests/Regression/pass-4-failure-netfilter-examples/runtest.sh deleted file mode 100755 index b2d8156..0000000 --- a/tests/Regression/pass-4-failure-netfilter-examples/runtest.sh +++ /dev/null @@ -1,55 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/pass-4-failure-netfilter-examples -# Description: Test for BZ#1055778 (Pass 4 failure on RHEL7 for examples) -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2014 Red Hat, Inc. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -PACKAGE="systemtap" - -rlJournalStart - rlPhaseStartSetup - TESTS=$(mktemp) - rlRun "rpm -qa | grep -F systemtap-testsuite" - rlPhaseEnd - - rpm -qa | grep systemtap-testsuite | xargs rpm -ql \ - | grep -E 'netfilter_drop.stp|netfilter_summary.stp' \ - | while read line; do - rlPhaseStart FAIL "Testing $line" - rlRun "stap -p4 $line -v -g TCP 1" && \ - echo $line >> $TESTS - rlPhaseEnd - done - - rlPhaseStart FAIL "Check what was tested" - rlRun "grep netfilter_drop.stp $TESTS" - rlRun "grep netfilter_summary.stp $TESTS" - rm -f $TESTS - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/python-probing/list.stp b/tests/Regression/python-probing/list.stp deleted file mode 100755 index f68e700..0000000 --- a/tests/Regression/python-probing/list.stp +++ /dev/null @@ -1,22 +0,0 @@ -#!/usr/bin/stap -v -/* - Example usage of the Python systemtap tapset to show a nested view of all - Python function calls (and returns) across the whole system. - - Run this using - stap systemtap-example.stp - to instrument all Python processes on the system, or (for example) using - stap systemtap-example.stp -c COMMAND - to instrument a specific program (implemented in Python) -*/ -probe python.function.entry -{ - if ( filename =~ "random" ) - printf("%s => %s in %s:%d\n", thread_indent(1), funcname, filename, lineno); -} - -probe python.function.return -{ - if ( filename =~ "random" ) - printf("%s <= %s in %s:%d\n", thread_indent(-1), funcname, filename, lineno); -} diff --git a/tests/Regression/python-probing/main.fmf b/tests/Regression/python-probing/main.fmf deleted file mode 100644 index c4afdea..0000000 --- a/tests/Regression/python-probing/main.fmf +++ /dev/null @@ -1,30 +0,0 @@ -summary: Systemtap static probes test -description: Systemtap static probes test -contact: Petr Splichal -component: - - python - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - python - - python-debuginfo - - python3-debuginfo - - python3.9-debuginfo - - systemtap - - python2 - - python3 - - elfutils - - yum-utils -adjust: - - environment: - PYTHON: python3 - when: distro is defined and distro == rhel-9 - because: "Test with python (i.e. python3) on rhel-9" - - enabled: false - when: distro is defined and distro == rhel-10 - because: "Test not relevant for rhel10" -duration: 15m -extra-summary: /CoreOS/python/Sanity/systemtap -extra-task: /CoreOS/python/Sanity/systemtap -tag: fedora diff --git a/tests/Regression/python-probing/runtest.sh b/tests/Regression/python-probing/runtest.sh deleted file mode 100755 index c9cbc40..0000000 --- a/tests/Regression/python-probing/runtest.sh +++ /dev/null @@ -1,88 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /CoreOS/python/Sanity/systemtap -# Description: Systemtap static probes test -# Author: Petr Splichal -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2011 Red Hat, Inc. All rights reserved. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -. /usr/share/beakerlib/beakerlib.sh || exit 1 -. /etc/os-release || exit 1 - -# Packages to be tested -PACKAGES="${PACKAGES:-python2}" -# Other required packages -REQUIRES=${REQUIRES:-} -# Binary name parametrized -PYTHON="${PYTHON:-python2}" - -rlJournalStart - rlPhaseStartSetup - # rlAssertRpm --all - rlAssertRpm "systemtap" - rlLogInfo "Running on kernel: $(uname -r)" - rlRun "rpm -qa 'systemtap*'" 0 "Checking systemtap packages" - rlRun "TmpDir=\`mktemp -d\`" 0 "Creating tmp directory" - rlRun "cp list.stp top.stp test.py $TmpDir" 0 "Copying scripts" - rlRun "pushd $TmpDir" - - # Install needed debuginfo, best effort - rlLogInfo "DEBUGINFOD_URLS=$DEBUGINFOD_URLS" - rlLogInfo "DEBUGINFOD_TIMEOUT=$DEBUGINFOD_TIMEOUT" - rlRun "L=$(stap -p2 -e 'probe python.function.entry {exit()}' | awk -F\" '/process/ {print $2}')" 0-255 - rlRun "debuginfo-install -y $L /usr/bin/python\*" 0-255 - rlPhaseEnd - - rlPhaseStartTest "Verifying ELF file for presence of .probes section" - for lib in /usr/lib*/libpython*.so.* ; do - rlRun "eu-readelf -x .probes $lib" \ - 0 "Checking for .probes section within $lib" - done - rlPhaseEnd - - # Note that typically you need to be root to run "stap" (or be within - # an appropriate group) - for script in list top; do - # bz2152970 is a known probem - [ "$ID" == "fedora" ] && [ "$script" == "top" ] && continue - rlPhaseStartTest "Test $script" - rlRun "rm -rf ~/.systemtap/cache" 0 "Cleaning cache" - rlRun "stap $script.stp -v -c \"$PYTHON test.py\" > $script" \ - 0 "Testing with $script.stp" - rlRun "tail -100 $script | col -b" 0 "Inspecting output" - # Checking for random in the list output (python3) - # stap -L 'process("/usr/lib*/libpython*.so*").mark("*")' - # no markers with python3. PViktori mentions that python3 - # is going to use JIT, and that will probably drop the - # markers entirely. - rlRun "grep '/usr/lib.*python.*random.py' '$script'" \ - 0 "Checking for random in the $script output" - rlPhaseEnd - done - - rlPhaseStartCleanup - rlRun "popd" - rlRun "rm -r $TmpDir" 0 "Removing tmp directory" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/python-probing/test.py b/tests/Regression/python-probing/test.py deleted file mode 100755 index 65cc0b7..0000000 --- a/tests/Regression/python-probing/test.py +++ /dev/null @@ -1,3 +0,0 @@ -import random, time -print(random.random()) -time.sleep(3) diff --git a/tests/Regression/python-probing/top.stp b/tests/Regression/python-probing/top.stp deleted file mode 100755 index f32fbf9..0000000 --- a/tests/Regression/python-probing/top.stp +++ /dev/null @@ -1,19 +0,0 @@ -#!/usr/bin/stap -v - -global fn_calls; - -probe python.function.entry -{ - fn_calls[pid(), filename, funcname, lineno] += 1; -} - -probe timer.ms(1000) { - foreach ([pid, filename, funcname, lineno] in fn_calls- limit 1000) { - if (filename =~ "random") - printf("%6d %80s %6d %30s %6d\n", - pid, filename, lineno, funcname, - fn_calls[pid, filename, funcname, lineno]); - } - - delete fn_calls; -} diff --git a/tests/Regression/second-command-not-captured/main.fmf b/tests/Regression/second-command-not-captured/main.fmf deleted file mode 100644 index 6ade74e..0000000 --- a/tests/Regression/second-command-not-captured/main.fmf +++ /dev/null @@ -1,17 +0,0 @@ -summary: second-command-not-captured -description: second-command-not-captured -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap - - ruby - - ruby-libs -duration: 48h -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1857749 -extra-summary: /tools/systemtap/Regression/second-command-not-captured -extra-task: /tools/systemtap/Regression/second-command-not-captured -tag: fedora diff --git a/tests/Regression/second-command-not-captured/ruby-exercise.stp b/tests/Regression/second-command-not-captured/ruby-exercise.stp deleted file mode 100644 index 8c5f42b..0000000 --- a/tests/Regression/second-command-not-captured/ruby-exercise.stp +++ /dev/null @@ -1,9 +0,0 @@ -probe ruby.method.entry, ruby.cmethod.entry { - if((classname =~ "Array") && (methodname =~ "push")) - printf("%d -> %s::%s %s:%d\n", tid(), classname, methodname, file, line); -} - -probe ruby.method.return, ruby.cmethod.return { - if((classname =~ "Array") && (methodname =~ "push")) - printf("%d <- %s::%s %s:%d\n", tid(), classname, methodname, file, line); -} diff --git a/tests/Regression/second-command-not-captured/runtest.sh b/tests/Regression/second-command-not-captured/runtest.sh deleted file mode 100755 index 6be076b..0000000 --- a/tests/Regression/second-command-not-captured/runtest.sh +++ /dev/null @@ -1,57 +0,0 @@ -#!/bin/bash -# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/second-command-not-captured -# Description: second-command-not-captured -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2020 Red Hat, Inc. -# -# This program is free software: you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 2 of -# the License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see http://www.gnu.org/licenses/. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -PACKAGE="systemtap" - -STP_OVERLOAD_THRESHOLD='' -arch | grep -F ppc64le && STP_OVERLOAD_THRESHOLD='-DSTP_OVERLOAD_THRESHOLD=1000000000LL' - -rlJournalStart - rlPhaseStart "WARN" "Attempt to hack around possible ruby tapset problem" - rlRun "rpm -q ruby-libs" - if rpm -V ruby-libs; then - rlLogInfo "Skipping the hack attempt" - else - rlRun "dnf update ruby\* -y" - rlRun "dnf -y reinstall ruby-libs" - rlRun "rpm -q ruby-libs" - rlRun "rpm -V ruby-libs" - fi - rlPhaseEnd - - rlPhaseStartTest - rlLog "`which stap`" - rlLog "`stap -V`" - rlRun "stap $STP_OVERLOAD_THRESHOLD -v ./ruby-exercise.stp -c ./test.sh -o stap.log" - rlRun "grep 'Array::push' stap.log" || - rlFileSubmit "stap.log" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/second-command-not-captured/test.sh b/tests/Regression/second-command-not-captured/test.sh deleted file mode 100755 index d308ba2..0000000 --- a/tests/Regression/second-command-not-captured/test.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/bash - -set -e - -ruby -e 'puts "ABC"' -ruby -e '[1, 2, 3].push(4)' -sleep 10 diff --git a/tests/Regression/semantic-error-nfs-proc-read_setup/main.fmf b/tests/Regression/semantic-error-nfs-proc-read_setup/main.fmf deleted file mode 100644 index 0ea2cab..0000000 --- a/tests/Regression/semantic-error-nfs-proc-read_setup/main.fmf +++ /dev/null @@ -1,15 +0,0 @@ -summary: semantic-error-nfs-proc-read_setup -description: semantic-error-nfs-proc-read_setup -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap -duration: 5m -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=884951 -extra-summary: /tools/systemtap/Regression/semantic-error-nfs-proc-read_setup -extra-task: /tools/systemtap/Regression/semantic-error-nfs-proc-read_setup -tag: fedora diff --git a/tests/Regression/semantic-error-nfs-proc-read_setup/nfs.proc.read_setup.stp b/tests/Regression/semantic-error-nfs-proc-read_setup/nfs.proc.read_setup.stp deleted file mode 100644 index c6974c7..0000000 --- a/tests/Regression/semantic-error-nfs-proc-read_setup/nfs.proc.read_setup.stp +++ /dev/null @@ -1,5 +0,0 @@ -probe nfs.proc.read_setup{ - println("nfs.proc.read_setup server_ip: ", server_ip); - println("nfs.proc.read_setup prot: ", prot); -} - diff --git a/tests/Regression/semantic-error-nfs-proc-read_setup/runtest.sh b/tests/Regression/semantic-error-nfs-proc-read_setup/runtest.sh deleted file mode 100755 index d14e39b..0000000 --- a/tests/Regression/semantic-error-nfs-proc-read_setup/runtest.sh +++ /dev/null @@ -1,45 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/semantic-error-nfs-proc-read_setup -# Description: semantic-error-nfs-proc-read_setup -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2013 Red Hat, Inc. All rights reserved. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -rlJournalStart - rlPhaseStartSetup - rlRun "uname -r" - rlRun "rpm -qa | grep ^kernel | sort" - rlRun "rpm -qa | grep systemtap | sort" - rlRun "which stap" - rlPhaseEnd - - rlPhaseStartTest - rlRun "stap -v -p 2 nfs.proc.read_setup.stp" - rlPhaseEnd - -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/semantic-errors-bz1062076/main.fmf b/tests/Regression/semantic-errors-bz1062076/main.fmf deleted file mode 100644 index e5bcbbf..0000000 --- a/tests/Regression/semantic-errors-bz1062076/main.fmf +++ /dev/null @@ -1,15 +0,0 @@ -summary: semantic-errors-bz1062076 -description: '' -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap -duration: 30m -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1062076 -extra-summary: /tools/systemtap/Regression/semantic-errors-bz1062076 -extra-task: /tools/systemtap/Regression/semantic-errors-bz1062076 -tag: fedora diff --git a/tests/Regression/semantic-errors-bz1062076/runtest.sh b/tests/Regression/semantic-errors-bz1062076/runtest.sh deleted file mode 100755 index bd89675..0000000 --- a/tests/Regression/semantic-errors-bz1062076/runtest.sh +++ /dev/null @@ -1,41 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/semantic-errors-bz1062076 -# Description: semantic-errors-bz1062076 -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2014 Red Hat, Inc. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -rlJournalStart - rlPhaseStartTest - rlLogInfo "Related bugs: Fedora rawhide 6.2.0-0.rc8.57.fc39.x86_64 bz2177196" - rlLogInfo "Check if we might want to try out prologue search" - p="" - stap -vp4 script.stp >& /dev/null || p="-P" - rlRun "stap $p -vp4 script.stp" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/semantic-errors-bz1062076/script.stp b/tests/Regression/semantic-errors-bz1062076/script.stp deleted file mode 100644 index 7527474..0000000 --- a/tests/Regression/semantic-errors-bz1062076/script.stp +++ /dev/null @@ -1,3 +0,0 @@ -probe nfsd.close? { printf("%s\n", filename) } probe never { exit() } -probe sunrpc.clnt.clone_client { print(progname) } -probe scsi.iodone { printf("%d, %d, %d, %d, %d, %d, %d, %d\n", host_no, channel, lun, dev_id, device_state, data_direction, req_addr, scsi_timer_pending ) } diff --git a/tests/Regression/semantic-errors-bz953776/main.fmf b/tests/Regression/semantic-errors-bz953776/main.fmf deleted file mode 100644 index 9dcb8c8..0000000 --- a/tests/Regression/semantic-errors-bz953776/main.fmf +++ /dev/null @@ -1,17 +0,0 @@ -summary: semantic-errors-bz953776 -description: '' -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap - - perf - - gcc -duration: 60m -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=953776 -extra-summary: /tools/systemtap/Regression/semantic-errors-bz953776 -extra-task: /tools/systemtap/Regression/semantic-errors-bz953776 -tag: fedora diff --git a/tests/Regression/semantic-errors-bz953776/runtest.sh b/tests/Regression/semantic-errors-bz953776/runtest.sh deleted file mode 100755 index 7ea0f29..0000000 --- a/tests/Regression/semantic-errors-bz953776/runtest.sh +++ /dev/null @@ -1,169 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/semantic-errors-bz953776 -# Description: semantic-errors-bz953776 -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2014 Red Hat, Inc. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -_rhelmajor=$(rpm --eval '%{rhel}') -_arch=$(arch) - -function perf_probe_failed () -{ - probe=$1 - perf probe -d $probe ||: - perf probe --add $probe - retval=$? - test $retval -eq 0 && \ - rlLogInfo "Running perf probe --add $probe PASSED" || \ - rlLogInfo "Running perf probe --add $probe FAILED" - perf probe -d $probe ||: - if test $retval -eq 0; then - return 1 - else - return 0 - fi -} - -function perf_found_none_of () -{ - ret=0 - for f in "$@"; do - perf_probe_failed $f || ret=1 - done - return $ret -} - -rlJournalStart - # CHECK FOR PERF ---------------------------------------------- - rlPhaseStart FAIL "CHECK FOR PERF" - rlRun "perf --version" - rlPhaseEnd - - rlPhaseStartSetup - rlRun "TMPDIR=$(mktemp -d)" - rlRun "pushd $TMPDIR" - - # prepare sigaltstack for case-5 - cat > sigaltstack.c < -#include -void handler(int sig) -{ - write(2, "stack overflow\n", 15); - _exit(1); -} -unsigned infinite_recursion(unsigned x) { - return infinite_recursion(x)+1; -} -int main() -{ - static char stack[SIGSTKSZ]; - stack_t ss = { - .ss_size = SIGSTKSZ, - .ss_sp = stack, - }; - struct sigaction sa = { - .sa_handler = handler, - .sa_flags = SA_ONSTACK - }; - sigaltstack(&ss, 0); - sigfillset(&sa.sa_mask); - sigaction(SIGSEGV, &sa, 0); - infinite_recursion(0); -} -EOF - rlRun "gcc -o sigaltstack sigaltstack.c" - rlPhaseEnd - - p="" - uname -m | grep -q ^ppc && p="-P" - p="$p -E 'probe timer.s(900){error(\"probe timeout after 15 minutes\")}'" - - export p - - ( - # Work around rhel10 ppc64le specific error::dwarf - test $_rhelmajor -eq 10 && arch | fgrep ppc64le && exit - rlPhaseStart FAIL 'case-1' - rlRun "stap $p -v -e 'probe syscall.close { println(fd); exit(); }'" - rlPhaseEnd - ) - - # After fixing bz1657681, this constraint can be removed - if [[ $(rpm --eval %rhel) -le 7 ]]; then - if arch | grep -vq ppc; then - rlPhaseStart FAIL 'case-2' - # https://bugzilla.redhat.com/show_bug.cgi?id=1657681 - rlRun "stap $p -v -e 'probe socket.close { print(protocol); print(family); print(state); print(flags); print(type); exit() }'" - rlPhaseEnd - fi - fi - - ( - test $_rhelmajor -le 8 && exit - perf_found_none_of "sys_read" "__arm64_sys_read" "do_syscall_64" && exit - test $_rhelmajor -ge 9 && test $_arch = ppc64le -o $_arch = aarch64 && p="$p -p4" # no hits - rlPhaseStart FAIL 'case-3' - rlRun "stap $p -v -e 'probe kernel.function(\"sys_read\").return!, kernel.function(\"__arm64_sys_read\").return!, kernel.function(\"do_syscall_64\").return { println(probefunc()) exit()}'" - rlPhaseEnd - ) - - ( - # Work around rhel10 ppc64le specific error::dwarf - test $_rhelmajor -eq 10 && arch | fgrep ppc64le && exit - rlPhaseStart FAIL 'case-4' - rlRun "stap $p -v -e 'probe syscall.open, syscall.openat { if (\"open\" == execname()) println(argstr); exit() }'" - rlPhaseEnd - ) - - rlPhaseStart FAIL 'case-5' - rlRun "stap $p -ve 'probe syscall.sigaltstack { println(name); exit() }' -c './sigaltstack || true'" - rlPhaseEnd - - # gcc 8.2.1->8.3.1 change related to systemtap debuginfo regression in rhel-8.1.0, kernel -84 -> -85 - # https://bugzilla.redhat.com/show_bug.cgi?id=1709831#c17 - # ( grep -F RESULT: /tmp/typescript | sort -u ) - rlPhaseStart FAIL 'case-6' - rlRun "stap $p -vp4 -e 'probe sunrpc.clnt.shutdown_client { println(servername) }'" - rlPhaseEnd - - rlPhaseStart FAIL 'case-7' - rlRun "stap $p -vp4 -e 'probe sunrpc.clnt.bind_new_program { println(servername) }'" - rlPhaseEnd - - rlPhaseStart FAIL 'case-8' - rlRun "stap $p -vp4 -e 'probe sunrpc.clnt.bind_new_program { println(servername, vers) }'" - rlPhaseEnd - - rlPhaseStartCleanup - rlRun "popd" - rlRun "rm -r $TMPDIR" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/small-tests-wrapper-001/main.fmf b/tests/Regression/small-tests-wrapper-001/main.fmf deleted file mode 100644 index 5046850..0000000 --- a/tests/Regression/small-tests-wrapper-001/main.fmf +++ /dev/null @@ -1,12 +0,0 @@ -summary: Small tests wrapper -component: -- systemtap -test: ./runtest.sh -framework: beakerlib -recommend: -- systemtap -- systemtap-testsuite -- perf -- psmisc -duration: 300m -tag: fedora diff --git a/tests/Regression/small-tests-wrapper-001/runtest.sh b/tests/Regression/small-tests-wrapper-001/runtest.sh deleted file mode 100755 index 9f44eef..0000000 --- a/tests/Regression/small-tests-wrapper-001/runtest.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/bash - -ID=$(pwd | awk -F- '{print $NF}') - -export TESTS=$(printf "%d" $ID) - -../small-tests/runtest.sh - diff --git a/tests/Regression/small-tests-wrapper-002 b/tests/Regression/small-tests-wrapper-002 deleted file mode 120000 index 7d35367..0000000 --- a/tests/Regression/small-tests-wrapper-002 +++ /dev/null @@ -1 +0,0 @@ -small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-003 b/tests/Regression/small-tests-wrapper-003 deleted file mode 120000 index 7d35367..0000000 --- a/tests/Regression/small-tests-wrapper-003 +++ /dev/null @@ -1 +0,0 @@ -small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-004 b/tests/Regression/small-tests-wrapper-004 deleted file mode 120000 index 7d35367..0000000 --- a/tests/Regression/small-tests-wrapper-004 +++ /dev/null @@ -1 +0,0 @@ -small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-005 b/tests/Regression/small-tests-wrapper-005 deleted file mode 120000 index 7d35367..0000000 --- a/tests/Regression/small-tests-wrapper-005 +++ /dev/null @@ -1 +0,0 @@ -small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-006 b/tests/Regression/small-tests-wrapper-006 deleted file mode 120000 index 7d35367..0000000 --- a/tests/Regression/small-tests-wrapper-006 +++ /dev/null @@ -1 +0,0 @@ -small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-007 b/tests/Regression/small-tests-wrapper-007 deleted file mode 120000 index 7d35367..0000000 --- a/tests/Regression/small-tests-wrapper-007 +++ /dev/null @@ -1 +0,0 @@ -small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-008 b/tests/Regression/small-tests-wrapper-008 deleted file mode 120000 index 7d35367..0000000 --- a/tests/Regression/small-tests-wrapper-008 +++ /dev/null @@ -1 +0,0 @@ -small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-009 b/tests/Regression/small-tests-wrapper-009 deleted file mode 120000 index 7d35367..0000000 --- a/tests/Regression/small-tests-wrapper-009 +++ /dev/null @@ -1 +0,0 @@ -small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-010 b/tests/Regression/small-tests-wrapper-010 deleted file mode 120000 index 7d35367..0000000 --- a/tests/Regression/small-tests-wrapper-010 +++ /dev/null @@ -1 +0,0 @@ -small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-011 b/tests/Regression/small-tests-wrapper-011 deleted file mode 120000 index 7d35367..0000000 --- a/tests/Regression/small-tests-wrapper-011 +++ /dev/null @@ -1 +0,0 @@ -small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-012 b/tests/Regression/small-tests-wrapper-012 deleted file mode 120000 index 7d35367..0000000 --- a/tests/Regression/small-tests-wrapper-012 +++ /dev/null @@ -1 +0,0 @@ -small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-013 b/tests/Regression/small-tests-wrapper-013 deleted file mode 120000 index 7d35367..0000000 --- a/tests/Regression/small-tests-wrapper-013 +++ /dev/null @@ -1 +0,0 @@ -small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-014 b/tests/Regression/small-tests-wrapper-014 deleted file mode 120000 index 7d35367..0000000 --- a/tests/Regression/small-tests-wrapper-014 +++ /dev/null @@ -1 +0,0 @@ -small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-015 b/tests/Regression/small-tests-wrapper-015 deleted file mode 120000 index 7d35367..0000000 --- a/tests/Regression/small-tests-wrapper-015 +++ /dev/null @@ -1 +0,0 @@ -small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-016 b/tests/Regression/small-tests-wrapper-016 deleted file mode 120000 index 7d35367..0000000 --- a/tests/Regression/small-tests-wrapper-016 +++ /dev/null @@ -1 +0,0 @@ -small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-017 b/tests/Regression/small-tests-wrapper-017 deleted file mode 120000 index 7d35367..0000000 --- a/tests/Regression/small-tests-wrapper-017 +++ /dev/null @@ -1 +0,0 @@ -small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-018 b/tests/Regression/small-tests-wrapper-018 deleted file mode 120000 index 7d35367..0000000 --- a/tests/Regression/small-tests-wrapper-018 +++ /dev/null @@ -1 +0,0 @@ -small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests-wrapper-019 b/tests/Regression/small-tests-wrapper-019 deleted file mode 120000 index 7d35367..0000000 --- a/tests/Regression/small-tests-wrapper-019 +++ /dev/null @@ -1 +0,0 @@ -small-tests-wrapper-001 \ No newline at end of file diff --git a/tests/Regression/small-tests/main.fmf b/tests/Regression/small-tests/main.fmf deleted file mode 100644 index 43e6b7d..0000000 --- a/tests/Regression/small-tests/main.fmf +++ /dev/null @@ -1,16 +0,0 @@ -summary: Small tests -description: '' -contact: Martin Cermak -component: -- systemtap -test: ./runtest.sh -framework: beakerlib -recommend: -- systemtap -- systemtap-testsuite -- perf -- psmisc -duration: 300m -extra-summary: /tools/systemtap/Regression/small-tests -extra-task: /tools/systemtap/Regression/small-tests -tag: fedora diff --git a/tests/Regression/small-tests/runtest.sh b/tests/Regression/small-tests/runtest.sh deleted file mode 100755 index 60b7658..0000000 --- a/tests/Regression/small-tests/runtest.sh +++ /dev/null @@ -1,310 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/small-tests -# Description: suns small tests -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2014 Red Hat, Inc. -# -# This program is free software: you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 2 of -# the License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see http://www.gnu.org/licenses/. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -# shellcheck disable=SC1091 -. /usr/share/beakerlib/beakerlib.sh || exit 1 -. /etc/os-release ||: - -_rhelmajor=$(rpm --eval '%{rhel}') -_arch=$(arch) - -# Specify which tests to run e.g. "1,3,5-6,8-11" or "ALL" -TESTS="${TESTS:-ALL}" -TESTS="${TESTS//,/\ }" - -function run_test () -{ - [ "$TESTS" == "ALL" ] && return 0 - digits=4 - test_no=$(printf "%0${digits}g\n" "$1") - - for spec in $TESTS; do - case $spec in - [0-9]*-[0-9]*) - n1=$(echo "$spec" | awk -F- '{print $1}') - n2=$(echo "$spec" | awk -F- '{print $2}') - for id in $(seq -f "%0${digits}g" "$n1" "$n2"); do - if [ "$test_no" == "$id" ]; then - return 0 - fi - done - ;; - [0-9]*) - id=$(printf "%0${digits}g\n" "$spec") - if [ "$test_no" == "$id" ]; then - return 0 - fi - ;; - *) - echo "ERROR: TESTS=\"$TESTS\". That is not parseable." - return 1 - esac - done - return 1 -} - - -function perf_probe_failed () -{ - probe=$1 - perf probe -d "$probe" ||: - perf probe --add "$probe" - retval=$? - if test $retval -eq 0; then - rlLogInfo "Running perf probe --add $probe PASSED" - else - rlLogInfo "Running perf probe --add $probe FAILED" - fi - perf probe -d "$probe" ||: - if test $retval -eq 0; then - return 1 - else - return 0 - fi -} - -function perf_found_none_of () -{ - ret=0 - for f in "$@"; do - perf_probe_failed "$f" || ret=1 - done - return $ret -} - -rlJournalStart - # Check the environment --------------------------------------- - rlPhaseStart WARN "Check the environment" - rlRun "rpm -qa | grep -E '^(kernel|systemtap|perf)' | sort" - rlRun "uname -r" - rlRun "perf --version" - rlLogInfo "DEBUGINFOD_URLS=$DEBUGINFOD_URLS" - rlLogInfo "DEBUGINFOD_TIMEOUT=$DEBUGINFOD_TIMEOUT" - rlLogInfo "TESTS=$TESTS" - rlPhaseEnd - - # bz1162939 --------------------------------------------------- - ( - run_test 1 || exit - perf_probe_failed "vfs_read" && exit - rlPhaseStart FAIL "test 1 bz1162939" - rlRun "stap -e 'probe vfs.read{println(\"hit\"); exit()}' -c 'head -1 /etc/hosts' | grep -F hit" - rlPhaseEnd - ) - - # bz1119335 --------------------------------------------------- - ( - run_test 2 || exit - rlPhaseStart FAIL "test 2 bz1119335" - rlRun "man 8 staprun | grep 'STAP_FIPS_OVERRIDE'" - rlPhaseEnd - ) - - # bz1153673 --------------------------------------------------- - ( - run_test 3 || exit - # Work around rhel10 ppc64le specific error::dwarf - test "$_rhelmajor" -eq 10 && arch | grep -F ppc64le && exit - rlPhaseStart FAIL "test 3 bz1153673" - _tested=0 - for _pkg in $( rpm -qa | grep systemtap-testsuite ); do - for _tc in $( rpm -ql "$_pkg" | grep 'alias_suffixes.stp$' ); do - stap -p4 "$_tc" && p="" || p="-P" - rlRun "stap $p -p4 $_tc" - _tested=1 - done - done - [[ $_tested -eq 0 ]] && rlFail "Not tested" - rlPhaseEnd - ) - - # bz1160837 --------------------------------------------------- - ( - run_test 4 || exit - perf_probe_failed "sd_init_command" && exit - rlPhaseStart FAIL "test 4 bz1160837" - _tested=0 - _prologue_search='' - for _pkg in $( rpm -qa | grep systemtap-testsuite ); do - for _tc in $( rpm -ql "$_pkg" | grep 'iostat-scsi.stp$' ); do - test "$_arch" = ppc64le && _prologue_search='-P' - rlRun "stap -g $_prologue_search $_tc 1 -c 'sleep 1'" - _tested=1 - done - done - [[ $_tested -eq 0 ]] && rlFail "Not tested" - rlPhaseEnd - ) - - # bz1203808 --------------------------------------------------- - ( - run_test 5 || exit - rlPhaseStart FAIL "test 5 bz1203808" - _tested=0 - for _pkg in $( rpm -qa | grep systemtap-testsuite ); do - for _tc in $( rpm -ql "$_pkg" | grep 'vfs-all-probes.stp$' ); do - stap -wp4 "$_tc" && p="" || p="-P" - rlRun "stap $p -w -p4 $_tc" - _tested=1 - done - done - [[ $_tested -eq 0 ]] && rlFail "Not tested" - rlPhaseEnd - ) - - # bz1269062 --------------------------------------------------- - ( - run_test 6 || exit - rlPhaseStart FAIL "test 6 bz1269062" - rlRun "stap -c sync --suppress-handler-errors -e 'probe ioscheduler.elv_add_request{println(elevator_name) exit()}'" - rlPhaseEnd - ) - - # bz528792 --------------------------------------------------- - ( - run_test 7 || exit - # Not relevant on rhel-9 because of kernel commit cad6967ac10843a70842cd39c7b53412901dd21f that removes - # _do_fork() and replaces it with new kernel_clone() - perf_found_none_of "_do_fork" "do_fork" "sys_clone" && exit - - rlPhaseStart FAIL "test 7 bz528792" - if test "$_arch" = ppc64le; then - # https://bugzilla.redhat.com/show_bug.cgi?id=1652740#c4 - We can not reach any function parameters, namely $clone_flags - rlRun "stap -ve 'probe kernel.function(\"_do_fork\")!, kernel.function(\"do_fork\")!, kernel.function(\"sys_clone\") { println(pp()) exit() }' -c \"bash -c 'while sleep 1; do /bin/true; done'\"" - else - rlRun "stap -ve 'probe kernel.function(\"_do_fork\")!, kernel.function(\"do_fork\")!, kernel.function(\"sys_clone\") { printf(\"%x\n\",\$clone_flags) exit() }' -c \"bash -c 'while sleep 1; do /bin/true; done'\"" - fi - rlPhaseEnd - ) - - # bz1890702 --------------------------------------------------- - ( - run_test 8 || exit - perf_probe_failed "vfs_open" && exit - rlPhaseStart FAIL "test 8 bz1890702" - rlRun "stap -g --suppress-time-limits -e 'probe kernel.function(\"vfs_open\") { printf(\"%s(path: %s)\", ppfunc(), \$path\$) ; exit() }' -c 'cat /etc/hosts'" - rlPhaseEnd - ) - - # bz1904216 --------------------------------------------------- - ( - run_test 9 || exit - rlPhaseStart FAIL "test 9 bz1904216" - rlRun "stap -p4 -DSTP_NO_OVERLOAD -t -c 'sleep 0.25' -e 'probe kernel.trace(\"bcache:bcache_btree_set_root\") { if (pid() == 0) printf(\"probe hit\n\"); }'" - rlPhaseEnd - ) - - # bz1940804 --------------------------------------------------- - ( - run_test 10 || exit - rlPhaseStart FAIL "test 10 bz1940804" - rlRun "stap -e 'probe process(\"/bin/bash\").function(\"main\") {println(pn()) }' -c '/bin/bash --help'" - rlPhaseEnd - ) - - # bz1940945 --------------------------------------------------- - ( - run_test 11 || exit - rlPhaseStart FAIL "test 11 bz1940945" - rlRun "stap -c sync --suppress-handler-errors -e 'probe ioscheduler.elv_add_request{println(elevator_name) exit()}'" - rlPhaseEnd - ) - - # bz1940761 --------------------------------------------------- - ( - run_test 12 || exit - rlPhaseStart FAIL "test 12 bz1940761" - rlRun "stap -v /usr/share/systemtap/examples/process/strace.stp -w -c \"echo hello world\"" - rlPhaseEnd - ) - - # broken-tapset-print-ubacktrace ------------------------------ - ( - run_test 13 || exit - rlPhaseStart FAIL "test 13 broken-tapset-print-ubacktrace" - rlRun "stap -p4 -e 'probe begin { print_ubacktrace() }'" - rlPhaseEnd - ) - - # Protected from elision -------------------------------------- - ( - run_test 14 || exit - rlPhaseStart FAIL "test 14 protected from elision" - rlRun "stap -v -e 'probe nfs.fop.fsync {} probe begin {print(\"Protected from elision\")}' -c true |\ - grep -F 'Protected from elision'" - rlPhaseEnd - ) - - # bz544207 ---------------------------------------------------- - ( - run_test 15 || exit - rlPhaseStart FAIL "test 15 bz544207" - extra_opts="" - stap -vp4 -e 'probe nfs.proc.write_setup{ println(how) }' || extra_opts="-P" - rlRun "stap $extra_opts -vp4 -e 'probe nfs.proc.write_setup{ println(how) }'" - rlPhaseEnd - ) - - # bz544209 ---------------------------------------------------- - ( - run_test 16 || exit - rlPhaseStart FAIL "test 16 bz544209" - rlRun "stap -vp2 -e 'probe sunrpc.clnt.create_client.return {}'" - rlPhaseEnd - ) - - # bz592830 ---------------------------------------------------- - ( - run_test 17 || exit - rlPhaseStart FAIL "test 17 bz592830" - rlRun "stap -vp2 -e 'probe signal.check_ignored.return {println(1)}'" - rlPhaseEnd - ) - - # caller-does-not-work ---------------------------------------- - ( - run_test 18 || exit - rlPhaseStart FAIL "test 18 caller-does-not-work" - rlRun "stap -ve 'probe kernel.function(\"vfs_read\") \ - { printf(\"%s\n\", caller()); exit() }' 2>&1 | tee strace.log" - rlPhaseEnd - ) - - # missing-rpc-tracepoints ------------------------------------- - ( - run_test 19 || exit - rlPhaseStart FAIL "test 19 missing-rpc-tracepoints" - rlRun "stap -L 'kernel.trace(\"rpc*\")'" - rlPhaseEnd - ) - - rlPhaseStart WARN "Check for stuff we failed to clean up" - rlRun "pstree -p $$" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/stap-ERROR-Build-id-mismatch-with/main.fmf b/tests/Regression/stap-ERROR-Build-id-mismatch-with/main.fmf deleted file mode 100644 index 2a96a6c..0000000 --- a/tests/Regression/stap-ERROR-Build-id-mismatch-with/main.fmf +++ /dev/null @@ -1,15 +0,0 @@ -summary: Test for BZ#1566422 (stap ERROR Build-id mismatch with) -description: '' -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap -duration: 48h -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1566422 -extra-summary: /tools/systemtap/Regression/stap-ERROR-Build-id-mismatch-with -extra-task: /tools/systemtap/Regression/stap-ERROR-Build-id-mismatch-with -tag: fedora diff --git a/tests/Regression/stap-ERROR-Build-id-mismatch-with/runtest.sh b/tests/Regression/stap-ERROR-Build-id-mismatch-with/runtest.sh deleted file mode 100755 index be97cea..0000000 --- a/tests/Regression/stap-ERROR-Build-id-mismatch-with/runtest.sh +++ /dev/null @@ -1,46 +0,0 @@ -#!/bin/bash -# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/stap-ERROR-Build-id-mismatch-with -# Description: Test for BZ#1566422 (stap ERROR Build-id mismatch with) -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2018 Red Hat, Inc. -# -# This program is free software: you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 2 of -# the License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see http://www.gnu.org/licenses/. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -# shellcheck disable=SC1091 -. /usr/share/beakerlib/beakerlib.sh || exit 1 -. /etc/os-release || exit 1 - -rlJournalStart - rlPhaseStartTest - if arch | grep -q s390x; then - rlLogWarning "Test not relevant" - elif test ${VERSION_ID%.*} -eq 9; then - rlLogInfo "Known problem https://issues.redhat.com/browse/RHEL-50105" - rlLogInfo 'Probing module("igb").function("igb_exit_module") crashes the rhel9 kernel' - else - rlRun "sudo modprobe igb" - rlRun "stap -e 'probe module(\"igb\").function(\"igb_*_module\") { printf(\"%s: %s.\n\", ctime(gettimeofday_s()), ppfunc()); }' -c \"bash -c 'sudo rmmod igb; sudo modprobe igb'\"" - fi - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/stapio-possible-circular-locking-dependency/main.fmf b/tests/Regression/stapio-possible-circular-locking-dependency/main.fmf deleted file mode 100644 index de6de2e..0000000 --- a/tests/Regression/stapio-possible-circular-locking-dependency/main.fmf +++ /dev/null @@ -1,15 +0,0 @@ -summary: Test for BZ#1020207 (stapio possible circular locking dependency) -description: '' -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap -duration: 4h -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1020207 -extra-summary: /tools/systemtap/Regression/stapio-possible-circular-locking-dependency -extra-task: /tools/systemtap/Regression/stapio-possible-circular-locking-dependency -tag: fedora diff --git a/tests/Regression/stapio-possible-circular-locking-dependency/runtest.sh b/tests/Regression/stapio-possible-circular-locking-dependency/runtest.sh deleted file mode 100755 index 856197c..0000000 --- a/tests/Regression/stapio-possible-circular-locking-dependency/runtest.sh +++ /dev/null @@ -1,74 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/stapio-possible-circular-locking-dependency -# Description: Test for BZ#1020207 (stapio possible circular locking dependency) -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2014 Red Hat, Inc. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -rlJournalStart - rlPhaseStartSetup - rlRun "TMPDIR=\$(mktemp -d)" - rlRun "pushd $TMPDIR" - cat > test5.stap < reproduce.sh < /proc/sys/vm/drop_caches - stap test5.stap -c "sleep 2" - if dmesg 2>&1 | grep "possible circular locking dependency detected"; then - dmesg - exit 1 - fi -done -exit 0 -EOF - - rlRun "chmod +x reproduce.sh" - rlPhaseEnd - - rlPhaseStartTest - TO=180 # timeout seconds - # when timeout TO is hit, exitcode 124 is returned - rlRun "timeout $TO ./reproduce.sh" 0,124 - # if issue doesn't get reproduced within TO, the test will pass - rlPhaseEnd - - rlPhaseStartCleanup - rlRun "popd" - rlRun "rm -r $TMPDIR" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/suspicious-RCU-usage/main.fmf b/tests/Regression/suspicious-RCU-usage/main.fmf deleted file mode 100644 index aff4cb7..0000000 --- a/tests/Regression/suspicious-RCU-usage/main.fmf +++ /dev/null @@ -1,15 +0,0 @@ -summary: suspicious-RCU-usage -description: '' -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap -duration: 48h -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1788662 -extra-summary: /tools/systemtap/Regression/suspicious-RCU-usage -extra-task: /tools/systemtap/Regression/suspicious-RCU-usage -tag: fedora diff --git a/tests/Regression/suspicious-RCU-usage/runtest.sh b/tests/Regression/suspicious-RCU-usage/runtest.sh deleted file mode 100755 index 8c8af00..0000000 --- a/tests/Regression/suspicious-RCU-usage/runtest.sh +++ /dev/null @@ -1,49 +0,0 @@ -#!/bin/bash -# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/suspicious-RCU-usage -# Description: suspicious-RCU-usage -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2020 Red Hat, Inc. -# -# This program is free software: you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 2 of -# the License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see http://www.gnu.org/licenses/. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -PACKAGE="systemtap" - -rlJournalStart - rlPhaseStartTest - dmesg1=$(mktemp) - dmesg2=$(mktemp) - diff=$(mktemp) - dmesg > $dmesg1 - rlRun "stap -e 'probe kernel.trace(\"*\"){}' -t -u -v -c '/bin/true'" - sleep 10 - dmesg > $dmesg2 - rlRun "diff $dmesg1 $dmesg2 |& tee $diff" - # Reproduced on hpe-moonshot-02-c02.hpe1.lab.eng.bos.redhat.com - # using kernel-4.18.0-167.el8.aarch64+debug and systemtap-4.2-1.el8.aarch64. - rlRun "grep -F -i rcu $diff" 1 - rm $dmesg{1,2} $diff - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/syscall-get-arguments-returning-wrong-value/main.fmf b/tests/Regression/syscall-get-arguments-returning-wrong-value/main.fmf deleted file mode 100644 index 12e3a31..0000000 --- a/tests/Regression/syscall-get-arguments-returning-wrong-value/main.fmf +++ /dev/null @@ -1,16 +0,0 @@ -summary: Test for BZ#1004059 (syscall_get_arguments() returning wrong value) -description: '' -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap - - perf -duration: 30m -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1004059 -extra-summary: /tools/systemtap/Regression/syscall-get-arguments-returning-wrong-value -extra-task: /tools/systemtap/Regression/syscall-get-arguments-returning-wrong-value -tag: fedora diff --git a/tests/Regression/syscall-get-arguments-returning-wrong-value/runtest.sh b/tests/Regression/syscall-get-arguments-returning-wrong-value/runtest.sh deleted file mode 100755 index 3c81142..0000000 --- a/tests/Regression/syscall-get-arguments-returning-wrong-value/runtest.sh +++ /dev/null @@ -1,79 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/syscall-get-arguments-returning-wrong-value -# Description: Test for BZ#1004059 (syscall_get_arguments() returning wrong value) -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2014 Red Hat, Inc. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -_rhelmajor="0$(rpm --eval '%{rhel}')" - -ASMLINKAGE=''; -uname -m | grep -E 'i[36]86' && \ - ASMLINKAGE='asmlinkage();' - -SCRIPT=$( mktemp ) -cat > $SCRIPT <<-EOF -probe kernel.function("sys_open") { - $ASMLINKAGE - if (\$filename == pointer_arg(1)) { - exit(); - } else { - error("Possible manifestation of rhbz1004059."); - } -} -EOF - -function perf_probe_failed () -{ - probe=$1 - perf probe -d $probe ||: - perf probe --add $probe - retval=$? - test $retval -eq 0 && \ - rlLogInfo "Running perf probe --add $probe PASSED" || \ - rlLogInfo "Running perf probe --add $probe FAILED" - perf probe -d $probe ||: - if test $retval -eq 0; then - return 1 - else - return 0 - fi -} - -rlJournalStart - rlPhaseStartTest - ( - # Work around rhel10 ppc64le specific error::dwarf - test $_rhelmajor -eq 10 && arch | fgrep ppc64le && exit - perf_probe_failed "sys_open" && exit - stap -p4 $SCRIPT >&/dev/null && p="" || p='-P' - rlRun "stap $p -v $SCRIPT -c 'cat /dev/null'" - ) - rm $SCRIPT - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/main.fmf b/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/main.fmf deleted file mode 100644 index 9713fb6..0000000 --- a/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/main.fmf +++ /dev/null @@ -1,15 +0,0 @@ -summary: task-cwd-path-results-in-an-in-kernel-memory-leak -description: '' -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap -duration: 48h -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1412691 -extra-summary: /tools/systemtap/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak -extra-task: /tools/systemtap/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak -tag: fedora diff --git a/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/reproducer.stp b/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/reproducer.stp deleted file mode 100644 index ff15bbb..0000000 --- a/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/reproducer.stp +++ /dev/null @@ -1,10 +0,0 @@ -probe kprocess.exit -{ - path=fullpath_struct_path(task_cwd_path(task_current())) - printf("%s\n", path) -} - -#probe timer.s(240) -#{ -# exit() -#} diff --git a/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/runtest.sh b/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/runtest.sh deleted file mode 100755 index 1a742f2..0000000 --- a/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/runtest.sh +++ /dev/null @@ -1,46 +0,0 @@ -#!/bin/bash -# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak -# Description: task-cwd-path-results-in-an-in-kernel-memory-leak -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2017 Red Hat, Inc. -# -# This program is free software: you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 2 of -# the License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see http://www.gnu.org/licenses/. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -PACKAGE="systemtap" - -rlJournalStart - rlPhaseStartTest - EXTRA="" - arch | grep -F ppc64le && EXTRA='-P' - - # We rely on (and check for) units to be kB - rlRun "test \"$( awk '/KernelStack/ {print $3}' /proc/meminfo )\" == \"kB\"" - rlRun "STACK1=$(awk '/KernelStack/ {print $2}' /proc/meminfo)" - rlRun "stap $EXTRA -w reproducer.stp -c 'bash ./trigger.sh' -o /dev/null" - rlRun "STACK2=$(awk '/KernelStack/ {print $2}' /proc/meminfo)" - rlRun "test $((STACK2 - 1000)) -le $STACK1" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/trigger.sh b/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/trigger.sh deleted file mode 100755 index 165bd9a..0000000 --- a/tests/Regression/task-cwd-path-results-in-an-in-kernel-memory-leak/trigger.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/bash - -for i in `seq 1 2000`; do - ls / > /dev/null -done - - diff --git a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/main.fmf b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/main.fmf deleted file mode 100644 index d3da75c..0000000 --- a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/main.fmf +++ /dev/null @@ -1,15 +0,0 @@ -summary: task-exe-file-results-in-an-file-struct-leak -description: '' -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap -duration: 48h -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1430861 -extra-summary: /tools/systemtap/Regression/task-exe-file-results-in-an-file-struct-leak -extra-task: /tools/systemtap/Regression/task-exe-file-results-in-an-file-struct-leak -tag: fedora diff --git a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/reproducer.stp b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/reproducer.stp deleted file mode 100644 index 2dd39bb..0000000 --- a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/reproducer.stp +++ /dev/null @@ -1,6 +0,0 @@ -probe kprocess.exit -{ - t=task_current() - path=fullpath_struct_file(t, task_exe_file(t)) - printf("%s\n", path) -} diff --git a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/reproducer2.stp b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/reproducer2.stp deleted file mode 100644 index f26764a..0000000 --- a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/reproducer2.stp +++ /dev/null @@ -1,5 +0,0 @@ -probe kprocess.exit -{ - path=fullpath_struct_path(task_cwd_path(task_current())) - printf("%s\n", path) -} diff --git a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/runtest.sh b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/runtest.sh deleted file mode 100755 index 67d8be4..0000000 --- a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/runtest.sh +++ /dev/null @@ -1,45 +0,0 @@ -#!/bin/bash -# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/task-exe-file-results-in-an-file-struct-leak -# Description: task-exe-file-results-in-an-file-struct-leak -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2017 Red Hat, Inc. -# -# This program is free software: you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 2 of -# the License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see http://www.gnu.org/licenses/. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -PACKAGE="systemtap" - -rlJournalStart - rlPhaseStartTest - EXTRA='' - arch | grep -F ppc64le && EXTRA="-P" - rlRun "FILE_NR1=$(awk '{print $1}' /proc/sys/fs/file-nr)" - REPRODUCER=reproducer.stp - rlRun "stap -g -w $EXTRA --dump-functions | grep -F task_exe_file || REPRODUCER=reproducer2.stp" - rlRun "stap -w $EXTRA $REPRODUCER -c 'bash ./trigger.sh' -o /dev/null" - rlRun "FILE_NR2=$(awk '{print $1}' /proc/sys/fs/file-nr)" - rlRun "test $((FILE_NR2 - 1000)) -le $FILE_NR1" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/trigger.sh b/tests/Regression/task-exe-file-results-in-an-file-struct-leak/trigger.sh deleted file mode 100755 index 31ee2bb..0000000 --- a/tests/Regression/task-exe-file-results-in-an-file-struct-leak/trigger.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/bash - -for i in `seq 1 100000`; do - /bin/true -done - - diff --git a/tests/Regression/upstream-testsuite/main.fmf b/tests/Regression/upstream-testsuite/main.fmf deleted file mode 100644 index 1bae9d8..0000000 --- a/tests/Regression/upstream-testsuite/main.fmf +++ /dev/null @@ -1,54 +0,0 @@ -summary: upstream-testsuite -enabled: true -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - libstdc++ - - libstdc++-devel - - libgcc - - glibc-devel - - gcc-c++ - - kernel-devel - - kernel-headers - - git - - curl - - tar - - dejagnu - - elfutils-devel - - gettext - - gettext-devel - - nss-devel - - avahi-devel - - dyninst-devel - - libselinux-devel - - sqlite-devel - - json-c-devel - - ncurses-devel - - crash-devel - - rpm-devel - - emacs - - jpackage-utils - - java-devel - - libvirt-devel - - libxml2-devel - - readline-devel - - python-devel - - python3-devel - - rpm-build - - python-setuptools - - python2-setuptools - - python2-pyparsing - - dyninst-devel - - elfutils-debuginfod-client-devel -duration: 72h -tag: fedora -order: 9999 -# check: -# - how: watchdog -# interval: 2 -# reboot: true -# ping: true -# ping-packets: 1 -# ping-threshold: 3 diff --git a/tests/Regression/upstream-testsuite/my_environment_sanity.exp b/tests/Regression/upstream-testsuite/my_environment_sanity.exp deleted file mode 100644 index 0af241a..0000000 --- a/tests/Regression/upstream-testsuite/my_environment_sanity.exp +++ /dev/null @@ -1,6 +0,0 @@ -set test "my_environment_sanity_test" - -environment_sanity_test -print_system_info - -pass $test diff --git a/tests/Regression/upstream-testsuite/runtest.sh b/tests/Regression/upstream-testsuite/runtest.sh deleted file mode 100755 index 2b7ba6d..0000000 --- a/tests/Regression/upstream-testsuite/runtest.sh +++ /dev/null @@ -1,102 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/testsuite-upstream-raw -# Description: testsuite-upstream-raw -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2014 Red Hat, Inc. -# -# This program is free software: you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 2 of -# the License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see http://www.gnu.org/licenses/. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -SUITERPM=${SUITERPM:-systemtap-testsuite} -SUITELOC=${SUITELOC:-/usr/share/systemtap/testsuite/} -PKGMGR=${PKGMGR:-dnf} -ORIGWD=$(pwd) - -export SUITELOC - -rlJournalStart - rlPhaseStart WARN "Install" - # Try to free disk space by uninstalling unneeded kernel packages - rlRun "rpm -qa | grep ^kernel | grep -v `uname -r` | grep -v headers | xargs rpm -e --nodeps" 0-255 - # https://github.com/teemtee/tmt/issues/2762 - # rlRun "$PKGMGR -y install --setopt=multilib_policy=all libstdc++ libgcc glibc-devel gcc-c++ libstdc++-devel" - rlRun "stap-prep" - rlPhaseEnd - - rlPhaseStartSetup - rlServiceStop firewalld - rlServiceStop iptables - rlServiceStop ip6tables - rlServiceStop kdump - rlServiceStart avahi-daemon - rlRun "sysctl -w kernel.panic=1" - rlRun "sysctl -w kernel.panic_on_oops=1" - rlPhaseEnd - - rlPhaseStart WARN "Info" - rlLogInfo "SUITERPM=${SUITERPM}" - rlLogInfo "SUITELOC=${SUITELOC}" - rlLogInfo "PKGMGR=${PKGMGR}" - rlRun "uname -a" - rlRun "rpm -q $SUITERPM" - rlRun "cat /etc/os-release" - rlRun "stap-report" - rlPhaseEnd - - rlPhaseStart FAIL "sanity check" - rlRun "stap -vve 'probe kernel.function(\"vfs_read\"){ log(\"hey!\"); exit() } probe timer.s(60){log(\"timeout\"); exit()}'" - rlPhaseEnd - - rlPhaseStartTest - rlRun "pushd $SUITELOC" - rlRun "$ORIGWD/trimsuite" - rm -f /tmp/stopwatchdog - $ORIGWD/watchdog.sh & - watchdog_pid=$! - - # Make sure we always have the system identification print_system_info() - # Work around removal of print_system_info() from environment_sanity.exp - rlRun "cp $ORIGWD/my_environment_sanity.exp $SUITELOC/systemtap/" - - # Test primary arch only. The CI test systems have notorious problems - # with repos having i686 and x86_64 packages whose NVRs do not match. - # It's a PITA. Work it around. - rlRun "sed -i '/^proc arch_compile_flags/,/^}/d' $SUITELOC/lib/compile_flags.exp" - rlRun "echo 'proc arch_compile_flags {} { return 1 }' >> $SUITELOC/lib/compile_flags.exp" - - rlRun "make installcheck 2>&1" 0-255 - touch /tmp/stopwatchdog - wait - rlPhaseEnd - - rlPhaseStartCleanup - rlServiceRestore firewalld - rlServiceRestore iptables - rlServiceRestore ip6tables - rlServiceRestore kdump - rlServiceRestore avahi-daemon - rlRun popd - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Regression/upstream-testsuite/trimsuite b/tests/Regression/upstream-testsuite/trimsuite deleted file mode 100755 index a178cc0..0000000 --- a/tests/Regression/upstream-testsuite/trimsuite +++ /dev/null @@ -1,40 +0,0 @@ -#!/bin/bash - -set -xe - -cd /usr/share/systemtap/testsuite - -# Remove slow tests - -for i in systemtap.base/listing_mode_sanity.exp \ -systemtap.base/rlimit.exp \ -systemtap.onthefly/kprobes_onthefly.exp \ -systemtap.syscall/nd_syscall.exp \ -systemtap.syscall/tp_syscall.exp \ -systemtap.base/listing_mode.exp \ -systemtap.base/tracepoints_list.exp \ -systemtap.onthefly/hrtimer_onthefly.exp \ -systemtap.pass1-4/parse-semok.exp \ -systemtap.syscall/syscall.exp \ -systemtap.base/sdt_misc.exp \ -systemtap.base/sdt_buildid.exp \ -systemtap.pass1-4/buildok-interactive.exp \ -systemtap.unprivileged/unprivileged_myproc.exp \ -systemtap.pass1-4/buildok.exp \ -systemtap.examples/check.exp; do - rm -rf $i -done - -# # Remove whole directories -# -# for i in systemtap.analysis systemtap.apps systemtap.base systemtap.bpf \ -# systemtap.clone systemtap.context systemtap.examples systemtap.exelib \ -# systemtap.http_exporter systemtap.http_server systemtap.interactive \ -# systemtap.language_server systemtap.maps systemtap.onthefly systemtap.pass1-4 \ -# systemtap.printf systemtap.python systemtap.samples systemtap.server \ -# systemtap.speculate systemtap.stress systemtap.string systemtap.syscall \ -# systemtap.unprivileged; \ -# do -# echo $i | grep -q "systemtap.base" && continue -# rm -rf $i -# done diff --git a/tests/Regression/upstream-testsuite/watchdog.sh b/tests/Regression/upstream-testsuite/watchdog.sh deleted file mode 100755 index c92de6d..0000000 --- a/tests/Regression/upstream-testsuite/watchdog.sh +++ /dev/null @@ -1,45 +0,0 @@ -#!/bin/bash - -PROCESSES='stap staprun stapio' -TIMEOUT_MIN=17 -SUITELOC=${SUITELOC:-/root/build/testsuite} -LOG_PREFIX="WATCHDOG" -SIGNAL="-9" - -# set -x -killcount=0 -while true; do - date +"${LOG_PREFIX}: %a %F %H:%M: " | tr -d '\n' - echo "Alive (pid $$)" - for p in $PROCESSES; do - for pid in `pgrep $p`; do - test -f /proc/$pid/status || continue - grep -q "State.*zombie" /proc/$pid/status && continue - # echo "Checking process $p, pid $pid" - start_datetime=`ps --no-headers -o lstart -p $pid` - start_stamp=`date -d "$start_datetime" +"%s"` - now=`date +%s` - runtime=$(( (now - start_stamp) / 60 )) - # echo "Started $start_stamp, now is $now, tzn runtime=${runtime}min" - if test $runtime -ge $TIMEOUT_MIN; then - echo - grep '^Running' $SUITELOC/systemtap.sum | tail -3 | sed "s/.*/${LOG_PREFIX}: SUM:\ \0/" - tail -10 $SUITELOC/systemtap.log | sed "s/.*/${LOG_PREFIX}: LOG:\ \0/" - dmesg | tail -30 | sed "s/.*/${LOG_PREFIX}: DMESG:\ \0/" - date +"${LOG_PREFIX}: %a %F %H:%M: " | tr -d '\n' - echo -n "Checking process $p pid $pid, runtime $runtime min. " - if kill $SIGNAL $pid; then - killcount=$((killcount + 1)) - echo "Killed (killcount=$killcount)." - # Killing one process sometimes affects others, so - # we break and recollect the PIDs in next iteration. - break - else - echo "${LOG_PREFIX}: Kill attempted, but failed." - fi - fi - done - done - test -f /tmp/stopwatchdog && break - sleep 60 -done diff --git a/tests/Regression/utrace-taskfinder-misses-events/main.fmf b/tests/Regression/utrace-taskfinder-misses-events/main.fmf deleted file mode 100644 index a8fed74..0000000 --- a/tests/Regression/utrace-taskfinder-misses-events/main.fmf +++ /dev/null @@ -1,17 +0,0 @@ -summary: Test for BZ#876848 (utrace taskfinder misses events when main thread) -description: '' -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap - - gcc-c++ - - kernel-debuginfo -duration: 15m -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=876848 -extra-summary: /tools/systemtap/Regression/utrace-taskfinder-misses-events -extra-task: /tools/systemtap/Regression/utrace-taskfinder-misses-events -tag: fedora diff --git a/tests/Regression/utrace-taskfinder-misses-events/pthreadtestcase.cpp b/tests/Regression/utrace-taskfinder-misses-events/pthreadtestcase.cpp deleted file mode 100644 index 30a8215..0000000 --- a/tests/Regression/utrace-taskfinder-misses-events/pthreadtestcase.cpp +++ /dev/null @@ -1,35 +0,0 @@ -#include -#include -#include - -int square (int x) -{ - return (x * x); -} - -void *my_thread(void *arg) -{ - int x = 0; - int sqr; - - while (true) { - sqr = square(5); - sleep(1); - } - return NULL; -} - -int main() -{ - pthread_t thread_id; - if (pthread_create(&thread_id, NULL, my_thread, NULL)) { - fprintf(stderr, "Error creating thread\n"); - return 1; - } - if (pthread_join(thread_id, NULL)) { - fprintf(stderr, "Error joining thread\n"); - return 2; - } - return 0; -} - diff --git a/tests/Regression/utrace-taskfinder-misses-events/pthreadtestcase.stp b/tests/Regression/utrace-taskfinder-misses-events/pthreadtestcase.stp deleted file mode 100644 index d6ab354..0000000 --- a/tests/Regression/utrace-taskfinder-misses-events/pthreadtestcase.stp +++ /dev/null @@ -1,28 +0,0 @@ -#! /usr/bin/env stap - -probe timer.sec(180) -{ - printf("EXITONTIMEOUT\n"); - exit() -} - -probe process("./pthreadtestcase").function("square") -{ - printf("USERSPACEFUNCTIONENTER\n") - printf("=> %s(%s)\n", probefunc(), $$parms) -} - -probe process("./pthreadtestcase").function("square").return -{ - printf("USERSPACEFUNCTIONLEAVE\n") - printf("<= %s\n", probefunc()) - exit() -} - -probe process("./pthreadtestcase").statement("*@pthreadtestcase.cpp:7") -{ - printf("USERSPACEREACHEDLINE\n") - #printf(" x=%d, sqr=%d\n\n", $x, $sqr) - printf(" x=%d\n\n", $x) -} - diff --git a/tests/Regression/utrace-taskfinder-misses-events/runtest.sh b/tests/Regression/utrace-taskfinder-misses-events/runtest.sh deleted file mode 100755 index c20788c..0000000 --- a/tests/Regression/utrace-taskfinder-misses-events/runtest.sh +++ /dev/null @@ -1,77 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/utrace-taskfinder-misses-events -# Description: Test for BZ#876848 (utrace taskfinder misses events when main thread) -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2013 Red Hat, Inc. All rights reserved. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -# if this testcase caused kernel crash and reboot, don't try to rerun it -[[ $REBOOTCOUNT -gt 0 ]] && exit 1 - -rlJournalStart - rlPhaseStartSetup - rlRun "TMPDIR=\$(mktemp -d)" - rlRun "cp pthreadtestcase.cpp pthreadtestcase.stp $TMPDIR" - rlRun "pushd $TMPDIR" - rlPhaseEnd - - rlPhaseStart FAIL "Systemtap sanity check" - rlRun "stap --version" - rlRun "stap -v -e 'probe kernel.function(\"vfs_read\"){ exit() }'" - rlPhaseEnd - - rlPhaseStart FAIL "Prepare pthreadtestcase, run it" - rlRun "g++ -g -o pthreadtestcase pthreadtestcase.cpp -lpthread" - killall -9 pthreadtestcase &> /dev/null - ./pthreadtestcase & - MYPID=$! - sleep 3 - rlRun "ps | grep '$MYPID.*pthreadtestcase$'" - rlPhaseEnd - - rlPhaseStartTest - rlRun "stap -v pthreadtestcase.stp 2>&1 | tee mylog.txt" - rlRun "grep EXITONTIMEOUT mylog.txt" 1 - for token in USERSPACEFUNCTIONENTER \ - USERSPACEREACHEDLINE \ - USERSPACEFUNCTIONLEAVE - do - rlRun "grep ^$token$ mylog.txt" 0 - done - rlPhaseEnd - - rlPhaseStart FAIL "Shut pthreadtestcase down" - # pthreadtestcase should still be running - # so killing it should certsinly succeed - rlRun "kill $MYPID" - rlPhaseEnd - - rlPhaseStartCleanup - rlRun "popd" - rlRun "rm -r $TMPDIR" - rlPhaseEnd -rlJournalEnd diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/main.fmf b/tests/Regression/wrong-data-returned-by-nfs-commit-done/main.fmf deleted file mode 100644 index 2542286..0000000 --- a/tests/Regression/wrong-data-returned-by-nfs-commit-done/main.fmf +++ /dev/null @@ -1,15 +0,0 @@ -summary: wrong-data-returned-by-nfs-commit-done -description: '' -contact: Martin Cermak -component: - - systemtap -test: ./runtest.sh -framework: beakerlib -recommend: - - systemtap -duration: 2h -link: - - relates: https://bugzilla.redhat.com/show_bug.cgi?id=920444 -extra-summary: /tools/systemtap/Regression/wrong-data-returned-by-nfs-commit-done -extra-task: /tools/systemtap/Regression/wrong-data-returned-by-nfs-commit-done -tag: fedora diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/nfs.proc.commit_done.c b/tests/Regression/wrong-data-returned-by-nfs-commit-done/nfs.proc.commit_done.c deleted file mode 100644 index f7b5e9b..0000000 --- a/tests/Regression/wrong-data-returned-by-nfs-commit-done/nfs.proc.commit_done.c +++ /dev/null @@ -1,84 +0,0 @@ -#include -#include -#include -#include -#include -#include -#include -#include - -#define TEST_DIR "/systemtap-sts-nfs-share-and-mount-tmpdir2/sts_mount" - -static int create_and_write(char *file_name); -static int read_file(char *file_name); - -int main(int argc, char *argv[]) -{ - char tmp_path[1024]; - char tmp_file[1024]; - char new_file[1024]; - - strcpy(tmp_path, getenv("HOME")); - strcat(tmp_path, TEST_DIR); - strcat(tmp_path, "/sts_tmp"); - strcpy(tmp_file, tmp_path); - strcpy(new_file, tmp_path); - strcat(tmp_file, "/tmp.txt"); - strcat(new_file, "/tmp2.txt"); - - if (mkdir(tmp_path, 0777) == -1) { - fprintf(stderr, "Create tmp path failed! %d\n", errno); - return -1; - } - if (create_and_write(tmp_file)) - return -1; - - if (rename(tmp_file, new_file) == -1) { - fprintf(stderr, "Rename failed! %d\n", errno); - return -1; - } - read_file(new_file); - if (remove(new_file) == -1) { - fprintf(stderr, "Remove file failed! %d\n", errno); - return -1; - } - - remove(tmp_path); - - return 0; -} - -static int create_and_write(char *file_name) -{ - char buf[] = "abcdefg123"; - int i; - int fd; - - fd = open(file_name, O_RDWR | O_CREAT, 00777); - if (!fd) { - fprintf(stderr, "Create tmp file failed!\n"); - return -1; - } - - for (i = 0; i < 1024 * 1024; i++){ - if (write(fd, buf, 10) != 10) { - fprintf(stderr, "Write error!\n"); - return -1; - } - } - - close(fd); - return 0; -} - -static int read_file(char *file_name) -{ - char buf[1024]; - int fd; - - fd = open(file_name, O_RDONLY); - lseek(fd, 1024 * 10, SEEK_SET); - read(fd, buf, 1024); - close(fd); - return 0; -} diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/nfs.proc.commit_done.stp b/tests/Regression/wrong-data-returned-by-nfs-commit-done/nfs.proc.commit_done.stp deleted file mode 100644 index 8de8be0..0000000 --- a/tests/Regression/wrong-data-returned-by-nfs-commit-done/nfs.proc.commit_done.stp +++ /dev/null @@ -1,3 +0,0 @@ -probe nfs.proc.commit_done{ - printf("nfs.proc.commit_done server_ip: %s\n", %( systemtap_v >= "4.3" %? server_ip %: ip_ntop(server_ip) %)); -} diff --git a/tests/Regression/wrong-data-returned-by-nfs-commit-done/runtest.sh b/tests/Regression/wrong-data-returned-by-nfs-commit-done/runtest.sh deleted file mode 100755 index b33b035..0000000 --- a/tests/Regression/wrong-data-returned-by-nfs-commit-done/runtest.sh +++ /dev/null @@ -1,78 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Regression/wrong-data-returned-by-nfs-commit-done -# Description: wrong-data-returned-by-nfs-commit-done -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2013 Red Hat, Inc. All rights reserved. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 -. /etc/os-release || exit 1 - -PACKAGE="systemtap" -export NFS_TMP="$HOME/systemtap-sts-nfs-share-and-mount-tmpdir2" - -rlJournalStart - rlPhaseStartSetup - rlRun "rpm -qf $(which --skip-alias stap)" - rlRun "TMPDIR=$(mktemp -d)" - rlRun "cp nfs.proc.commit_done.c nfs.proc.commit_done.stp $TMPDIR/" - rlRun "pushd $TMPDIR" - rlRun "mkdir -p ${NFS_TMP}/sts_share ${NFS_TMP}/sts_mount" - rlPhaseEnd - - rlPhaseStart FAIL "Build testing binary, prepare nfs environment" - rlRun "systemctl stop nfs-server.service" - rlRun "systemctl stop rpcbind.service" - rlRun "sleep 3" - rlRun "systemctl start rpcbind.service" - rlRun "sleep 3" - rlRun "systemctl start nfs-server.service" - rlRun "sleep 3" - rlRun "systemctl status nfs-server.service" - rlRun "systemctl status rpcbind.service" - rlRun "exportfs -i -o 'rw,async,no_root_squash' 127.0.0.1:${NFS_TMP}/sts_share" - rlRun "mount -vvvvv -t nfs 127.0.0.1:${NFS_TMP}/sts_share ${NFS_TMP}/sts_mount" - rlRun "gcc nfs.proc.commit_done.c -o nfs.proc.commit_done" - rlPhaseEnd - - rlPhaseStartTest - ps="-P" - stap -p2 nfs.proc.commit_done.stp >&/dev/null && ps='' - rlRun "stap $ps --poison-cache -vc './nfs.proc.commit_done' nfs.proc.commit_done.stp 2>&1 | tee testout.log" - rlRun "grep -qP 'nfs.proc.commit_done server_ip:\ \d+\.\d+\.\d+\.\d+' testout.log" - rlPhaseEnd - - rlPhaseStart WARN "Clean the nfs environment up" - rlRun "umount -l ${NFS_TMP}/sts_mount" - rlRun "systemctl stop nfs-server.service" - rlRun "systemctl stop rpcbind.service" - rlPhaseEnd - - rlPhaseStartCleanup - rlRun "popd" - rlRun "rm -r $TMPDIR $NFS_TMP" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Sanity/byteman-java-methods-probing/ThreadedExample.java b/tests/Sanity/byteman-java-methods-probing/ThreadedExample.java deleted file mode 100644 index 8aa0f83..0000000 --- a/tests/Sanity/byteman-java-methods-probing/ThreadedExample.java +++ /dev/null @@ -1,60 +0,0 @@ -package foo.bar; - -import java.lang.*; -import java.util.*; - -class ThreadedExample -{ - - public static void printMessage(int message) { - System.out.println("message: " + message); - } - - public static void printMessage(long message) { - System.out.println("message: " + message); - } - - public static void main(String[] args) { - - // sleep so that stap can start and byteman agent gets installed - try { - Thread.sleep(30000); - } catch(InterruptedException ex) { - Thread.currentThread().interrupt(); - } - - - try { - String[] inputs = new String[] {"int", "foo", "long"}; - for (String next : inputs) { - - final String arg = next; - final int i = 42; - final long j = 987234864; - Thread thread = new Thread(arg) { - public void run() { - if(arg.equals("int")) - printMessage(i); - else if(arg.equals("long")) - printMessage(j); - else - System.out.println("Neither of the types"); - } - }; - thread.start(); - try { - thread.join(); - } catch (Exception e){} - } - } catch (Exception e){} - - - // sleep so that stap can finish still while probed java program still runs - try { - Thread.sleep(80000); - } catch(InterruptedException ex) { - Thread.currentThread().interrupt(); - } - } -} - diff --git a/tests/Sanity/byteman-java-methods-probing/ThreadedExample.stp b/tests/Sanity/byteman-java-methods-probing/ThreadedExample.stp deleted file mode 100644 index 2aaa08c..0000000 --- a/tests/Sanity/byteman-java-methods-probing/ThreadedExample.stp +++ /dev/null @@ -1,18 +0,0 @@ -probe java("foo.bar.ThreadedExample").class("ThreadedExample").method("printMessage(int)") -{ - printf("Hit printMessage(int): %s\n", arg1) -} - -probe java("foo.bar.ThreadedExample").class("ThreadedExample").method("printMessage(long)") -{ - printf("Hit printMessage(long): %s\n", arg1) - exit() -} - -probe timer.ms(100000) -{ - error("Exit on timeout") - exit() -} - - diff --git a/tests/Sanity/byteman-java-methods-probing/main.fmf b/tests/Sanity/byteman-java-methods-probing/main.fmf deleted file mode 100644 index 3e1dd29..0000000 --- a/tests/Sanity/byteman-java-methods-probing/main.fmf +++ /dev/null @@ -1,13 +0,0 @@ -summary: byteman-java-methods-probing -description: '' -contact: Martin Cermak -test: ./runtest.sh -framework: beakerlib -recommend: -- java-devel -- systemtap -- systemtap-runtime-java -duration: 15m -extra-summary: /tools/systemtap/Sanity/byteman-java-methods-probing -extra-task: /tools/systemtap/Sanity/byteman-java-methods-probing -tag: fedora diff --git a/tests/Sanity/byteman-java-methods-probing/runtest.sh b/tests/Sanity/byteman-java-methods-probing/runtest.sh deleted file mode 100755 index aa424fc..0000000 --- a/tests/Sanity/byteman-java-methods-probing/runtest.sh +++ /dev/null @@ -1,83 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Sanity/byteman-java-methods-probing -# Description: byteman-java-methods-probing -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2013 Red Hat, Inc. All rights reserved. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -rlJournalStart - rlPhaseStartSetup - rlLogInfo "DEBUGINFOD_URLS=$DEBUGINFOD_URLS" - rlLogInfo "DEBUGINFOD_TIMEOUT=$DEBUGINFOD_TIMEOUT" - - # At this point we simply rely on that the %triggerin scriptlet from - # systemtap-runtime-java did it's job well. There was a hack to force - # trigger it here, but commit respective to this comment removes it. - # https://bugzilla.redhat.com/show_bug.cgi?id=1732514#c11 - - rlRun "rpm -qa | grep -F -e systemtap-runtime-java -e byteman -e openjdk | sort" - - rlRun "stap-prep" - - for BINARY in java javac; do - rlRun "alternatives --display $BINARY | grep -v slave" - rlRun "$BINARY -version" - done - - rlRun "TMPDIR=$( mktemp -d )" - rlRun "mkdir -p $TMPDIR/foo/bar" - rlRun "cp ThreadedExample.java $TMPDIR/foo/bar/" - rlRun "cp ThreadedExample.stp $TMPDIR/" - rlRun "pushd $TMPDIR" - rlPhaseEnd - - rlPhaseStart FAIL 'Prepare bytecode class' - rlRun "javac foo/bar/ThreadedExample.java" - rlPhaseEnd - - rlPhaseStart FAIL 'Prepare the LKML' - rlRun "stap -p4 -m ThreadedExample ThreadedExample.stp" - rlPhaseEnd - - rlPhaseStart FAIL 'Check the Feature' - java foo.bar.ThreadedExample & - rlRun "jps -l | grep 'foo.bar.ThreadedExample'" - export STAPBM_VERBOSE=yes - # rlRun "stap --poison-cache -vv ThreadedExample.stp 2>&1 | tee testout.log" - # Speed the stap startup up by pre-compiling the module within separate - # phase 'Prepare the LKML' above. - rlRun "staprun -v -R ThreadedExample.ko 2>&1 | tee testout.log" - rlRun "grep -q 'Hit printMessage(int): 42' testout.log" - rlRun "grep -q 'Hit printMessage(long): 987234864' testout.log" - rlPhaseEnd - - rlPhaseStartCleanup - rlRun "popd" - rlRun "rm -r $TMPDIR" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Sanity/kernel-modules/Makefile.template b/tests/Sanity/kernel-modules/Makefile.template deleted file mode 100644 index a8bfffb..0000000 --- a/tests/Sanity/kernel-modules/Makefile.template +++ /dev/null @@ -1,3 +0,0 @@ -obj-m := MODULENAME.o -module: - make -C /lib/modules/$(shell uname -r)/build KBUILD_EXTMOD=DIRECTORY SUBDIRS=DIRECTORY modules diff --git a/tests/Sanity/kernel-modules/main.fmf b/tests/Sanity/kernel-modules/main.fmf deleted file mode 100644 index 8fb98dc..0000000 --- a/tests/Sanity/kernel-modules/main.fmf +++ /dev/null @@ -1,18 +0,0 @@ -summary: Tests systemtap working with kernel modules -description: '' -contact: Petr Muller -component: -- systemtap -test: ./runtest.sh -framework: beakerlib -recommend: -- systemtap -- kernel-devel -- bison -- flex -- openssl-devel -- elfutils-libelf-devel -duration: 10m -extra-summary: /tools/systemtap/Sanity/kernel-modules -extra-task: /tools/systemtap/Sanity/kernel-modules -tag: fedora diff --git a/tests/Sanity/kernel-modules/module.c b/tests/Sanity/kernel-modules/module.c deleted file mode 100644 index 427ddbc..0000000 --- a/tests/Sanity/kernel-modules/module.c +++ /dev/null @@ -1,20 +0,0 @@ -#include /* Needed by all modules */ -#include /* Needed for KERN_INFO */ - -int init_module(void) -{ - printk(KERN_INFO "Hello world 1.\n"); - return 0; -} - -int some_method(void){ - printk(KERN_INFO "Some method called\n"); - return 0; -} - -void cleanup_module(void) -{ - printk(KERN_INFO "Goodbye world 1.\n"); -} - -MODULE_LICENSE("GPL"); diff --git a/tests/Sanity/kernel-modules/runtest.sh b/tests/Sanity/kernel-modules/runtest.sh deleted file mode 100755 index b8d32d8..0000000 --- a/tests/Sanity/kernel-modules/runtest.sh +++ /dev/null @@ -1,123 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Sanity/kernel-modules -# Description: Tests systemtap working with kernel modules -# Author: Petr Muller -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2012 Red Hat, Inc. All rights reserved. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh - -PACKAGE="systemtap" - -check_probes(){ - FAIL="" - rlAssertGrep init_module $1 || FAIL='yes' - rlAssertGrep cleanup_module $1 || FAIL='yes' - rlAssertGrep some_method $1 || FAIL='yes' - - if [ -n "$FAIL" ] - then - rlFileSubmit $1 $2.out - fi -} - -rlJournalStart - -rlPhaseStartSetup "Preparing modules" - rlRun "mkdir -p 'stap-underscore' 'stap-dash' 'stap-none'" - rlRun "cp module.c stap-underscore/test_module.c" - rlRun "cp module.c stap-dash/test-module.c" - rlRun "cp module.c stap-none/testmodule.c" - - cat Makefile.template | sed -e 's/MODULENAME/test_module/g' \ - | sed -e "s|DIRECTORY|$PWD/stap-underscore|g" > stap-underscore/Makefile - rlAssert0 "Creating Makefile for underscore variant" $? - cat Makefile.template | sed -e 's/MODULENAME/test-module/g' \ - | sed -e "s|DIRECTORY|$PWD/stap-dash|g" > stap-dash/Makefile - rlAssert0 "Creating Makefile for dash variant" $? - - cat Makefile.template | sed -e 's/MODULENAME/testmodule/g' \ - | sed -e "s|DIRECTORY|$PWD/stap-none|g" > stap-none/Makefile - rlAssert0 "Creating Makefile for no character variant" $? - - if [ -n "$ARCH" ] - then - rlLog "ARCH is set to: [$ARCH]" - rlLog "This interferes with 'make module', so it needs to be unset." - ARCHOLD="$ARCH" - unset ARCH - rlLog "ARCH is set to: [$ARCH]" - fi - rlRun "make -C stap-underscore module" - rlRun "make -C stap-dash module" - rlRun "make -C stap-none module" - if [ -n "$ARCHOLD" ] - then - rlLog "Restoring ARCH" - export ARCH="$ARCHOLD" - rlLog "ARCH is set to: [$ARCH]" - fi - -rlPhaseEnd - -rlPhaseStartTest "Testing underscore variant" - rlRun "cp stap-underscore/test_module.ko /lib/modules/$(uname -r)/" - rlRun "insmod stap-underscore/test_module.ko" - stap -L 'module("test_module").function("*")' -v > stap.out - check_probes stap.out "module-und-probe-und" - stap -L 'module("test-module").function("*")' -v > stap.out - check_probes stap.out "module-und-probe-dash" - sleep 1 - rlRun "rmmod test_module" - rlRun "rm -f /lib/modules/$(uname -r)/test_module.ko" -rlPhaseEnd - -rlPhaseStartTest "Testing dash variant" - rlRun "cp stap-dash/test-module.ko /lib/modules/$(uname -r)/" - rlRun "insmod stap-dash/test-module.ko" - stap -L 'module("test_module").function("*")' -v > stap.out - check_probes stap.out "module-dash-probe-und" - stap -L 'module("test-module").function("*")' -v > stap.out - check_probes stap.out "module-dash-probe-dash" - sleep 1 - rlRun "rmmod test-module" - rlRun "rm -f /lib/modules/$(uname -r)/test-module.ko" -rlPhaseEnd - -rlPhaseStartTest "Testing no separator variant" - rlRun "cp stap-none/testmodule.ko /lib/modules/$(uname -r)/" - rlRun "insmod stap-none/testmodule.ko" - stap -L 'module("testmodule").function("*")' -v > stap.out - check_probes stap.out "module-none-probe-none" - sleep 1 - rlRun "rmmod testmodule" - rlRun "rm -f /lib/modules/$(uname -r)/testmodule.ko" -rlPhaseEnd - -rlPhaseStartCleanup - rlRun "rm -rf stap-underscore stap-dash stap-none stap.out" -rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Sanity/quick-smoke-test/main.fmf b/tests/Sanity/quick-smoke-test/main.fmf deleted file mode 100644 index f40c03b..0000000 --- a/tests/Sanity/quick-smoke-test/main.fmf +++ /dev/null @@ -1,17 +0,0 @@ -summary: Quick test that systemtap generally works -description: '' -contact: -- Petr Muller -component: -- systemtap -test: ./runtest.sh -framework: beakerlib -recommend: -- koji -- systemtap -- kernel-devel -duration: 1h -extra-summary: /tools/systemtap/Sanity/quick-smoke-test -extra-task: /tools/systemtap/Sanity/quick-smoke-test -tag: fedora -tier: 1 diff --git a/tests/Sanity/quick-smoke-test/runtest.sh b/tests/Sanity/quick-smoke-test/runtest.sh deleted file mode 100755 index 35f0313..0000000 --- a/tests/Sanity/quick-smoke-test/runtest.sh +++ /dev/null @@ -1,20 +0,0 @@ -#!/bin/bash - -# runtest.sh of /tools/systemtap/Sanity/quick-smoke-test - -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -rlJournalStart -rlPhaseStartTest - rlLogInfo "DEBUGINFOD_URLS=$DEBUGINFOD_URLS" - rlLogInfo "DEBUGINFOD_TIMEOUT=$DEBUGINFOD_TIMEOUT" - rlRun "rpm -qa | grep -E '^(kernel|systemtap)' | sort" - rlRun "uname -r" - rlRun "stap-prep" - rlRun "stap -L 'process(\"stap\").mark(\"*\")' | grep pass" - rlRun "stap -v --example helloworld.stp" - rlRun "stap -v -T 10 -p4 -e 'probe kernel.function(\"do_exit\") {println(\$\$vars)}'" - rlRun "stap -v -T 60 -e 'probe kernel.function(\"vfs_read\"){ println(\$\$vars); exit() }'" -rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Sanity/stap-server-basic-sanity/main.fmf b/tests/Sanity/stap-server-basic-sanity/main.fmf deleted file mode 100644 index 84da959..0000000 --- a/tests/Sanity/stap-server-basic-sanity/main.fmf +++ /dev/null @@ -1,18 +0,0 @@ -summary: stap-server-basic-sanity -description: '' -contact: Martin Cermak -component: -- systemtap -test: ./runtest.sh -framework: beakerlib -recommend: -- systemtap -- kernel-debuginfo -- avahi -- systemtap-server -- dbus -- net-tools -duration: 45m -extra-summary: /tools/systemtap/Sanity/stap-server-basic-sanity -extra-task: /tools/systemtap/Sanity/stap-server-basic-sanity -tag: fedora diff --git a/tests/Sanity/stap-server-basic-sanity/runtest.sh b/tests/Sanity/stap-server-basic-sanity/runtest.sh deleted file mode 100755 index 7c40bad..0000000 --- a/tests/Sanity/stap-server-basic-sanity/runtest.sh +++ /dev/null @@ -1,97 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/systemtap/Sanity/stap-server-basic-sanity -# Description: stap-server-basic-sanity -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2013 Red Hat, Inc. All rights reserved. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -CMD='stap' -BIN=$(which --skip-alias $CMD) -PACKAGE="${PACKAGE:-$(rpm -qf --qf='%{name}\n' $BIN | head -1)}" - -function service_stap_server() { - action=$1 - retval=${2:-0} - sleep 5 - rlLogInfo "PACKAGE=$PACKAGE" - if echo $PACKAGE | grep -q devtoolset; then - __i=$(echo $PACKAGE | awk -F- '{print $2}') - rlRun "service devtoolset-$__i-stap-server $action" $retval - elif echo $PACKAGE | grep -q gcc-toolset; then - __i=$(echo $PACKAGE | awk -F- '{print $3}') - rlRun "service gcc-toolset-$__i-stap-server $action" $retval - else - rlRun "service stap-server $action" $retval - fi - sleep 5 -} - -_rhelmajor=$(rpm --eval '%{rhel}') - -rlJournalStart - rlPhaseStartSetup - rlLogInfo "DEBUGINFOD_URLS=$DEBUGINFOD_URLS" - rlLogInfo "DEBUGINFOD_TIMEOUT=$DEBUGINFOD_TIMEOUT" - rlRun "TMPDIR=$(mktemp -d)" - rlRun "pushd $TMPDIR" - rlAssertRpm dbus - rlAssertRpm avahi - rlAssertRpm net-tools # because of netstat - rlPhaseEnd - - rlPhaseStart FAIL "sanity check" - rlRun "stap -v -e 'probe begin { log(\"hello\"); exit() }'" - rlPhaseEnd - - rlPhaseStartTest - rlRun "service iptables stop" 0-255 - rlRun "service firewalld stop" 0-255 - service_stap_server stop - test $_rhelmajor -le 8 && \ - rlRun "service messagebus restart" - rlRun "service avahi-daemon restart" - service_stap_server start - - rlRun "netstat -tlp | grep stap" - rlRun "SERVER_PORT=$( netstat -tlpn | awk '/stap/ {print $4}' | grep -o '[0-9]*$' )" - - for SERVER_IP in '127.0.0.1' '[::1]'; do - rlLogInfo "Testing SERVER_IP=$SERVER_IP" - rlRun "stap --trust-servers=ssl,signer,all-users,no-prompt --use-server=$SERVER_IP:$SERVER_PORT" - rlRun "stap --use-server=$SERVER_IP:$SERVER_PORT -v -e 'probe begin { log(\"hello\"); exit() }' 2>&1 | tee output.log" - rlRun "grep 'Using a compile server' output.log" - rlRun "grep '^hello$' output.log" - done - rlPhaseEnd - - rlPhaseStartCleanup - service_stap_server stop - rlRun "popd" - rlRun "rm -r $TMPDIR" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Sanity/userspace-probes/hello.c b/tests/Sanity/userspace-probes/hello.c deleted file mode 100644 index 60dac5b..0000000 --- a/tests/Sanity/userspace-probes/hello.c +++ /dev/null @@ -1,7 +0,0 @@ -#include - -int main(void) { - printf("Hello world!\n"); - return 0; -} - diff --git a/tests/Sanity/userspace-probes/main.fmf b/tests/Sanity/userspace-probes/main.fmf deleted file mode 100644 index 07fb48c..0000000 --- a/tests/Sanity/userspace-probes/main.fmf +++ /dev/null @@ -1,18 +0,0 @@ -summary: userspace-probes -description: '' -contact: Martin Cermak -component: -- systemtap -test: ./runtest.sh -framework: beakerlib -recommend: -- systemtap -- dyninst-devel -- gawk -duration: 5m -link: -- relates: https://bugzilla.redhat.com/show_bug.cgi?id=855981 -extra-summary: /CoreOS/systemtap/Sanity/userspace-probes -extra-task: /CoreOS/systemtap/Sanity/userspace-probes -enabled: true -tag: fedora diff --git a/tests/Sanity/userspace-probes/runtest.sh b/tests/Sanity/userspace-probes/runtest.sh deleted file mode 100755 index 52fb25d..0000000 --- a/tests/Sanity/userspace-probes/runtest.sh +++ /dev/null @@ -1,89 +0,0 @@ -#!/bin/bash -# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /CoreOS/systemtap/Sanity/userspace-probes -# Description: userspace-probes -# Author: Martin Cermak -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2013 Red Hat, Inc. All rights reserved. -# -# This copyrighted material is made available to anyone wishing -# to use, modify, copy, or redistribute it subject to the terms -# and conditions of the GNU General Public License version 2. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public -# License along with this program; if not, write to the Free -# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -# Boston, MA 02110-1301, USA. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -PACKAGE="$(rpm -qf $( which stap ) | head -n 1 )" -WORKDIR=$( mktemp -d ) -TESTUSER=mytestuser - - - -rlJournalStart - rlPhaseStart WARN "Check the environment" - rlLogInfo "DEBUGINFOD_URLS=$DEBUGINFOD_URLS" - rlLogInfo "DEBUGINFOD_TIMEOUT=$DEBUGINFOD_TIMEOUT" - if ! stap -V 2>&1 | grep -q 'enabled features:.*DYNINST'; then - rlLogWarning "No dyninst available in $PACKAGE" - rlPhaseEnd - rlJournalPrintText - rlJournalEnd - exit 0 - fi - rlRun "useradd $TESTUSER" 0,9 - rlRun "su $TESTUSER -c 'which stap'" - rlRun "rpm -qa | grep -F -e dyninst -e systemtap | sort" - rlPhaseEnd - - rlPhaseStartSetup - rlRun "cp hello.c testcase*.sh $WORKDIR" - rlRun "chown -R $TESTUSER:$TESTUSER $WORKDIR" - rlPhaseEnd - - rlPhaseStart FAIL "Testcase 1" - rlRun "which gcc" - rlRun "su $TESTUSER -c 'gcc -g -o $WORKDIR/hello $WORKDIR/hello.c'" - rlRun "su $TESTUSER -c '$WORKDIR/hello'" - rlRun "chmod a+x $WORKDIR/testcase1.sh" - rlRun "su $TESTUSER -c '$WORKDIR/testcase1.sh $WORKDIR'" - - LOG="$WORKDIR/stapout.log" - - rlRun "cat $LOG" - rlRun "grep '^process(\"$WORKDIR/hello\").function(\"main@$WORKDIR/hello.c:3\")$' $LOG" - rlRun "grep -i error $LOG" 1 - rlPhaseEnd - - rlPhaseStart FAIL "Testcase 2" - rlRun "chmod a+x $WORKDIR/testcase2.sh" - rlRun "su $TESTUSER -c '$WORKDIR/testcase2.sh $WORKDIR'" - - LOG="$WORKDIR/stapout.log" - - rlRun "cat $LOG" - rlRun "grep '^\*\*\*\ exiting\ \*\*\*$' $LOG" - rlRun "grep -E -i 'error|warning' $LOG" 1 - rlPhaseEnd - - rlPhaseStartCleanup - rlRun "userdel $TESTUSER" 0-255 - rlRun "rm -rf /home/$TESTUSER $WORKDIR" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd diff --git a/tests/Sanity/userspace-probes/testcase1.sh b/tests/Sanity/userspace-probes/testcase1.sh deleted file mode 100755 index 818d2cd..0000000 --- a/tests/Sanity/userspace-probes/testcase1.sh +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/bash - -stap -e "probe process(\"$1/hello\").function(\"main\") { println(pn()) }" --runtime=dyninst -c "$1/hello" -o "$1/stapout.log" diff --git a/tests/Sanity/userspace-probes/testcase2.sh b/tests/Sanity/userspace-probes/testcase2.sh deleted file mode 100755 index d270d09..0000000 --- a/tests/Sanity/userspace-probes/testcase2.sh +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/bash - -stap --runtime=dyninst -e 'probe end { printf("*** exiting ***\n"); exit() }' -c "$1/hello" -o "$1/stapout.log" - From 9c79ac67a5e743e4f2772ca4a358f7d6c0951e71 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Fri, 30 Aug 2024 08:52:32 -0400 Subject: [PATCH 077/101] Automated weekly systemtap rawhide release: 5.2~pre17250223gd07e4284 --- .gitignore | 1 + sources | 2 +- systemtap.spec | 53 ++++++++++++++++++++++++-------------------------- 3 files changed, 27 insertions(+), 29 deletions(-) diff --git a/.gitignore b/.gitignore index eab5424..e5cfcc0 100644 --- a/.gitignore +++ b/.gitignore @@ -101,3 +101,4 @@ /systemtap-5.1~pre17206206ge48abca5.tar.gz /systemtap-5.2~pre17206355g1a07290a.tar.gz /systemtap-5.2~pre17224323g98d1ea34.tar.gz +/systemtap-5.2~pre17250223gd07e4284.tar.gz diff --git a/sources b/sources index a2109b7..3306e19 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.2~pre17224323g98d1ea34.tar.gz) = e8b1b11daf966e753fddb3f330a330061726b9fc0222b45f403ee33eab6fe48670fd4378de2756375a43ee2e3fbbe4541731d0fb3d4a744a2d07553ccc03fe3b +SHA512 (systemtap-5.2~pre17250223gd07e4284.tar.gz) = 09b319d215a33a147e3082a12c3b7a8f238bc53910b0e8de01a61bc8474b11fe52c78e9b662343e403469061f518cabcc0c780342c33e7517095395ef64b6f36 diff --git a/systemtap.spec b/systemtap.spec index 89a474c..0b686fd 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -120,8 +120,8 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.2~pre17224323g98d1ea34 -Release: 2%{?release_override}%{?dist} +Version: 5.2~pre17250223gd07e4284 +Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -156,7 +156,7 @@ Release: 2%{?release_override}%{?dist} Summary: Programmable system-wide instrumentation system License: GPL-2.0-or-later -URL: http://sourceware.org/systemtap/ +URL: https://sourceware.org/systemtap/ Source: %{name}-%{version}.tar.gz # Build* @@ -260,7 +260,7 @@ the components needed to locally develop and execute systemtap scripts. %package server Summary: Instrumentation System Server License: GPL-2.0-or-later -URL: http://sourceware.org/systemtap/ +URL: https://sourceware.org/systemtap/ Requires: systemtap-devel = %{version}-%{release} Conflicts: systemtap-devel < %{version}-%{release} Conflicts: systemtap-runtime < %{version}-%{release} @@ -290,7 +290,7 @@ compiles systemtap scripts to kernel objects on their demand. %package devel Summary: Programmable system-wide instrumentation system - development headers, tools License: GPL-2.0-or-later AND GPL-2.0-only AND BSD-3-Clause AND LGPL-2.1-only AND BSD-2-Clause -URL: http://sourceware.org/systemtap/ +URL: https://sourceware.org/systemtap/ %if 0%{?rhel} >= 8 || 0%{?fedora} >= 20 Recommends: (kernel-debug-devel if kernel-debug) @@ -320,7 +320,7 @@ a copy of the standard tapset library and the runtime library C files. %package runtime Summary: Programmable system-wide instrumentation system - runtime License: GPL-2.0-or-later -URL: http://sourceware.org/systemtap/ +URL: https://sourceware.org/systemtap/ Requires(pre): shadow-utils Conflicts: systemtap-devel < %{version}-%{release} Conflicts: systemtap-server < %{version}-%{release} @@ -335,7 +335,7 @@ using a local or remote systemtap-devel installation. %package client Summary: Programmable system-wide instrumentation system - client License: GPL-2.0-or-later AND GPL-2.0-only AND BSD-3-Clause AND LGPL-2.1-only AND GFDL-1.2-or-later AND BSD-2-Clause -URL: http://sourceware.org/systemtap/ +URL: https://sourceware.org/systemtap/ Requires: zip unzip Requires: systemtap-runtime = %{version}-%{release} Requires: coreutils grep sed unzip zip @@ -358,7 +358,7 @@ documentation, and a copy of the tapset library for reference. %package initscript Summary: Systemtap Initscripts License: GPL-2.0-or-later -URL: http://sourceware.org/systemtap/ +URL: https://sourceware.org/systemtap/ Requires: systemtap = %{version}-%{release} %if %{with_systemd} Requires: systemd @@ -378,7 +378,7 @@ boot-time probing if supported. %package sdt-devel Summary: Static probe support header files License: GPL-2.0-or-later AND CC0-1.0 -URL: http://sourceware.org/systemtap/ +URL: https://sourceware.org/systemtap/ %description sdt-devel This package includes the header file used for static @@ -388,7 +388,7 @@ instrumentation compiled into userspace programs. %package sdt-dtrace Summary: Static probe support dtrace tool License: GPL-2.0-or-later AND CC0-1.0 -URL: http://sourceware.org/systemtap/ +URL: https://sourceware.org/systemtap/ Provides: dtrace = %{version}-%{release} %if %{with_pyparsing} %if %{with_python3} @@ -410,7 +410,7 @@ to process related .d files into tracing-macro-laden .h headers. %package testsuite Summary: Instrumentation System Testsuite License: GPL-2.0-or-later AND GPL-2.0-only AND GPL-3.0-or-later AND MIT -URL: http://sourceware.org/systemtap/ +URL: https://sourceware.org/systemtap/ Requires: systemtap = %{version}-%{release} Requires: systemtap-sdt-devel = %{version}-%{release} Requires: systemtap-server = %{version}-%{release} @@ -482,7 +482,7 @@ systemtap on the current system. %package runtime-java Summary: Systemtap Java Runtime Support License: GPL-2.0-or-later -URL: http://sourceware.org/systemtap/ +URL: https://sourceware.org/systemtap/ Requires: systemtap-runtime = %{version}-%{release} # work around fedora ci gating kvetching about i686<->x86-64 conflicts %ifarch x86_64 @@ -504,7 +504,7 @@ that probe Java processes running on the OpenJDK runtimes using Byteman. %package runtime-python2 Summary: Systemtap Python 2 Runtime Support License: GPL-2.0-or-later -URL: http://sourceware.org/systemtap/ +URL: https://sourceware.org/systemtap/ Requires: systemtap-runtime = %{version}-%{release} %description runtime-python2 @@ -516,7 +516,7 @@ that probe python 2 processes. %package runtime-python3 Summary: Systemtap Python 3 Runtime Support License: GPL-2.0-or-later -URL: http://sourceware.org/systemtap/ +URL: https://sourceware.org/systemtap/ Requires: systemtap-runtime = %{version}-%{release} %if ! (%{with_python2_probes}) @@ -533,7 +533,7 @@ that probe python 3 processes. %package exporter Summary: Systemtap-prometheus interoperation mechanism License: GPL-2.0-or-later -URL: http://sourceware.org/systemtap/ +URL: https://sourceware.org/systemtap/ Requires: systemtap-runtime = %{version}-%{release} %description exporter @@ -546,7 +546,7 @@ to remote requesters on demand. %package runtime-virthost Summary: Systemtap Cross-VM Instrumentation - host License: GPL-2.0-or-later -URL: http://sourceware.org/systemtap/ +URL: https://sourceware.org/systemtap/ # only require libvirt-libs really #Requires: libvirt >= 1.0.2 Requires: libxml2 @@ -561,7 +561,7 @@ connection. %package runtime-virtguest Summary: Systemtap Cross-VM Instrumentation - guest License: GPL-2.0-or-later -URL: http://sourceware.org/systemtap/ +URL: https://sourceware.org/systemtap/ Requires: systemtap-runtime = %{version}-%{release} %if %{with_systemd} Requires(post): findutils coreutils @@ -581,7 +581,7 @@ systemtap-runtime-virthost machine to execute systemtap scripts. %package jupyter Summary: ISystemtap jupyter kernel and examples License: GPL-2.0-or-later -URL: http://sourceware.org/systemtap/ +URL: https://sourceware.org/systemtap/ Requires: systemtap = %{version}-%{release} %description jupyter @@ -1134,7 +1134,7 @@ exit 0 %if %{with_emacsvim} %{_emacs_sitelispdir}/*.el* %{_emacs_sitestartdir}/systemtap-init.el -%{_datadir}/vim/vimfiles/*/*.vim +%{_datadir}/vim/vimfiles %endif # Notice that the stap-resolve-module-function.py file is used by # *both* the python2 and python3 subrpms. Both subrpms use that same @@ -1237,7 +1237,6 @@ exit 0 %files sdt-devel %{_includedir}/sys/sdt.h %{_includedir}/sys/sdt-config.h -%{_mandir}/man1/dtrace.1* %{_rpmmacrodir}/macros.systemtap %doc README AUTHORS NEWS %{!?_licensedir:%global license %%doc} @@ -1247,7 +1246,9 @@ exit 0 %files sdt-dtrace %{_bindir}/dtrace %doc README AUTHORS NEWS +%{!?_licensedir:%global license %%doc} %license COPYING +%{_mandir}/man1/dtrace.1* %files testsuite @@ -1318,20 +1319,16 @@ exit 0 # Future new-release entries should be of the form # * DDD MMM DD YYYY YOURNAME - V-R # - Upstream release, see wiki page below for detailed notes. -# http://sourceware.org/systemtap/wiki/SystemTapReleases +# https://sourceware.org/systemtap/wiki/SystemTapReleases # PRERELEASE %changelog -* Thu Aug 08 2024 Lumír Balhar - 5.2-17224323g98d1ea34-2 -- Final split of sdt-dtrace and sdt-devel (rhbz#2296275) - https://fedoraproject.org/wiki/Changes/Separate_dtrace_package - -* Wed Jul 31 2024 William Cohen - 5.2-17224323g98d1ea34 +* Fri Aug 30 2024 Frank Ch. Eigler - 5.2-17250223gd07e4284 - Automated weekly rawhide release - Applied spec changes from upstream git -* Wed Jul 17 2024 Lumír Balhar - 5.2~pre17206355g1a07290a-2 -- New sdt-dtrace subpackage for dtrace tool (rhbz#2296275) +* Thu Aug 08 2024 Lumír Balhar - 5.2-pre +- Final split of sdt-dtrace and sdt-devel (rhbz#2296275) https://fedoraproject.org/wiki/Changes/Separate_dtrace_package * Fri Apr 26 2024 Frank Ch. Eigler - 5.1-1 From 5a82cccf7361492a01fa63c1a3f1a050a9dfc89b Mon Sep 17 00:00:00 2001 From: William Cohen Date: Tue, 1 Oct 2024 11:15:22 -0400 Subject: [PATCH 078/101] Automated weekly systemtap rawhide release: 5.2~pre17277956g0b7f6722 --- .gitignore | 1 + sources | 2 +- systemtap.spec | 19 +++++++++++++------ 3 files changed, 15 insertions(+), 7 deletions(-) diff --git a/.gitignore b/.gitignore index e5cfcc0..3a07d63 100644 --- a/.gitignore +++ b/.gitignore @@ -102,3 +102,4 @@ /systemtap-5.2~pre17206355g1a07290a.tar.gz /systemtap-5.2~pre17224323g98d1ea34.tar.gz /systemtap-5.2~pre17250223gd07e4284.tar.gz +/systemtap-5.2~pre17277956g0b7f6722.tar.gz diff --git a/sources b/sources index 3306e19..1bf173b 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.2~pre17250223gd07e4284.tar.gz) = 09b319d215a33a147e3082a12c3b7a8f238bc53910b0e8de01a61bc8474b11fe52c78e9b662343e403469061f518cabcc0c780342c33e7517095395ef64b6f36 +SHA512 (systemtap-5.2~pre17277956g0b7f6722.tar.gz) = 4589b466bbf43c33b47dc7defb6f1d2d9f50ff8599dc8e333a200aa23068f85ba36127a71ca68d524a7e9c74a768c9a6c16c3fa5360d46bf178f23fc5c187322 diff --git a/systemtap.spec b/systemtap.spec index 0b686fd..84d5027 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -120,7 +120,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.2~pre17250223gd07e4284 +Version: 5.2~pre17277956g0b7f6722 Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -348,12 +348,14 @@ Requires: mokutil %endif %description client -This package contains/requires the components needed to develop -systemtap scripts, and compile them using a local systemtap-devel -or a remote systemtap-server installation, then run them using a -local or remote systemtap-runtime. It includes script samples and +This package contains/requires only the components needed to +use systemtap scripts by compiling them using a local or a remote +systemtap-server service, then run them using a local or +remote systemtap-runtime. It includes script samples and documentation, and a copy of the tapset library for reference. - +It does NOT include all the components for running a systemtap +script in a self-contained fashion; for that, use the -devel +subpackage instead. %package initscript Summary: Systemtap Initscripts @@ -1141,6 +1143,7 @@ exit 0 # python script to help list python probes. %if %{with_python3_probes} || %{with_python2_probes} %{_libexecdir}/systemtap/python/stap-resolve-module-function.py +%dir %{_libexecdir}/systemtap/python %exclude %{_libexecdir}/systemtap/python/stap-resolve-module-function.py? %endif @@ -1323,6 +1326,10 @@ exit 0 # PRERELEASE %changelog +* Tue Oct 01 2024 William Cohen - 5.2-17277956g0b7f6722 +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Fri Aug 30 2024 Frank Ch. Eigler - 5.2-17250223gd07e4284 - Automated weekly rawhide release - Applied spec changes from upstream git From 67e80ccf0056e1086eb1bc0e566692a58c6fa0cd Mon Sep 17 00:00:00 2001 From: William Cohen Date: Mon, 7 Oct 2024 13:24:16 -0400 Subject: [PATCH 079/101] Automated weekly systemtap rawhide release: 5.2~pre17283218gc5774e18 --- .gitignore | 1 + sources | 2 +- systemtap.spec | 6 +++++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 3a07d63..4667998 100644 --- a/.gitignore +++ b/.gitignore @@ -103,3 +103,4 @@ /systemtap-5.2~pre17224323g98d1ea34.tar.gz /systemtap-5.2~pre17250223gd07e4284.tar.gz /systemtap-5.2~pre17277956g0b7f6722.tar.gz +/systemtap-5.2~pre17283218gc5774e18.tar.gz diff --git a/sources b/sources index 1bf173b..feb04dc 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.2~pre17277956g0b7f6722.tar.gz) = 4589b466bbf43c33b47dc7defb6f1d2d9f50ff8599dc8e333a200aa23068f85ba36127a71ca68d524a7e9c74a768c9a6c16c3fa5360d46bf178f23fc5c187322 +SHA512 (systemtap-5.2~pre17283218gc5774e18.tar.gz) = b7731529ae6577f2b724f9f05a105519c5cd990d0ecd9982ee5550fe7103c121deff5d0ddb29cc0f03097bae21d6b33ccd857714af8f82edd42a0341c5238d81 diff --git a/systemtap.spec b/systemtap.spec index 84d5027..e3f98a5 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -120,7 +120,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.2~pre17277956g0b7f6722 +Version: 5.2~pre17283218gc5774e18 Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -1326,6 +1326,10 @@ exit 0 # PRERELEASE %changelog +* Mon Oct 07 2024 William Cohen - 5.2-17283218gc5774e18 +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Tue Oct 01 2024 William Cohen - 5.2-17277956g0b7f6722 - Automated weekly rawhide release - Applied spec changes from upstream git From 17f221776b076fd16e53f280662239a190820c9f Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Fri, 8 Nov 2024 19:58:20 -0500 Subject: [PATCH 080/101] upstream systemtap 5.2 release --- .gitignore | 1 + sources | 2 +- systemtap.spec | 8 ++++++-- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 4667998..c7a87f3 100644 --- a/.gitignore +++ b/.gitignore @@ -104,3 +104,4 @@ /systemtap-5.2~pre17250223gd07e4284.tar.gz /systemtap-5.2~pre17277956g0b7f6722.tar.gz /systemtap-5.2~pre17283218gc5774e18.tar.gz +/systemtap-5.2.tar.gz diff --git a/sources b/sources index feb04dc..68e20e1 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.2~pre17283218gc5774e18.tar.gz) = b7731529ae6577f2b724f9f05a105519c5cd990d0ecd9982ee5550fe7103c121deff5d0ddb29cc0f03097bae21d6b33ccd857714af8f82edd42a0341c5238d81 +SHA512 (systemtap-5.2.tar.gz) = 30137e232e44abe98747ae61a71a162eff5abc89e9a922f86ade834eac2cac1923ae06d4ed17710718adba082ad06d2fb544822003a54e13b97eea9e183bdf9d diff --git a/systemtap.spec b/systemtap.spec index e3f98a5..b8ab46a 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -120,7 +120,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.2~pre17283218gc5774e18 +Version: 5.2 Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -157,7 +157,7 @@ Release: 1%{?release_override}%{?dist} Summary: Programmable system-wide instrumentation system License: GPL-2.0-or-later URL: https://sourceware.org/systemtap/ -Source: %{name}-%{version}.tar.gz +Source: ftp://sourceware.org/pub/systemtap/releases/systemtap-%{version}.tar.gz # Build* BuildRequires: make @@ -1326,6 +1326,10 @@ exit 0 # PRERELEASE %changelog +* Fri Nov 08 2024 Frank Ch. Eigler - 5.2-1 +- Upstream release, see wiki page below for detailed notes. + https://sourceware.org/systemtap/wiki/SystemTapReleases + * Mon Oct 07 2024 William Cohen - 5.2-17283218gc5774e18 - Automated weekly rawhide release - Applied spec changes from upstream git From eb8c0fea4cd000225f689a9230301886567e8d3d Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Sun, 19 Jan 2025 12:16:21 +0000 Subject: [PATCH 081/101] Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index b8ab46a..36f2730 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -121,7 +121,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE Version: 5.2 -Release: 1%{?release_override}%{?dist} +Release: 2%{?release_override}%{?dist} # for version, see also configure.ac @@ -1326,6 +1326,9 @@ exit 0 # PRERELEASE %changelog +* Sun Jan 19 2025 Fedora Release Engineering - 5.2-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild + * Fri Nov 08 2024 Frank Ch. Eigler - 5.2-1 - Upstream release, see wiki page below for detailed notes. https://sourceware.org/systemtap/wiki/SystemTapReleases From ae0cad098c75d1e830d95e3733cc3ea71e35538b Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Sun, 19 Jan 2025 22:01:49 -0500 Subject: [PATCH 082/101] Automated weekly systemtap rawhide release: 5.2~pre17373420g1e894ff0 --- .gitignore | 1 + sources | 2 +- systemtap.spec | 28 +++++++++++++++++++++++----- 3 files changed, 25 insertions(+), 6 deletions(-) diff --git a/.gitignore b/.gitignore index c7a87f3..ed8c697 100644 --- a/.gitignore +++ b/.gitignore @@ -105,3 +105,4 @@ /systemtap-5.2~pre17277956g0b7f6722.tar.gz /systemtap-5.2~pre17283218gc5774e18.tar.gz /systemtap-5.2.tar.gz +/systemtap-5.2~pre17373420g1e894ff0.tar.gz diff --git a/sources b/sources index 68e20e1..5450295 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.2.tar.gz) = 30137e232e44abe98747ae61a71a162eff5abc89e9a922f86ade834eac2cac1923ae06d4ed17710718adba082ad06d2fb544822003a54e13b97eea9e183bdf9d +SHA512 (systemtap-5.2~pre17373420g1e894ff0.tar.gz) = f0389b82095ff69c65d5083d272a791c2142b9a78df62bf9c70713f415ffcc7afc5bb461980270317ba30b6858d668337d6257ab6884eca7654ebd835937313a diff --git a/systemtap.spec b/systemtap.spec index 36f2730..6278290 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -45,6 +45,7 @@ %{!?with_httpd: %global with_httpd 0} %{!?with_specific_python: %global with_specific_python 0%{?fedora} >= 31} %{!?with_sysusers: %global with_sysusers 0%{?fedora} >= 32 || 0%{?rhel} >= 9} +%{!?with_check: %global with_check 0%{?fedora} >= 42} # Virt is supported on these arches, even on el7, but it's not in core EL7 %if 0%{?rhel} && 0%{?rhel} <= 7 @@ -120,8 +121,8 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.2 -Release: 2%{?release_override}%{?dist} +Version: 5.2~pre17373420g1e894ff0 +Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -157,7 +158,7 @@ Release: 2%{?release_override}%{?dist} Summary: Programmable system-wide instrumentation system License: GPL-2.0-or-later URL: https://sourceware.org/systemtap/ -Source: ftp://sourceware.org/pub/systemtap/releases/systemtap-%{version}.tar.gz +Source: %{name}-%{version}.tar.gz # Build* BuildRequires: make @@ -209,7 +210,7 @@ BuildRequires: xmlto /usr/share/xmlto/format/fo/pdf %endif %if %{with_emacsvim} # for _emacs_sitelispdir macros etc. -BuildRequires: emacs +BuildRequires: emacs-common %endif %if %{with_java} BuildRequires: java-devel @@ -241,8 +242,15 @@ BuildRequires: libmicrohttpd-devel BuildRequires: libuuid-devel %endif %if %{with_sysusers} -BuildRequires: systemd-rpm-macros +BuildRequires: systemd-rpm-macros %endif +%if %{with_check} +BuildRequires: (kernel-debug-devel if kernel-debug) +BuildRequires: (kernel-devel if kernel) +# and some of the same Requires: as below +BuildRequires: dejagnu gcc make +%endif + # Install requirements @@ -847,6 +855,12 @@ done %py3_shebang_fix %{buildroot}%{python3_sitearch} %{buildroot}%{_bindir}/* %endif +%check +%if %{with_check} +make check RUNTESTFLAGS=environment_sanity.exp +%endif + + %pre runtime %if %{with_sysusers} echo '%_systemtap_runtime_preinstall' | systemd-sysusers --replace=%{_sysusersdir}/systemtap-runtime.conf - @@ -1326,6 +1340,10 @@ exit 0 # PRERELEASE %changelog +* Sun Jan 19 2025 Frank Ch. Eigler - 5.2-17373420g1e894ff0 +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Sun Jan 19 2025 Fedora Release Engineering - 5.2-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild From 4f28506db7071162d6880f1c16b6f04044c0352d Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Sun, 19 Jan 2025 22:04:39 -0500 Subject: [PATCH 083/101] Automated weekly systemtap rawhide release: 5.3~pre17373422g9a48fbea --- .gitignore | 1 + sources | 2 +- systemtap.spec | 6 +++++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index ed8c697..fa6e10d 100644 --- a/.gitignore +++ b/.gitignore @@ -106,3 +106,4 @@ /systemtap-5.2~pre17283218gc5774e18.tar.gz /systemtap-5.2.tar.gz /systemtap-5.2~pre17373420g1e894ff0.tar.gz +/systemtap-5.3~pre17373422g9a48fbea.tar.gz diff --git a/sources b/sources index 5450295..8a17119 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.2~pre17373420g1e894ff0.tar.gz) = f0389b82095ff69c65d5083d272a791c2142b9a78df62bf9c70713f415ffcc7afc5bb461980270317ba30b6858d668337d6257ab6884eca7654ebd835937313a +SHA512 (systemtap-5.3~pre17373422g9a48fbea.tar.gz) = c7a3929d5c9fb90c63986e7657df9b55c8007728d4d180a1bb41f0eef7321d149bf63c3ca5629ed56171bd08f931076abb39eb7a6f6066931bf7060b0a4e4560 diff --git a/systemtap.spec b/systemtap.spec index 6278290..e6be2dc 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -121,7 +121,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.2~pre17373420g1e894ff0 +Version: 5.3~pre17373422g9a48fbea Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -1340,6 +1340,10 @@ exit 0 # PRERELEASE %changelog +* Sun Jan 19 2025 Frank Ch. Eigler - 5.3-17373422g9a48fbea +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Sun Jan 19 2025 Frank Ch. Eigler - 5.2-17373420g1e894ff0 - Automated weekly rawhide release - Applied spec changes from upstream git From e8c03b8035e23130d4b2be8ebd0c66d414c894a0 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Mon, 20 Jan 2025 08:26:17 -0500 Subject: [PATCH 084/101] Automated weekly systemtap rawhide release: 5.3~pre17373794g3efe129d --- .gitignore | 1 + sources | 2 +- systemtap.spec | 9 ++++++--- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/.gitignore b/.gitignore index fa6e10d..861a257 100644 --- a/.gitignore +++ b/.gitignore @@ -107,3 +107,4 @@ /systemtap-5.2.tar.gz /systemtap-5.2~pre17373420g1e894ff0.tar.gz /systemtap-5.3~pre17373422g9a48fbea.tar.gz +/systemtap-5.3~pre17373794g3efe129d.tar.gz diff --git a/sources b/sources index 8a17119..34a70de 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.3~pre17373422g9a48fbea.tar.gz) = c7a3929d5c9fb90c63986e7657df9b55c8007728d4d180a1bb41f0eef7321d149bf63c3ca5629ed56171bd08f931076abb39eb7a6f6066931bf7060b0a4e4560 +SHA512 (systemtap-5.3~pre17373794g3efe129d.tar.gz) = 30435388917ed28f5dbea48aa07668951c1488be61114b456cd26115a5dc9371892c26a64277365b0ca2ea20156ba5574c2ca0c39de8d0a0fca5522ab1f58c38 diff --git a/systemtap.spec b/systemtap.spec index e6be2dc..4ae7e3c 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -121,7 +121,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.3~pre17373422g9a48fbea +Version: 5.3~pre17373794g3efe129d Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -245,8 +245,7 @@ BuildRequires: libuuid-devel BuildRequires: systemd-rpm-macros %endif %if %{with_check} -BuildRequires: (kernel-debug-devel if kernel-debug) -BuildRequires: (kernel-devel if kernel) +BuildRequires: kernel-devel # and some of the same Requires: as below BuildRequires: dejagnu gcc make %endif @@ -1340,6 +1339,10 @@ exit 0 # PRERELEASE %changelog +* Mon Jan 20 2025 Frank Ch. Eigler - 5.3-17373794g3efe129d +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Sun Jan 19 2025 Frank Ch. Eigler - 5.3-17373422g9a48fbea - Automated weekly rawhide release - Applied spec changes from upstream git From 2da431cab313ba8e9621adec8d6f9b3d90216dcf Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Mon, 20 Jan 2025 09:01:46 -0500 Subject: [PATCH 085/101] Automated weekly systemtap rawhide release: 5.3~pre17373816g7a71d34b --- .gitignore | 1 + sources | 2 +- systemtap.spec | 11 +++++++++-- 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 861a257..0d17911 100644 --- a/.gitignore +++ b/.gitignore @@ -108,3 +108,4 @@ /systemtap-5.2~pre17373420g1e894ff0.tar.gz /systemtap-5.3~pre17373422g9a48fbea.tar.gz /systemtap-5.3~pre17373794g3efe129d.tar.gz +/systemtap-5.3~pre17373816g7a71d34b.tar.gz diff --git a/sources b/sources index 34a70de..7236a8d 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.3~pre17373794g3efe129d.tar.gz) = 30435388917ed28f5dbea48aa07668951c1488be61114b456cd26115a5dc9371892c26a64277365b0ca2ea20156ba5574c2ca0c39de8d0a0fca5522ab1f58c38 +SHA512 (systemtap-5.3~pre17373816g7a71d34b.tar.gz) = 8b561c10766341d45a26552bf09e8708baf1f737749b484bafa9de02af863ea3f0ac69d61225f89370f09a20054bc9ad86f073eec8dc4f135adb264b7298acaf diff --git a/systemtap.spec b/systemtap.spec index 4ae7e3c..5513e1a 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -45,7 +45,10 @@ %{!?with_httpd: %global with_httpd 0} %{!?with_specific_python: %global with_specific_python 0%{?fedora} >= 31} %{!?with_sysusers: %global with_sysusers 0%{?fedora} >= 32 || 0%{?rhel} >= 9} -%{!?with_check: %global with_check 0%{?fedora} >= 42} +# NB: can't turn this on by default on any distro version whose builder system +# may run kernels different than the distro version itself. +%{!?with_check: %global with_check 0} + # Virt is supported on these arches, even on el7, but it's not in core EL7 %if 0%{?rhel} && 0%{?rhel} <= 7 @@ -121,7 +124,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.3~pre17373794g3efe129d +Version: 5.3~pre17373816g7a71d34b Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -1339,6 +1342,10 @@ exit 0 # PRERELEASE %changelog +* Mon Jan 20 2025 Frank Ch. Eigler - 5.3-17373816g7a71d34b +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Mon Jan 20 2025 Frank Ch. Eigler - 5.3-17373794g3efe129d - Automated weekly rawhide release - Applied spec changes from upstream git From 12f28a923c8cb68af33162adb41f06560b3d29b7 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Fri, 24 Jan 2025 15:25:54 -0500 Subject: [PATCH 086/101] Respin against dyninst 13.0.0 --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index 5513e1a..548fe8e 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -125,7 +125,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE Version: 5.3~pre17373816g7a71d34b -Release: 1%{?release_override}%{?dist} +Release: 2%{?release_override}%{?dist} # for version, see also configure.ac @@ -1342,6 +1342,9 @@ exit 0 # PRERELEASE %changelog +* Fri Jan 24 2025 Frank Ch. Eigler - 5.3~pre17373816g7a71d34b.2 +- Respin against dyninst 13. + * Mon Jan 20 2025 Frank Ch. Eigler - 5.3-17373816g7a71d34b - Automated weekly rawhide release - Applied spec changes from upstream git From a230f161dd96bf453d96f90116246b53f404b7cc Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Fri, 24 Jan 2025 15:51:58 -0500 Subject: [PATCH 087/101] respin try for dyninst 13 --- systemtap.spec | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/systemtap.spec b/systemtap.spec index 548fe8e..3bb3fc9 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -125,7 +125,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE Version: 5.3~pre17373816g7a71d34b -Release: 2%{?release_override}%{?dist} +Release: 3%{?release_override}%{?dist} # for version, see also configure.ac @@ -175,7 +175,7 @@ BuildRequires: pkgconfig(libdebuginfod) BuildRequires: pkgconfig(json-c) %endif %if %{with_dyninst} -BuildRequires: dyninst-devel >= 10.0 +BuildRequires: dyninst-devel >= 13.0 BuildRequires: pkgconfig(libselinux) %endif %if %{with_sqlite} @@ -1342,7 +1342,7 @@ exit 0 # PRERELEASE %changelog -* Fri Jan 24 2025 Frank Ch. Eigler - 5.3~pre17373816g7a71d34b.2 +* Fri Jan 24 2025 Frank Ch. Eigler - 5.3~pre17373816g7a71d34b.3 - Respin against dyninst 13. * Mon Jan 20 2025 Frank Ch. Eigler - 5.3-17373816g7a71d34b From 3105e88d5b5d64b6a5e6f388810efacf16e6a2eb Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Fri, 24 Jan 2025 18:52:57 -0500 Subject: [PATCH 088/101] expect disabled dyninst on i686 --- systemtap.spec | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/systemtap.spec b/systemtap.spec index 3bb3fc9..a28ad8e 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -14,7 +14,7 @@ %{!?with_rpm: %global with_rpm 1} %{!?elfutils_version: %global elfutils_version 0.179} %{!?with_boost: %global with_boost 0} -%ifarch %{ix86} x86_64 ppc ppc64 ppc64le aarch64 +%ifarch x86_64 ppc ppc64 ppc64le aarch64 %{!?with_dyninst: %global with_dyninst 0%{?fedora} >= 18 || 0%{?rhel} >= 7} %else %{!?with_dyninst: %global with_dyninst 0} @@ -125,7 +125,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE Version: 5.3~pre17373816g7a71d34b -Release: 3%{?release_override}%{?dist} +Release: 4%{?release_override}%{?dist} # for version, see also configure.ac @@ -1343,7 +1343,7 @@ exit 0 # PRERELEASE %changelog * Fri Jan 24 2025 Frank Ch. Eigler - 5.3~pre17373816g7a71d34b.3 -- Respin against dyninst 13. +- Respin against dyninst 13, sans dyninst on i686. * Mon Jan 20 2025 Frank Ch. Eigler - 5.3-17373816g7a71d34b - Automated weekly rawhide release From 423d7bf3e55e90622c6d0524dddd482335b893ce Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Thu, 6 Feb 2025 09:04:46 -0500 Subject: [PATCH 089/101] Respin against newer dyninst --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index a28ad8e..3dca235 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -125,7 +125,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE Version: 5.3~pre17373816g7a71d34b -Release: 4%{?release_override}%{?dist} +Release: 5%{?release_override}%{?dist} # for version, see also configure.ac @@ -1342,6 +1342,9 @@ exit 0 # PRERELEASE %changelog +* Thu Feb 06 2025 Frank Ch. Eigler - 5.3~pre17373816g7a71d34b.5 +- Respin against dyninst 13 redux + * Fri Jan 24 2025 Frank Ch. Eigler - 5.3~pre17373816g7a71d34b.3 - Respin against dyninst 13, sans dyninst on i686. From b9c00fd898bb220be44d53f89660d2cc1edba3ad Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Fri, 2 May 2025 14:45:36 -0400 Subject: [PATCH 090/101] rebase to upstream release 5.3 --- .gitignore | 1 + sources | 2 +- systemtap.spec | 33 ++++++++++++++++++++++----------- 3 files changed, 24 insertions(+), 12 deletions(-) diff --git a/.gitignore b/.gitignore index 0d17911..344a031 100644 --- a/.gitignore +++ b/.gitignore @@ -109,3 +109,4 @@ /systemtap-5.3~pre17373422g9a48fbea.tar.gz /systemtap-5.3~pre17373794g3efe129d.tar.gz /systemtap-5.3~pre17373816g7a71d34b.tar.gz +/systemtap-5.3.tar.gz diff --git a/sources b/sources index 7236a8d..65d0436 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.3~pre17373816g7a71d34b.tar.gz) = 8b561c10766341d45a26552bf09e8708baf1f737749b484bafa9de02af863ea3f0ac69d61225f89370f09a20054bc9ad86f073eec8dc4f135adb264b7298acaf +SHA512 (systemtap-5.3.tar.gz) = b252cd00a7ddab53f19d30129834b205ce8e90ccc5422444c1d188b765c122da712f5ca73092c425aef7430888c75ebfebbe3bfd87d6df8761338a1135abda89 diff --git a/systemtap.spec b/systemtap.spec index 3dca235..c125d04 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -13,8 +13,8 @@ %endif %{!?with_rpm: %global with_rpm 1} %{!?elfutils_version: %global elfutils_version 0.179} -%{!?with_boost: %global with_boost 0} -%ifarch x86_64 ppc ppc64 ppc64le aarch64 +%{!?with_boost: %global with_boost 1} +%ifarch %{ix86} x86_64 ppc ppc64 ppc64le aarch64 %{!?with_dyninst: %global with_dyninst 0%{?fedora} >= 18 || 0%{?rhel} >= 7} %else %{!?with_dyninst: %global with_dyninst 0} @@ -124,8 +124,8 @@ m stapdev stapdev Name: systemtap # PRERELEASE -Version: 5.3~pre17373816g7a71d34b -Release: 5%{?release_override}%{?dist} +Version: 5.3 +Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -161,7 +161,7 @@ Release: 5%{?release_override}%{?dist} Summary: Programmable system-wide instrumentation system License: GPL-2.0-or-later URL: https://sourceware.org/systemtap/ -Source: %{name}-%{version}.tar.gz +Source: ftp://sourceware.org/pub/systemtap/releases/systemtap-%{version}.tar.gz # Build* BuildRequires: make @@ -175,7 +175,7 @@ BuildRequires: pkgconfig(libdebuginfod) BuildRequires: pkgconfig(json-c) %endif %if %{with_dyninst} -BuildRequires: dyninst-devel >= 13.0 +BuildRequires: dyninst-devel >= 10.0 BuildRequires: pkgconfig(libselinux) %endif %if %{with_sqlite} @@ -189,9 +189,7 @@ BuildRequires: pkgconfig(ncurses) BuildRequires: systemd %endif # Needed for libstd++ < 4.0, without -%if %{with_boost} BuildRequires: boost-devel -%endif %if %{with_crash} BuildRequires: crash-devel zlib-devel %endif @@ -865,7 +863,10 @@ make check RUNTESTFLAGS=environment_sanity.exp %pre runtime %if %{with_sysusers} +%if 0%{?fedora} && 0%{?fedora} < 42 echo '%_systemtap_runtime_preinstall' | systemd-sysusers --replace=%{_sysusersdir}/systemtap-runtime.conf - +exit 0 +%endif %else getent group stapusr >/dev/null || groupadd -f -g 156 -r stapusr getent group stapsys >/dev/null || groupadd -f -g 157 -r stapsys @@ -873,23 +874,29 @@ getent group stapdev >/dev/null || groupadd -f -g 158 -r stapdev getent passwd stapunpriv >/dev/null || \ useradd -c "Systemtap Unprivileged User" -u 159 -g stapunpriv -d %{_localstatedir}/lib/stapunpriv -r -s /sbin/nologin stapunpriv 2>/dev/null || \ useradd -c "Systemtap Unprivileged User" -g stapunpriv -d %{_localstatedir}/lib/stapunpriv -r -s /sbin/nologin stapunpriv -%endif exit 0 +%endif %pre server %if %{with_sysusers} +%if 0%{?fedora} && 0%{?fedora} < 42 echo '%_systemtap_server_preinstall' | systemd-sysusers --replace=%{_sysusersdir}/systemtap-server.conf - +exit 0 +%endif %else getent group stap-server >/dev/null || groupadd -f -g 155 -r stap-server getent passwd stap-server >/dev/null || \ useradd -c "Systemtap Compile Server" -u 155 -g stap-server -d %{_localstatedir}/lib/stap-server -r -s /sbin/nologin stap-server 2>/dev/null || \ useradd -c "Systemtap Compile Server" -g stap-server -d %{_localstatedir}/lib/stap-server -r -s /sbin/nologin stap-server -%endif exit 0 +%endif %pre testsuite %if %{with_sysusers} +%if 0%{?fedora} && 0%{?fedora} < 42 echo '%_systemtap_testsuite_preinstall' | systemd-sysusers --replace=%{_sysusersdir}/systemtap-testsuite.conf - +exit 0 +%endif %else getent passwd stapusr >/dev/null || \ useradd -c "Systemtap 'stapusr' User" -g stapusr -r -s /sbin/nologin stapusr @@ -897,8 +904,8 @@ getent passwd stapsys >/dev/null || \ useradd -c "Systemtap 'stapsys' User" -g stapsys -G stapusr -r -s /sbin/nologin stapsys getent passwd stapdev >/dev/null || \ useradd -c "Systemtap 'stapdev' User" -g stapdev -G stapusr -r -s /sbin/nologin stapdev -%endif exit 0 +%endif %post server @@ -1342,6 +1349,10 @@ exit 0 # PRERELEASE %changelog +* Fri May 02 2025 Frank Ch. Eigler - 5.3-1 +- Upstream release, see wiki page below for detailed notes. + https://sourceware.org/systemtap/wiki/SystemTapReleases + * Thu Feb 06 2025 Frank Ch. Eigler - 5.3~pre17373816g7a71d34b.5 - Respin against dyninst 13 redux From 967cf9e53d8d37a9fbfd51fbe3481c15f3e5a286 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Fri, 2 May 2025 14:55:11 -0400 Subject: [PATCH 091/101] disable dyninst buildreq on i686 --- systemtap.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index c125d04..c9e5a2e 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -14,7 +14,7 @@ %{!?with_rpm: %global with_rpm 1} %{!?elfutils_version: %global elfutils_version 0.179} %{!?with_boost: %global with_boost 1} -%ifarch %{ix86} x86_64 ppc ppc64 ppc64le aarch64 +%ifarch x86_64 ppc ppc64 ppc64le aarch64 %{!?with_dyninst: %global with_dyninst 0%{?fedora} >= 18 || 0%{?rhel} >= 7} %else %{!?with_dyninst: %global with_dyninst 0} From 846836105b0e2c970fe71075f76350b4c11f9f53 Mon Sep 17 00:00:00 2001 From: Python Maint Date: Tue, 3 Jun 2025 14:30:52 +0200 Subject: [PATCH 092/101] Rebuilt for Python 3.14 --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index c9e5a2e..506ef22 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -125,7 +125,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE Version: 5.3 -Release: 1%{?release_override}%{?dist} +Release: 2%{?release_override}%{?dist} # for version, see also configure.ac @@ -1349,6 +1349,9 @@ exit 0 # PRERELEASE %changelog +* Tue Jun 03 2025 Python Maint - 5.3-2 +- Rebuilt for Python 3.14 + * Fri May 02 2025 Frank Ch. Eigler - 5.3-1 - Upstream release, see wiki page below for detailed notes. https://sourceware.org/systemtap/wiki/SystemTapReleases From 360287bbf0b084b8cbf363f9fb16ae0df511b1dc Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Fri, 25 Jul 2025 19:02:43 +0000 Subject: [PATCH 093/101] Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index 506ef22..30aa772 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -125,7 +125,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE Version: 5.3 -Release: 2%{?release_override}%{?dist} +Release: 3%{?release_override}%{?dist} # for version, see also configure.ac @@ -1349,6 +1349,9 @@ exit 0 # PRERELEASE %changelog +* Fri Jul 25 2025 Fedora Release Engineering - 5.3-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild + * Tue Jun 03 2025 Python Maint - 5.3-2 - Rebuilt for Python 3.14 From ccde07acbd4155a71fdb8d74d1f1f58e8ba28a6a Mon Sep 17 00:00:00 2001 From: Python Maint Date: Fri, 15 Aug 2025 15:19:43 +0200 Subject: [PATCH 094/101] Rebuilt for Python 3.14.0rc2 bytecode --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index 30aa772..a23c708 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -125,7 +125,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE Version: 5.3 -Release: 3%{?release_override}%{?dist} +Release: 4%{?release_override}%{?dist} # for version, see also configure.ac @@ -1349,6 +1349,9 @@ exit 0 # PRERELEASE %changelog +* Fri Aug 15 2025 Python Maint - 5.3-4 +- Rebuilt for Python 3.14.0rc2 bytecode + * Fri Jul 25 2025 Fedora Release Engineering - 5.3-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild From e304ee7f0d9a33f45058a3d45b15f516049d92fc Mon Sep 17 00:00:00 2001 From: Python Maint Date: Fri, 19 Sep 2025 14:59:01 +0200 Subject: [PATCH 095/101] Rebuilt for Python 3.14.0rc3 bytecode --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index a23c708..b16b680 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -125,7 +125,7 @@ m stapdev stapdev Name: systemtap # PRERELEASE Version: 5.3 -Release: 4%{?release_override}%{?dist} +Release: 5%{?release_override}%{?dist} # for version, see also configure.ac @@ -1349,6 +1349,9 @@ exit 0 # PRERELEASE %changelog +* Fri Sep 19 2025 Python Maint - 5.3-5 +- Rebuilt for Python 3.14.0rc3 bytecode + * Fri Aug 15 2025 Python Maint - 5.3-4 - Rebuilt for Python 3.14.0rc2 bytecode From 02ce13f3713c4ad84f311fc6891b53c0e1b7d1f0 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Mon, 22 Sep 2025 09:23:23 -0400 Subject: [PATCH 096/101] Automated weekly systemtap rawhide release: 5.4~pre17585473g1fe4178d --- .gitignore | 1 + sources | 2 +- systemtap.spec | 32 +++++++++++++++++++++++++------- 3 files changed, 27 insertions(+), 8 deletions(-) diff --git a/.gitignore b/.gitignore index 344a031..c176a4d 100644 --- a/.gitignore +++ b/.gitignore @@ -110,3 +110,4 @@ /systemtap-5.3~pre17373794g3efe129d.tar.gz /systemtap-5.3~pre17373816g7a71d34b.tar.gz /systemtap-5.3.tar.gz +/systemtap-5.4~pre17585473g1fe4178d.tar.gz diff --git a/sources b/sources index 65d0436..18a538e 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.3.tar.gz) = b252cd00a7ddab53f19d30129834b205ce8e90ccc5422444c1d188b765c122da712f5ca73092c425aef7430888c75ebfebbe3bfd87d6df8761338a1135abda89 +SHA512 (systemtap-5.4~pre17585473g1fe4178d.tar.gz) = 373b165253413e0c30eec30f553280b8640ad10597d73c7a5ebc71eb45b784e58068b5f20ab8e8823b74c25d801d97afc1a0227907540cc93f334f64ca7de293 diff --git a/systemtap.spec b/systemtap.spec index b16b680..ea91476 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -14,7 +14,7 @@ %{!?with_rpm: %global with_rpm 1} %{!?elfutils_version: %global elfutils_version 0.179} %{!?with_boost: %global with_boost 1} -%ifarch x86_64 ppc ppc64 ppc64le aarch64 +%ifarch %{ix86} x86_64 ppc ppc64 ppc64le aarch64 %{!?with_dyninst: %global with_dyninst 0%{?fedora} >= 18 || 0%{?rhel} >= 7} %else %{!?with_dyninst: %global with_dyninst 0} @@ -121,11 +121,17 @@ m stapsys stapsys\ m stapdev stapusr\ m stapdev stapdev +%define _systemtap_server_preinstall_tmpfiles \ +# See systemd-tmpfiles(8) tmpfiles.d(5)\ +d /var/lib/stap-server 0750 stap-server stap-server -\ +d /var/lib/stap-server/.systemtap 0700 stap-server stap-server -\ +d /var/log/stap-server 0755 stap-server stap-server -\ +f /var/log/stap-server/log 0644 stap-server stap-server - Name: systemtap # PRERELEASE -Version: 5.3 -Release: 5%{?release_override}%{?dist} +Version: 5.4~pre17585473g1fe4178d +Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -161,7 +167,7 @@ Release: 5%{?release_override}%{?dist} Summary: Programmable system-wide instrumentation system License: GPL-2.0-or-later URL: https://sourceware.org/systemtap/ -Source: ftp://sourceware.org/pub/systemtap/releases/systemtap-%{version}.tar.gz +Source: %{name}-%{version}.tar.gz # Build* BuildRequires: make @@ -389,6 +395,10 @@ boot-time probing if supported. Summary: Static probe support header files License: GPL-2.0-or-later AND CC0-1.0 URL: https://sourceware.org/systemtap/ +%if 0%{?rhel} && 0%{?rhel} <= 10 +# for RHEL buildability compatibility, pull in sdt-dtrace at all times +Requires: systemtap-sdt-dtrace = %{version}-%{release} +%endif %description sdt-devel This package includes the header file used for static @@ -730,6 +740,8 @@ mkdir -p %{buildroot}%{_sysusersdir} echo '%_systemtap_runtime_preinstall' > %{buildroot}%{_sysusersdir}/systemtap-runtime.conf echo '%_systemtap_server_preinstall' > %{buildroot}%{_sysusersdir}/systemtap-server.conf echo '%_systemtap_testsuite_preinstall' > %{buildroot}%{_sysusersdir}/systemtap-testsuite.conf +mkdir -p %{buildroot}%{_tmpfilesdir} +echo '%_systemtap_server_preinstall_tmpfiles' > %{buildroot}%{_tmpfilesdir}/systemtap-server.conf %endif @@ -863,7 +875,7 @@ make check RUNTESTFLAGS=environment_sanity.exp %pre runtime %if %{with_sysusers} -%if 0%{?fedora} && 0%{?fedora} < 42 +%if (0%{?fedora} && 0%{?fedora} < 42) || (0%{?rhel} && 0%{?rhel} < 11) echo '%_systemtap_runtime_preinstall' | systemd-sysusers --replace=%{_sysusersdir}/systemtap-runtime.conf - exit 0 %endif @@ -879,8 +891,9 @@ exit 0 %pre server %if %{with_sysusers} -%if 0%{?fedora} && 0%{?fedora} < 42 +%if (0%{?fedora} && 0%{?fedora} < 42) || (0%{?rhel} && 0%{?rhel} < 11) echo '%_systemtap_server_preinstall' | systemd-sysusers --replace=%{_sysusersdir}/systemtap-server.conf - +echo '%_systemtap_server_preinstall_tmpfiles' | systemd-tmpfiles --replace=%{_tmpfilesdir}/systemtap-server.conf - exit 0 %endif %else @@ -893,7 +906,7 @@ exit 0 %pre testsuite %if %{with_sysusers} -%if 0%{?fedora} && 0%{?fedora} < 42 +%if (0%{?fedora} && 0%{?fedora} < 42) || (0%{?rhel} && 0%{?rhel} < 11) echo '%_systemtap_testsuite_preinstall' | systemd-sysusers --replace=%{_sysusersdir}/systemtap-testsuite.conf - exit 0 %endif @@ -1113,6 +1126,7 @@ exit 0 %if %{with_systemd} %{_unitdir}/stap-server.service %{_tmpfilesdir}/stap-server.conf +%{_tmpfilesdir}/systemtap-server.conf %else %{initdir}/stap-server %dir %{_sysconfdir}/stap-server/conf.d @@ -1349,6 +1363,10 @@ exit 0 # PRERELEASE %changelog +* Mon Sep 22 2025 Frank Ch. Eigler - 5.4-17585473g1fe4178d +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Fri Sep 19 2025 Python Maint - 5.3-5 - Rebuilt for Python 3.14.0rc3 bytecode From 703cf33b20d634bb56f65103368f1ea6f3daffb0 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Mon, 22 Sep 2025 10:01:32 -0400 Subject: [PATCH 097/101] Automated weekly systemtap rawhide release: 5.4~pre17585496g86ab88eb --- .gitignore | 1 + sources | 2 +- systemtap.spec | 8 ++++++-- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index c176a4d..de206d5 100644 --- a/.gitignore +++ b/.gitignore @@ -111,3 +111,4 @@ /systemtap-5.3~pre17373816g7a71d34b.tar.gz /systemtap-5.3.tar.gz /systemtap-5.4~pre17585473g1fe4178d.tar.gz +/systemtap-5.4~pre17585496g86ab88eb.tar.gz diff --git a/sources b/sources index 18a538e..8f0ef09 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.4~pre17585473g1fe4178d.tar.gz) = 373b165253413e0c30eec30f553280b8640ad10597d73c7a5ebc71eb45b784e58068b5f20ab8e8823b74c25d801d97afc1a0227907540cc93f334f64ca7de293 +SHA512 (systemtap-5.4~pre17585496g86ab88eb.tar.gz) = ffe6629c773c898f6b16921515de112e250dc6bc6da0b75f9c5c08564c4b48e156b4128d632cc6979371afa5356c77945458795cc86548f2acf8f178f4c740e6 diff --git a/systemtap.spec b/systemtap.spec index ea91476..76177ad 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -14,7 +14,7 @@ %{!?with_rpm: %global with_rpm 1} %{!?elfutils_version: %global elfutils_version 0.179} %{!?with_boost: %global with_boost 1} -%ifarch %{ix86} x86_64 ppc ppc64 ppc64le aarch64 +%ifarch x86_64 ppc ppc64 ppc64le aarch64 %{!?with_dyninst: %global with_dyninst 0%{?fedora} >= 18 || 0%{?rhel} >= 7} %else %{!?with_dyninst: %global with_dyninst 0} @@ -130,7 +130,7 @@ f /var/log/stap-server/log 0644 stap-server stap-server - Name: systemtap # PRERELEASE -Version: 5.4~pre17585473g1fe4178d +Version: 5.4~pre17585496g86ab88eb Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -1363,6 +1363,10 @@ exit 0 # PRERELEASE %changelog +* Mon Sep 22 2025 Frank Ch. Eigler - 5.4-17585496g86ab88eb +- Automated weekly rawhide release +- Applied spec changes from upstream git + * Mon Sep 22 2025 Frank Ch. Eigler - 5.4-17585473g1fe4178d - Automated weekly rawhide release - Applied spec changes from upstream git From 93ca322655453b1dab8b6cbcc581ecb1bcbeb9d0 Mon Sep 17 00:00:00 2001 From: Martin Cermak Date: Mon, 22 Sep 2025 20:32:00 +0200 Subject: [PATCH 098/101] Fix the CI gating setup Fix the CI gating setup per https://docs.fedoraproject.org/en-US/ci/gating/ --- gating.yaml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/gating.yaml b/gating.yaml index ff1fcc6..a2c8282 100644 --- a/gating.yaml +++ b/gating.yaml @@ -1,7 +1,15 @@ --- !Policy product_versions: - fedora-* -decision_context: bodhi_update_push_stable +decision_contexts: [bodhi_update_push_testing] +subject_type: koji_build +rules: + - !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.tier0.functional} + - !PassingTestCaseRule {test_case_name: baseos-qe.koji-build.scratch-build.validation} +--- !Policy +product_versions: + - fedora-* +decision_contexts: [bodhi_update_push_stable] subject_type: koji_build rules: - !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.tier0.functional} From 6fe8d3d7ef1e8f0f97089fa3a851ca6b9647fe80 Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Fri, 31 Oct 2025 14:14:14 -0400 Subject: [PATCH 099/101] upstream release 5.4 --- .gitignore | 1 + sources | 2 +- systemtap.spec | 8 ++++++-- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index de206d5..702599e 100644 --- a/.gitignore +++ b/.gitignore @@ -112,3 +112,4 @@ /systemtap-5.3.tar.gz /systemtap-5.4~pre17585473g1fe4178d.tar.gz /systemtap-5.4~pre17585496g86ab88eb.tar.gz +/systemtap-5.4.tar.gz diff --git a/sources b/sources index 8f0ef09..a210820 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (systemtap-5.4~pre17585496g86ab88eb.tar.gz) = ffe6629c773c898f6b16921515de112e250dc6bc6da0b75f9c5c08564c4b48e156b4128d632cc6979371afa5356c77945458795cc86548f2acf8f178f4c740e6 +SHA512 (systemtap-5.4.tar.gz) = 5869fe3735e44be65ba7895a46b4ea66fcdcc21ed2ab0673c62d822730553837f816d82fd78eeca4bfe6f17fdeaa12eb2f94c0b0b7ebb8c495c961f0b6935785 diff --git a/systemtap.spec b/systemtap.spec index 76177ad..63998aa 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -130,7 +130,7 @@ f /var/log/stap-server/log 0644 stap-server stap-server - Name: systemtap # PRERELEASE -Version: 5.4~pre17585496g86ab88eb +Version: 5.4 Release: 1%{?release_override}%{?dist} # for version, see also configure.ac @@ -167,7 +167,7 @@ Release: 1%{?release_override}%{?dist} Summary: Programmable system-wide instrumentation system License: GPL-2.0-or-later URL: https://sourceware.org/systemtap/ -Source: %{name}-%{version}.tar.gz +Source: ftp://sourceware.org/pub/systemtap/releases/systemtap-%{version}.tar.gz # Build* BuildRequires: make @@ -1363,6 +1363,10 @@ exit 0 # PRERELEASE %changelog +* Fri Oct 31 2025 Frank Ch. Eigler - 5.4-1 +- Upstream release, see wiki page below for detailed notes. + https://sourceware.org/systemtap/wiki/SystemTapReleases + * Mon Sep 22 2025 Frank Ch. Eigler - 5.4-17585496g86ab88eb - Automated weekly rawhide release - Applied spec changes from upstream git From 070cdc17ea5a32e223c6840580c8b16c19c4fa42 Mon Sep 17 00:00:00 2001 From: Jonathan Wakely Date: Tue, 13 Jan 2026 10:52:47 +0000 Subject: [PATCH 100/101] Rebuilt for Boost 1.90 --- systemtap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systemtap.spec b/systemtap.spec index 63998aa..2f345ef 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -131,7 +131,7 @@ f /var/log/stap-server/log 0644 stap-server stap-server - Name: systemtap # PRERELEASE Version: 5.4 -Release: 1%{?release_override}%{?dist} +Release: 2%{?release_override}%{?dist} # for version, see also configure.ac @@ -1363,6 +1363,9 @@ exit 0 # PRERELEASE %changelog +* Tue Jan 13 2026 Jonathan Wakely - 5.4-2 +- Rebuilt for Boost 1.90 + * Fri Oct 31 2025 Frank Ch. Eigler - 5.4-1 - Upstream release, see wiki page below for detailed notes. https://sourceware.org/systemtap/wiki/SystemTapReleases From 0eafb3090d920880b4f5aa2eff59fe92bb189a04 Mon Sep 17 00:00:00 2001 From: Jonathan Wakely Date: Tue, 13 Jan 2026 18:41:19 +0000 Subject: [PATCH 101/101] Patched to workaround Autoconf 2.72 incompatiblity with GCC 16 --- systemtap-gcc16.patch | 13 +++++++++++++ systemtap.spec | 4 +++- 2 files changed, 16 insertions(+), 1 deletion(-) create mode 100644 systemtap-gcc16.patch diff --git a/systemtap-gcc16.patch b/systemtap-gcc16.patch new file mode 100644 index 0000000..c336ce6 --- /dev/null +++ b/systemtap-gcc16.patch @@ -0,0 +1,13 @@ +--- systemtap-5.4/configure~ 2025-10-30 14:47:35.000000000 +0000 ++++ systemtap-5.4/configure 2026-01-13 18:53:20.466037572 +0000 +@@ -3121,8 +3121,8 @@ + } + { + // Unicode literals +- char const *utf8 = u8"UTF-8 string \u2500"; +- char16_t const *utf16 = u"UTF-8 string \u2500"; ++ auto const *utf8 = u8"UTF-8 string \u2500"; ++ char16_t const *utf16 = u"UTF-16 string \u2500"; + char32_t const *utf32 = U"UTF-32 string \u2500"; + } + ' diff --git a/systemtap.spec b/systemtap.spec index 2f345ef..577dc67 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -168,6 +168,7 @@ Summary: Programmable system-wide instrumentation system License: GPL-2.0-or-later URL: https://sourceware.org/systemtap/ Source: ftp://sourceware.org/pub/systemtap/releases/systemtap-%{version}.tar.gz +Patch0: systemtap-gcc16.patch # Build* BuildRequires: make @@ -613,6 +614,7 @@ or within a container. %prep %setup -q +%patch 0 -p1 %build @@ -1364,7 +1366,7 @@ exit 0 # PRERELEASE %changelog * Tue Jan 13 2026 Jonathan Wakely - 5.4-2 -- Rebuilt for Boost 1.90 +- Patched to workaround Autoconf 2.72 incompatiblity with GCC 16 * Fri Oct 31 2025 Frank Ch. Eigler - 5.4-1 - Upstream release, see wiki page below for detailed notes.