cosmopolitan/test/libc/calls
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
..
access_test.c Delete ASAN 2024-06-22 05:45:49 -07:00
BUILD.mk Implement proper time zone support 2024-05-04 23:06:37 -07:00
cachestat_test.c Build tool for hunting down flakes 2024-12-24 11:36:16 -08:00
chdir_test.c Delete ASAN 2024-06-22 05:45:49 -07:00
clock_getres_test.c Delve into clock rabbit hole 2024-09-04 01:32:46 -07:00
clock_gettime_test.c Delve into clock rabbit hole 2024-09-04 01:32:46 -07:00
clock_nanosleep_test.c Get rid of .internal.h convention in LIBC_INTRIN 2024-07-19 19:38:00 -07:00
closefrom_test.c Apply clang-format update to repo (#1154) 2024-04-25 10:38:00 -07:00
commandv_test.c Introduce sigtimedwait() on Windows 2024-09-15 01:18:27 -07:00
copy_file_range_test.c Apply clang-format update to repo (#1154) 2024-04-25 10:38:00 -07:00
devfd_test.c Get rid of .internal.h convention in LIBC_INTRIN 2024-07-19 19:38:00 -07:00
dup_test.c Release Cosmopolitan v3.3 2024-02-20 13:27:59 -08:00
fchdir_test.c Bring back gc() function 2024-01-08 10:26:28 -08:00
fchmodat_test.c Remove .internal from more header filenames 2024-08-04 12:52:25 -07:00
fcntl_test.c Remove .internal from more header filenames 2024-08-04 12:52:25 -07:00
fileexists_test.c flip et / noet in modelines 2023-12-07 22:17:11 -05:00
ftruncate_test.c Get rid of .internal.h convention in LIBC_INTRIN 2024-07-19 19:38:00 -07:00
getcontext_test.c Improve memory manager and signal handling 2024-12-27 01:33:00 -08:00
getcwd_test.c Remove .internal from more header filenames 2024-08-04 12:52:25 -07:00
getgroups_test.c Remove .internal from more header filenames 2024-08-04 12:52:25 -07:00
getitimer_test.c Implement proper time zone support 2024-05-04 23:06:37 -07:00
getprogramexecutablename_test.c Apply clang-format update to repo (#1154) 2024-04-25 10:38:00 -07:00
getrandom_test.c Introduce sigtimedwait() on Windows 2024-09-15 01:18:27 -07:00
ioctl_test.c Apply clang-format update to repo (#1154) 2024-04-25 10:38:00 -07:00
life.c flip et / noet in modelines 2023-12-07 22:17:11 -05:00
lock2_test.c flip et / noet in modelines 2023-12-07 22:17:11 -05:00
lock_ofd_test.c Remove .internal from more header filenames 2024-08-04 12:52:25 -07:00
lock_test.c Remove .internal from more header filenames 2024-08-04 12:52:25 -07:00
lseek_test.c Share file offset across execve() on Windows 2024-08-03 17:48:00 -07:00
madvise_test.c Use better memory strategy on Windows 2024-07-20 02:20:03 -07:00
makedirs_test.c Apply clang-format update to repo (#1154) 2024-04-25 10:38:00 -07:00
mkdir_test.c Fix remove() directory on Windows 2024-07-28 17:31:21 -07:00
mkntcmdline_test.c Support shebang on Windows 2024-05-20 22:11:42 -07:00
mkntenvblock_test.c Bring back gc() function 2024-01-08 10:26:28 -08:00
mkntpath_test.c Fix relative Windows path normalization (#1261) 2024-08-16 11:55:49 -07:00
open_test.c Remove .internal from more header filenames 2024-08-04 12:52:25 -07:00
openatemp_test.c Apply clang-format update to repo (#1154) 2024-04-25 10:38:00 -07:00
openbsd_test.c Apply clang-format update to repo (#1154) 2024-04-25 10:38:00 -07:00
pipe_test.c Apply clang-format update to repo (#1154) 2024-04-25 10:38:00 -07:00
pledge2_test.c Get rid of .internal.h convention in LIBC_INTRIN 2024-07-19 19:38:00 -07:00
pledge_test.c Eliminate cyclic locks in runtime 2024-12-16 22:25:12 -08:00
poll_latency_test.c Reduce latency of poll() on Windows 2024-09-10 04:12:21 -07:00
poll_test.c Fix polling of files on Windows 2024-09-11 17:13:23 -07:00
posix_fadvise_test.c Apply clang-format update to repo (#1154) 2024-04-25 10:38:00 -07:00
pread_test.c flip et / noet in modelines 2023-12-07 22:17:11 -05:00
preadv_test.c flip et / noet in modelines 2023-12-07 22:17:11 -05:00
raise_test.c Build tool for hunting down flakes 2024-12-24 11:36:16 -08:00
read_test.c Apply clang-format update to repo (#1154) 2024-04-25 10:38:00 -07:00
readansi_test.c Implement proper time zone support 2024-05-04 23:06:37 -07:00
readlinkat_test.c Fix bug with realpath() on Windows 2024-05-29 18:47:01 -07:00
readwrite_test.c flip et / noet in modelines 2023-12-07 22:17:11 -05:00
renameat_test.c Apply clang-format update to repo (#1154) 2024-04-25 10:38:00 -07:00
reservefd_test.c Remove .internal from more header filenames 2024-08-04 12:52:25 -07:00
sched_setscheduler_test.c Apply clang-format update to repo (#1154) 2024-04-25 10:38:00 -07:00
seccomp_test.c flip et / noet in modelines 2023-12-07 22:17:11 -05:00
select_test.c Fix bugs in poll(), select(), ppoll(), and pselect() 2024-09-02 00:29:52 -07:00
setrlimit_test.c Get rid of .internal.h convention in LIBC_INTRIN 2024-07-19 19:38:00 -07:00
shm_open_test.c Build tool for hunting down flakes 2024-12-24 11:36:16 -08:00
sig_test.c Apply clang-format update to repo (#1154) 2024-04-25 10:38:00 -07:00
sigaction_test.c Improve memory manager and signal handling 2024-12-27 01:33:00 -08:00
sigaltstack_test.c Improve memory manager and signal handling 2024-12-27 01:33:00 -08:00
sigbus_test.c Simplify memory manager 2024-07-05 05:47:15 -07:00
signal_test.c Favor siginfo_t over struct siginfo 2024-05-28 02:34:17 -07:00
sigpending_test.c flip et / noet in modelines 2023-12-07 22:17:11 -05:00
sigprocmask_test.c Avoid linker conflicts on DescribeFoo symbols 2024-08-24 18:10:22 -07:00
sigsuspend_test.c Introduce interprocess signaling on Windows 2024-09-19 03:02:13 -07:00
sigtimedwait_test.c Introduce sigtimedwait() on Windows 2024-09-15 01:18:27 -07:00
specialfile_test.c Add /dev/(u)random on NT (#1163) 2024-05-03 07:59:51 -07:00
splice_test.c flip et / noet in modelines 2023-12-07 22:17:11 -05:00
stackoverflow1_test.c Improve memory manager and signal handling 2024-12-27 01:33:00 -08:00
stackoverflow2_test.c Improve memory manager and signal handling 2024-12-27 01:33:00 -08:00
stackoverflow3_test.c Improve memory manager and signal handling 2024-12-27 01:33:00 -08:00
stackoverflow4_test.c Improve memory manager and signal handling 2024-12-27 01:33:00 -08:00
stackoverflow5_test.c Improve memory manager and signal handling 2024-12-27 01:33:00 -08:00
stat_test.c Bring back gc() function 2024-01-08 10:26:28 -08:00
statfs_test.c flip et / noet in modelines 2023-12-07 22:17:11 -05:00
symlinkat_test.c flip et / noet in modelines 2023-12-07 22:17:11 -05:00
timespec_test.c Apply clang-format update to repo (#1154) 2024-04-25 10:38:00 -07:00
tiny64.elf Bump support up to FreeBSD 13 and NetBSD 9.2 2022-06-11 10:36:17 -07:00
unlinkat_test.c Delete ASAN 2024-06-22 05:45:49 -07:00
unveil_test.c Make realloc() go 100x faster on Linux/NetBSD 2024-07-07 12:40:30 -07:00
utimensat_test.c Implement proper time zone support 2024-05-04 23:06:37 -07:00
vfork_test.c flip et / noet in modelines 2023-12-07 22:17:11 -05:00
write_test.c Delete ASAN 2024-06-22 05:45:49 -07:00
writev_test.c Remove .internal from more header filenames 2024-08-04 12:52:25 -07:00
zipread.c flip et / noet in modelines 2023-12-07 22:17:11 -05:00