diff options
author | Jim Keniston <jkenisto@us.ibm.com> | 2009-04-20 16:39:26 -0700 |
---|---|---|
committer | Jim Keniston <jkenisto@us.ibm.com> | 2009-04-20 16:39:26 -0700 |
commit | 436e5bf634020bcb9f98967891508db21f9e6cbd (patch) | |
tree | aa0b83ff4089ab4f15be10d7ffeb94eea2255960 /testsuite/systemtap.base/bz10078.exp | |
parent | d1b6c2866b35575219fb36fa2307c9f87e876750 (diff) | |
download | systemtap-steved-436e5bf634020bcb9f98967891508db21f9e6cbd.tar.gz systemtap-steved-436e5bf634020bcb9f98967891508db21f9e6cbd.tar.xz systemtap-steved-436e5bf634020bcb9f98967891508db21f9e6cbd.zip |
PR10078: uretprobes on functions returning structs/unions
arch_predict_sp_at_ret() for x86_32 now accommodates ret $4.
Added bz10078 regression test.
Diffstat (limited to 'testsuite/systemtap.base/bz10078.exp')
-rw-r--r-- | testsuite/systemtap.base/bz10078.exp | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/testsuite/systemtap.base/bz10078.exp b/testsuite/systemtap.base/bz10078.exp new file mode 100644 index 00000000..cad3a3a8 --- /dev/null +++ b/testsuite/systemtap.base/bz10078.exp @@ -0,0 +1,35 @@ +set test bz10078 + +catch {exec gcc -g -o $test $srcdir/$subdir/$test.c} err +if {$err == "" && [file exists $test]} then { pass "$test compile" } else { fail "$test compile" } + +if {![utrace_p]} { + catch {exec rm -f $test} + untested "$test -p4" + untested "$test -p5" + return +} + +set rc [stap_run_batch $srcdir/$subdir/$test.stp] +if {$rc == 0} then { pass "$test -p4" } else { fail "$test -p4" } + +if {! [installtest_p]} { + catch {exec rm -f $test} + untested "$test -p5" + return +} + +# Pick up the stap being tested. +set stapexe [exec /usr/bin/which stap] +spawn sudo $stapexe $srcdir/$subdir/$test.stp -c ./$test +set ok 0 +expect { + -timeout 60 + -re {mkpoint[^\r\n]* returns\r\n} { incr ok; exp_continue } + -re {1,2\r\n} { incr ok; exp_continue } + timeout { fail "$test (timeout)" } + eof { } +} +wait +if {$ok == 3} then { pass "$test -p5" } else { fail "$test -p5 ($ok)" } +exec rm -f $test |