| 1 |
set test "embeddedc_suffix" |
| 2 |
set testpath "$srcdir/$subdir" |
| 3 |
set work_dir [pwd] |
| 4 |
|
| 5 |
if {! [installtest_p]} { untested $test; return } |
| 6 |
|
| 7 |
# --- TEST 1 --- |
| 8 |
|
| 9 |
set subtest1 "TEST 1: PR31018: if stmt needing locks before a map op stmt (check at runtime)" |
| 10 |
foreach runtime [get_runtime_list] { |
| 11 |
if {$runtime eq ""} { |
| 12 |
set runtime "kernel" |
| 13 |
} |
| 14 |
set test_name "$test: $subtest1 ($runtime)" |
| 15 |
set stp_opts "-g -k" |
| 16 |
set cmd "stap $stp_opts --runtime=$runtime '$srcdir/$subdir/${test}_1.stp'" |
| 17 |
set exit_code [run_cmd_2way $cmd out stderr] |
| 18 |
set exp_out "res: 32 |
| 19 |
a=32 |
| 20 |
" |
| 21 |
is "${test_name}: stdout" $out $exp_out |
| 22 |
is "${test_name}: exit code" $exit_code 0 |
| 23 |
if {$stderr ne ""} { |
| 24 |
send_log "stderr:\n$stderr" |
| 25 |
} |
| 26 |
} |