cosmopolitan/test/posix
Justine Tunney 379cd77078
Improve memory manager and signal handling
On Windows, mmap() now chooses addresses transactionally. It reduces the
risk of badness when interacting with the WIN32 memory manager. We don't
throw darts anymore. There is also no more retry limit, since we recover
from mystery maps more gracefully. The subroutine for combining adjacent
maps has been rewritten for clarity. The print maps subroutine is better

This change goes to great lengths to perfect the stack overflow code. On
Windows you can now longjmp() out of a crash signal handler. Guard pages
previously weren't being restored properly by the signal handler. That's
fixed, so on Windows you can now handle a stack overflow multiple times.
Great thought has been put into selecting the perfect SIGSTKSZ constants
so you can save sigaltstack() memory. You can now use kprintf() with 512
bytes of stack available. The guard pages beneath the main stack are now
recorded in the memory manager.

This change fixes getcontext() so it works right with the %rax register.
2024-12-27 01:33:00 -08:00
..
accept4_nonblock_test.c Rewrite Windows accept() 2024-09-12 04:23:38 -07:00
accept_inherit_nonblock_test.c Rewrite Windows accept() 2024-09-12 04:23:38 -07:00
accept_poll_test.c Rewrite Windows accept() 2024-09-12 04:23:38 -07:00
atoi_test.c Apply clang-format update to repo (#1154) 2024-04-25 10:38:00 -07:00
BUILD.mk Rewrite Windows accept() 2024-09-12 04:23:38 -07:00
connect_nonblock_test.c Rewrite Windows connect() 2024-09-12 23:07:52 -07:00
cyclic_mutex_test.c Eliminate cyclic locks in runtime 2024-12-16 22:25:12 -08:00
exit_async_signal_safety_test.c Demonstrate signal safety of recursive mutexes 2024-07-04 02:47:52 -07:00
file_offset_exec_prog.c Share file offset across execve() on Windows 2024-08-03 17:48:00 -07:00
file_offset_exec_test.c Make threads faster and more reliable 2024-12-21 22:13:00 -08:00
file_offset_fork_test.c Share file offset across execve() on Windows 2024-08-03 17:48:00 -07:00
fork_bench_test.c Make threads faster and more reliable 2024-12-21 22:13:00 -08:00
fread3gb_test.c Add some noexcept annotations 2024-06-01 03:19:53 -07:00
iconv_utf8_utf16_test.c Update Musl Libc code 2024-07-30 22:51:29 -07:00
iconv_utf8_utf32_test.c Update Musl Libc code 2024-07-30 22:51:29 -07:00
interprocess_signaling_test.c Introduce interprocess signaling on Windows 2024-09-19 03:02:13 -07:00
listen_timeout_test.c Rewrite Windows connect() 2024-09-12 23:07:52 -07:00
lowest_fd_test.c Fix file descriptor assignment issues on Windows 2024-09-15 22:16:38 -07:00
mask_test.c flip et / noet in modelines 2023-12-07 22:17:11 -05:00
msg_nosignal_test.c Make more Windows socket fixes and improvements 2024-09-18 20:29:42 -07:00
msg_waitall_test.c Make more Windows socket fixes and improvements 2024-09-18 20:29:42 -07:00
nonblock_pipe2_test.c Rewrite Windows accept() 2024-09-12 04:23:38 -07:00
nonblock_pipe_test.c Rewrite Windows accept() 2024-09-12 04:23:38 -07:00
pending_signal_execve_test.c Eliminate cyclic locks in runtime 2024-12-16 22:25:12 -08:00
pipe_write_eagain_test.c Write more tests attempting to break windows 2024-09-22 01:21:10 -07:00
printf_return_test.c Make more fixups and quality assurance 2024-10-07 15:29:53 -07:00
pthread_process_shared_test.c Add unit test for process shared conditions 2024-07-22 18:48:54 -07:00
reentrant_signal_test.c Apply clang-format update to repo (#1154) 2024-04-25 10:38:00 -07:00
sa_resethand2_test.c Fix --ftrace on Windows 2024-01-01 00:00:42 -08:00
sa_resethand_test.c Write more tests attempting to break windows 2024-09-22 01:21:10 -07:00
sigchld_test.c Apply clang-format update to repo (#1154) 2024-04-25 10:38:00 -07:00
signal_fight_test.c Write more tests for signal handling 2024-09-21 05:24:56 -07:00
signal_latency_async_test.c Improve memory manager and signal handling 2024-12-27 01:33:00 -08:00
signal_latency_test.c Reduce stack virtual memory consumption on Linux 2024-12-25 20:58:08 -08:00
signal_test.c flip et / noet in modelines 2023-12-07 22:17:11 -05:00
signal_torture_read_test.c Make read() and write() signal handling atomic 2024-09-15 01:18:27 -07:00
socket_fionread_test.c Fix ioctl() and FIONREAD for sockets on Windows 2024-09-13 01:47:33 -07:00
socket_timeout_signal_test.c Reveal another Qemu bug 2024-09-17 01:31:55 -07:00
strtol_test.c Apply clang-format update to repo (#1154) 2024-04-25 10:38:00 -07:00
unnamed_semaphore_test.c Speed up unnamed POSIX semaphores 2024-09-13 06:25:27 -07:00
wait2x_test.c Fix ECHILD with WNOHANG on Windows 2024-09-18 23:26:02 -07:00
writev_test.c Slightly optimize iovec on Windows 2024-09-16 21:36:22 -07:00