Lines Matching refs:FAIL_IF_MSG

179 	FAIL_IF_MSG(ppc_ptrace_gethwdbginfo(pid, &dbginfo), "PPC_PTRACE_GETHWDBGINFO failed");  in check_watchpoints()
197 FAIL_IF_MSG(1, "Failed to fork child"); in ptrace_fork_child()
204 FAIL_IF_MSG(waitpid(*pid, &status, 0) == -1, "Failed to wait for child"); in ptrace_fork_child()
205 FAIL_IF_MSG(!WIFSTOPPED(status), "Child is not stopped"); in ptrace_fork_child()
252 FAIL_IF_MSG(perf_fd < 0, "Failed to open perf performance counter"); in same_watch_addr_test()
257 FAIL_IF_MSG(bp_id < 0, "Failed to set ptrace watchpoint"); in same_watch_addr_test()
260 FAIL_IF_MSG(ptrace_cont(pid, 0), "Failed to continue child"); in same_watch_addr_test()
262 FAIL_IF_MSG(waitpid(pid, &status, 0) == -1, "Failed to wait for child"); in same_watch_addr_test()
263 FAIL_IF_MSG(!WIFSTOPPED(status), "Child is not stopped"); in same_watch_addr_test()
264 FAIL_IF_MSG(ptrace_getreg_pc(pid, &pc), "Failed to get child PC"); in same_watch_addr_test()
265 FAIL_IF_MSG(pc != same_watch_addr_load, "Child did not stop on load instruction"); in same_watch_addr_test()
271 FAIL_IF_MSG(perf_read_counter(perf_fd, &perf_count), "Failed to read perf counter"); in same_watch_addr_test()
272 FAIL_IF_MSG(perf_count != 0, "perf recorded unexpected event"); in same_watch_addr_test()
275 FAIL_IF_MSG(ptrace_singlestep(pid, 0), "Failed to single step child"); in same_watch_addr_test()
277 FAIL_IF_MSG(waitpid(pid, &status, 0) == -1, "Failed to wait for child"); in same_watch_addr_test()
278 FAIL_IF_MSG(!WIFSTOPPED(status), "Child is not stopped"); in same_watch_addr_test()
279 FAIL_IF_MSG(ptrace_getreg_pc(pid, &pc), "Failed to get child PC"); in same_watch_addr_test()
280 FAIL_IF_MSG(pc != same_watch_addr_load + 4, "Failed to single step load instruction"); in same_watch_addr_test()
281 FAIL_IF_MSG(perf_read_counter(perf_fd, &perf_count), "Failed to read perf counter"); in same_watch_addr_test()
282 FAIL_IF_MSG(perf_count != 1, "perf counter did not increment"); in same_watch_addr_test()
289 FAIL_IF_MSG(ppc_ptrace_delhwdbg(pid, bp_id), "Failed to remove old ptrace watchpoint"); in same_watch_addr_test()
291 FAIL_IF_MSG(bp_id < 0, "Failed to set ptrace watchpoint"); in same_watch_addr_test()
292 FAIL_IF_MSG(ptrace_setreg_pc(pid, same_watch_addr_load), "Failed to set child PC"); in same_watch_addr_test()
293 FAIL_IF_MSG(ptrace_cont(pid, 0), "Failed to continue child"); in same_watch_addr_test()
295 FAIL_IF_MSG(waitpid(pid, &status, 0) == -1, "Failed to wait for child"); in same_watch_addr_test()
296 FAIL_IF_MSG(!WIFSTOPPED(status), "Child is not stopped"); in same_watch_addr_test()
297 FAIL_IF_MSG(ptrace_getreg_pc(pid, &pc), "Failed to get child PC"); in same_watch_addr_test()
298 FAIL_IF_MSG(pc != same_watch_addr_load, "Child did not stop on load trap"); in same_watch_addr_test()
299 FAIL_IF_MSG(perf_read_counter(perf_fd, &perf_count), "Failed to read perf counter"); in same_watch_addr_test()
300 FAIL_IF_MSG(perf_count != 1, "perf counter should not have changed"); in same_watch_addr_test()
303 FAIL_IF_MSG(ptrace_cont(pid, 0), "Failed to continue child"); in same_watch_addr_test()
305 FAIL_IF_MSG(waitpid(pid, &status, 0) == -1, "Failed to wait for child"); in same_watch_addr_test()
306 FAIL_IF_MSG(!WIFSTOPPED(status), "Child is not stopped"); in same_watch_addr_test()
307 FAIL_IF_MSG(ptrace_getreg_pc(pid, &pc), "Failed to get child PC"); in same_watch_addr_test()
308 FAIL_IF_MSG(pc != same_watch_addr_trap, "Child did not stop on end trap"); in same_watch_addr_test()
309 FAIL_IF_MSG(perf_read_counter(perf_fd, &perf_count), "Failed to read perf counter"); in same_watch_addr_test()
310 FAIL_IF_MSG(perf_count != 2, "perf counter did not increment"); in same_watch_addr_test()
317 FAIL_IF_MSG(ptrace_setreg_pc(pid, same_watch_addr_load), "Failed to set child PC"); in same_watch_addr_test()
318 FAIL_IF_MSG(ptrace_cont(pid, 0), "Failed to continue child"); in same_watch_addr_test()
320 FAIL_IF_MSG(waitpid(pid, &status, 0) == -1, "Failed to wait for child"); in same_watch_addr_test()
321 FAIL_IF_MSG(!WIFSTOPPED(status), "Child is not stopped"); in same_watch_addr_test()
322 FAIL_IF_MSG(ptrace_getreg_pc(pid, &pc), "Failed to get child PC"); in same_watch_addr_test()
323 FAIL_IF_MSG(pc != same_watch_addr_trap, "Child did not stop on end trap"); in same_watch_addr_test()
324 FAIL_IF_MSG(perf_read_counter(perf_fd, &perf_count), "Failed to read perf counter"); in same_watch_addr_test()
325 FAIL_IF_MSG(perf_count != 3, "perf counter did not increment"); in same_watch_addr_test()
332 FAIL_IF_MSG(ppc_ptrace_delhwdbg(pid, bp_id), "Failed to remove old ptrace watchpoint"); in same_watch_addr_test()
334 FAIL_IF_MSG(bp_id < 0, "Failed to set ptrace watchpoint"); in same_watch_addr_test()
335 FAIL_IF_MSG(ptrace_setreg_pc(pid, same_watch_addr_load), "Failed to set child PC"); in same_watch_addr_test()
336 FAIL_IF_MSG(ptrace_cont(pid, 0), "Failed to continue child"); in same_watch_addr_test()
338 FAIL_IF_MSG(waitpid(pid, &status, 0) == -1, "Failed to wait for child"); in same_watch_addr_test()
339 FAIL_IF_MSG(!WIFSTOPPED(status), "Child is not stopped"); in same_watch_addr_test()
340 FAIL_IF_MSG(ptrace_getreg_pc(pid, &pc), "Failed to get child PC"); in same_watch_addr_test()
341 FAIL_IF_MSG(pc != same_watch_addr_load, "Child did not stop on load instruction"); in same_watch_addr_test()
342 FAIL_IF_MSG(perf_read_counter(perf_fd, &perf_count), "Failed to read perf counter"); in same_watch_addr_test()
343 FAIL_IF_MSG(perf_count != 3, "perf counter should not have changed"); in same_watch_addr_test()
350 FAIL_IF_MSG(ptrace_setreg_pc(pid, same_watch_addr_load + 4), "Failed to set child PC"); in same_watch_addr_test()
351 FAIL_IF_MSG(ptrace_cont(pid, 0), "Failed to continue child"); in same_watch_addr_test()
353 FAIL_IF_MSG(waitpid(pid, &status, 0) == -1, "Failed to wait for child"); in same_watch_addr_test()
354 FAIL_IF_MSG(!WIFSTOPPED(status), "Child is not stopped"); in same_watch_addr_test()
355 FAIL_IF_MSG(ptrace_getreg_pc(pid, &pc), "Failed to get child PC"); in same_watch_addr_test()
356 FAIL_IF_MSG(pc != same_watch_addr_trap, "Child did not stop on end trap"); in same_watch_addr_test()
357 FAIL_IF_MSG(perf_read_counter(perf_fd, &perf_count), "Failed to read perf counter"); in same_watch_addr_test()
358 FAIL_IF_MSG(perf_count != 3, "perf counter should not have changed"); in same_watch_addr_test()
361 FAIL_IF_MSG(kill(pid, SIGKILL) != 0, "Failed to kill child"); in same_watch_addr_test()
411 FAIL_IF_MSG(perf_fd < 0, "Failed to open perf performance counter"); in perf_then_ptrace_test()
417 FAIL_IF_MSG(bp_id < 0, "Failed to set ptrace watchpoint"); in perf_then_ptrace_test()
420 FAIL_IF_MSG(ptrace_cont(pid, 0), "Failed to continue child"); in perf_then_ptrace_test()
422 FAIL_IF_MSG(waitpid(pid, &status, 0) == -1, "Failed to wait for child"); in perf_then_ptrace_test()
423 FAIL_IF_MSG(!WIFSTOPPED(status), "Child is not stopped"); in perf_then_ptrace_test()
424 FAIL_IF_MSG(ptrace_getreg_pc(pid, &pc), "Failed to get child PC"); in perf_then_ptrace_test()
425 FAIL_IF_MSG(pc != perf_then_ptrace_load2, "Child did not stop on ptrace load"); in perf_then_ptrace_test()
428 FAIL_IF_MSG(perf_read_counter(perf_fd, &perf_count), "Failed to read perf counter"); in perf_then_ptrace_test()
429 FAIL_IF_MSG(perf_count != 1, "perf counter did not increment"); in perf_then_ptrace_test()
432 FAIL_IF_MSG(kill(pid, SIGKILL) != 0, "Failed to kill child"); in perf_then_ptrace_test()