Debian Codegraph @

doc/SystemTap_Beginners_Guide/testsuite/systemtap.base/add.stp

raw
1 /*
2 * add.stp
3 *
4 * Check that systemtap "addition" works
5 */
6
7 global x3
8 global x1
9 global x2
10
11 probe begin
12 {
13 println("systemtap starting probe")
14 x1 = 42; x2 = 53;
15 }
16
17 probe end
18 {
19 println("systemtap ending probe")
20 x3 = x1 + x2;
21 if (x3 != 95 ) {
22 println("systemtap test failure")
23 } else {
24 println("systemtap test success")
25 }
26 }