Commit Graph

1925 Commits

Author SHA1 Message Date
4lDO2 2d50055dfb WIP: support thread/process-specific kill. 2024-07-17 15:29:05 +02:00
4lDO2 3c540efb00 Support sending signals to individual threads. 2024-07-16 22:06:21 +02:00
4lDO2 8de850e7e9 Ensure all threads stop in exit(). 2024-07-16 20:33:37 +02:00
4lDO2 79bbf79656 Fix some proc scheme FIXMEs. 2024-07-16 20:28:17 +02:00
4lDO2 cc465c008b Remove rustc hack. 2024-07-16 19:52:18 +02:00
4lDO2 bda12fe55e Print MXCSR in the SIMD exception handler. 2024-07-16 13:14:42 +02:00
4lDO2 cde108439c Fix kill deadlock. 2024-07-16 13:05:42 +02:00
4lDO2 6bd01513c5 Simplify and improve thread/process cleanup. 2024-07-15 18:08:43 +02:00
4lDO2 a3dedb0639 Do proper resource cleanup for thread exit too. 2024-07-15 18:08:43 +02:00
4lDO2 8259ed281c Boot to desktop with process/context changes. 2024-07-15 18:08:43 +02:00
4lDO2 40f5c01586 Flatten syscall match statement. 2024-07-15 18:08:43 +02:00
4lDO2 e67c040f69 WIP: Separate process status from context status. 2024-07-15 18:08:43 +02:00
4lDO2 7fbe5c72e9 Use strong references in context set. 2024-07-15 18:08:42 +02:00
4lDO2 80fe891c6e WIP: Replace ContextId with direct Arcs. 2024-07-15 18:08:42 +02:00
4lDO2 038ff03996 Fix waitpid and improve debug. 2024-07-15 18:08:42 +02:00
4lDO2 0de23a1141 Use correct context for proc scheme 'new-thread'. 2024-07-15 18:08:42 +02:00
4lDO2 4202bc3ba0 WIP: add new-thread 2024-07-15 18:08:42 +02:00
4lDO2 208d74899a Fix fork & process creation, now boots to desktop. 2024-07-15 18:08:42 +02:00
4lDO2 25974bec6e It compiles. 2024-07-15 18:08:42 +02:00
4lDO2 de1bd46c84 Make proc scheme almost compile. 2024-07-15 18:08:42 +02:00
4lDO2 89d532a267 Fix half of proc scheme errors. 2024-07-15 18:08:42 +02:00
4lDO2 89d1d49a4e Fix most code except proc scheme. 2024-07-15 18:08:41 +02:00
4lDO2 8f452b0b0f WIP: continue the process transition 2024-07-15 18:08:41 +02:00
4lDO2 0da2fce64a Separate context and process IDs. 2024-07-15 18:08:41 +02:00
4lDO2 74b824f40f Add rustfmt to CI. 2024-07-15 17:54:27 +02:00
4lDO2 d94baa2712 Run rustfmt. 2024-07-15 17:50:18 +02:00
4lDO2 f3532f4549 Fix static mut ref warnings. 2024-07-15 17:48:46 +02:00
4lDO2 5e7db80285 Fix a bunch of warnings. 2024-07-15 17:48:45 +02:00
4lDO2 c86f107344 Switch back to upstream syscall submodule. 2024-07-15 17:20:58 +02:00
4lDO2 9259a36f5e Run more of sigchld test correctly. 2024-07-15 17:20:58 +02:00
4lDO2 5abbcd8e34 Send SIGCHLD to parent after child stop/exit. 2024-07-15 17:20:57 +02:00
4lDO2 d70ad544e6 Fix SIGKILL and allow SYS_EXIT to pass 16 bits. 2024-07-15 17:20:57 +02:00
4lDO2 8f3e40a99e Fix aarch64 compilation. 2024-07-15 17:20:57 +02:00
4lDO2 465128da26 Don't block nanosleep/futex <= signals are pending. 2024-07-15 17:20:57 +02:00
4lDO2 9198ee7e52 Reimplement shutdown and restart. 2024-07-15 17:20:57 +02:00
4lDO2 4dba818c83 Check pending unblocked signals before blocking.
This is not a perfect solution, since the kernel technically already has
all the information it needs to synchronize this between the kill()
invocation and the time WaitCondition::wait is called, but it should not
have any noticeable performance impact.
2024-07-15 17:20:57 +02:00
4lDO2 e9de24c097 Only return EINTR in kill() if self was killed. 2024-07-15 17:20:57 +02:00
4lDO2 965f5879b7 Never clear sig pending bits in the kernel. 2024-07-15 17:20:57 +02:00
4lDO2 ae8e13525f Remove is_pending flag, read word directly instead. 2024-07-15 17:20:57 +02:00
4lDO2 f91b90445d Force userspace to do post-syscall EINTR check. 2024-07-15 17:20:56 +02:00
4lDO2 e8060b259d Only save ip and 'archdep' regs when signalling. 2024-07-15 17:20:56 +02:00
4lDO2 12cfcfc6f2 TMP: change syscall gitmodule to fork 2024-07-15 17:20:56 +02:00
4lDO2 93a3401df4 Fix bug causing raise() to not deliver any signals. 2024-07-15 17:20:56 +02:00
4lDO2 13720f59d5 Make signals masked when clear rather than set. 2024-07-15 17:20:56 +02:00
4lDO2 87046b77c7 Compile on aarch64. 2024-07-15 17:20:56 +02:00
4lDO2 c1ce1d76f9 Compile on i686. 2024-07-15 17:20:56 +02:00
4lDO2 5b25e2cda7 Fix excp_handler deadlock. 2024-07-15 17:20:56 +02:00
4lDO2 b94904a660 Use correct addrsp when setting sighandler. 2024-07-15 17:20:56 +02:00
4lDO2 cc406804c0 Don't double-clear is_pending flag. 2024-07-15 17:20:55 +02:00
4lDO2 35aa24800b Implement correct context sig unblocking behavior. 2024-07-15 17:20:55 +02:00