diff options
| author | Christian Krinitsin <mail@krinitsin.com> | 2025-07-08 08:55:39 +0000 |
|---|---|---|
| committer | Christian Krinitsin <mail@krinitsin.com> | 2025-07-08 08:55:39 +0000 |
| commit | 1a3c4faf4e0a25ed0b86e8739d5319a634cb9112 (patch) | |
| tree | 90ceb50013ad28bab46e52731ec4ce1e70c32a57 /results/classifier/no-thinking-deepseek-r1:70b/output/syscall/834 | |
| parent | c50b0c4da17b6e83640e4ed2380fffb5f507c846 (diff) | |
| download | qemu-analysis-1a3c4faf4e0a25ed0b86e8739d5319a634cb9112.tar.gz qemu-analysis-1a3c4faf4e0a25ed0b86e8739d5319a634cb9112.zip | |
add deepseek 70b result
Diffstat (limited to 'results/classifier/no-thinking-deepseek-r1:70b/output/syscall/834')
| -rw-r--r-- | results/classifier/no-thinking-deepseek-r1:70b/output/syscall/834 | 62 |
1 files changed, 62 insertions, 0 deletions
diff --git a/results/classifier/no-thinking-deepseek-r1:70b/output/syscall/834 b/results/classifier/no-thinking-deepseek-r1:70b/output/syscall/834 new file mode 100644 index 000000000..99ad9901b --- /dev/null +++ b/results/classifier/no-thinking-deepseek-r1:70b/output/syscall/834 @@ -0,0 +1,62 @@ + + + +linux-user: fails to deliver signals raised during pselect +Description of problem: +When run via qemu a program which blocks signals but unmasks them during `pselect` does not catch these signals when returning from `pselect`. + +Used as reference on expected behavior: [The new pselect() system call](https://lwn.net/Articles/176911/) +Steps to reproduce: +A minimal test case below mimics behavior as encountered in the test suite of `p11-kit` ([link](https://github.com/p11-glue/p11-kit)) (which attempts to catch `SIGTERM` in a similar way and results in lingering processes after running the test suite). + +```C +#include <stdio.h> +#include <unistd.h> +#include <signal.h> +#include <sys/select.h> + +static void handler(int sig) +{ + puts("SIGNAL"); +} + +int main(int argc, char *argv[]) +{ + struct sigaction sa; + + fd_set rfds; + sigset_t emptyset, blockset; + + sigemptyset (&blockset); + sigemptyset (&emptyset); + sigaddset (&blockset, SIGUSR1); + + sa.sa_handler = handler; + sigemptyset(&sa.sa_mask); + sa.sa_flags = 0; + sigaction(SIGUSR1, &sa, NULL); + + sigprocmask (SIG_BLOCK, &blockset, NULL); + + FD_ZERO(&rfds); + + while(1) { + pselect(0, &rfds, NULL, NULL, NULL, &emptyset); + } + + return 0; +} +``` + +Running this without qemu should print _SIGNAL_ when sent `SIGUSR1`: + +``` +$ ./a.out & +[1] 1683587 +$ kill -USR1 %1 +$ SIGNAL +``` + +When run with `qemu-x86_64` however, it does not (also qemu's `-strace` confirms the signal isn't received whereas a strace of qemu shows it's in fact delivered). + +The pselect call itself _is_ interrupted, but the signal goes missing. |