doc/SystemTap_Beginners_Guide/testsuite/systemtap.base/overflow_error.stp
raw| 1 | # overflow some stuff to see if error message point to the correct thing. |
| 2 | global count; |
| 3 | global overflow1[3]; |
| 4 | global overflow2[5]; |
| 5 | |
| 6 | probe timer.ms(10) |
| 7 | { |
| 8 | if (count <= 3) |
| 9 | { |
| 10 | overflow1[count++] = gettimeofday_ns(); |
| 11 | } |
| 12 | else |
| 13 | { |
| 14 | overflow2[count++] <<< gettimeofday_ns(); |
| 15 | } |
| 16 | } |
| 17 | |
| 18 | probe timer.s(3) |
| 19 | { |
| 20 | exit(); |
| 21 | } |
| 22 |