Module Name: src Committed By: kamil Date: Sat May 26 15:32:31 UTC 2018
Modified Files: src/tests/lib/libc/sys: t_ptrace_wait.c Log Message: Refactor the PT_WRITE*/PT_READ* and PIOD_* ATF ptrace(2) tests Merge all the PT_WRITE*/PT_READ* and PIOD_* the test cases into the common body. Changes: - treat D and I variations exactly the same - stop testing 2-3-4 attempts to perform the same read/write operation - stop testing interlocked (handshake) read/write operations - rename the tests - test write to .text section (with D and I type of operations) New tests: - bytes_transfer_piod_read_d_8 - bytes_transfer_piod_read_d_16 - bytes_transfer_piod_read_d_32 - bytes_transfer_piod_read_d_64 - bytes_transfer_piod_read_i_8 - bytes_transfer_piod_read_i_16 - bytes_transfer_piod_read_i_32 - bytes_transfer_piod_read_i_64 - bytes_transfer_piod_write_d_8 - bytes_transfer_piod_write_d_16 - bytes_transfer_piod_write_d_32 - bytes_transfer_piod_write_d_64 - bytes_transfer_piod_write_i_8 - bytes_transfer_piod_write_i_16 - bytes_transfer_piod_write_i_32 - bytes_transfer_piod_write_i_64 - bytes_transfer_read_d - bytes_transfer_read_i - bytes_transfer_write_d - bytes_transfer_write_i - bytes_transfer_piod_read_d_8_text - bytes_transfer_piod_read_d_16_text - bytes_transfer_piod_read_d_32_text - bytes_transfer_piod_read_d_64_text - bytes_transfer_piod_read_i_8_text - bytes_transfer_piod_read_i_16_text - bytes_transfer_piod_read_i_32_text - bytes_transfer_piod_read_i_64_text - bytes_transfer_piod_write_d_8_text - bytes_transfer_piod_write_d_16_text - bytes_transfer_piod_write_d_32_text - bytes_transfer_piod_write_d_64_text - bytes_transfer_piod_write_i_8_text - bytes_transfer_piod_write_i_16_text - bytes_transfer_piod_write_i_32_text - bytes_transfer_piod_write_i_64_text - bytes_transfer_read_d_text - bytes_transfer_read_i_text - bytes_transfer_write_d_text - bytes_transfer_write_i_text - bytes_transfer_piod_read_auxv These tests are now covering all usual code paths. All tests pass. The PaX MPROTECT violating ones automatically detect whether to be skipped. Eliminated 4x more code than removed. Sponsored by <The NetBSD Foundation> To generate a diff of this commit: cvs rdiff -u -r1.53 -r1.54 src/tests/lib/libc/sys/t_ptrace_wait.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.