summaryrefslogtreecommitdiffstats
path: root/libc-top-half/musl/src/signal/i386
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 13:54:38 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 13:54:38 +0000
commit8c1ab65c0f548d20b7f177bdb736daaf603340e1 (patch)
treedf55b7e75bf43f2bf500845b105afe3ac3a5157e /libc-top-half/musl/src/signal/i386
parentInitial commit. (diff)
downloadwasi-libc-8c1ab65c0f548d20b7f177bdb736daaf603340e1.tar.xz
wasi-libc-8c1ab65c0f548d20b7f177bdb736daaf603340e1.zip
Adding upstream version 0.0~git20221206.8b7148f.upstream/0.0_git20221206.8b7148f
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'libc-top-half/musl/src/signal/i386')
-rw-r--r--libc-top-half/musl/src/signal/i386/restore.s14
-rw-r--r--libc-top-half/musl/src/signal/i386/sigsetjmp.s26
2 files changed, 40 insertions, 0 deletions
diff --git a/libc-top-half/musl/src/signal/i386/restore.s b/libc-top-half/musl/src/signal/i386/restore.s
new file mode 100644
index 0000000..ccc9430
--- /dev/null
+++ b/libc-top-half/musl/src/signal/i386/restore.s
@@ -0,0 +1,14 @@
+.global __restore
+.hidden __restore
+.type __restore,@function
+__restore:
+ popl %eax
+ movl $119, %eax
+ int $0x80
+
+.global __restore_rt
+.hidden __restore_rt
+.type __restore_rt,@function
+__restore_rt:
+ movl $173, %eax
+ int $0x80
diff --git a/libc-top-half/musl/src/signal/i386/sigsetjmp.s b/libc-top-half/musl/src/signal/i386/sigsetjmp.s
new file mode 100644
index 0000000..690b251
--- /dev/null
+++ b/libc-top-half/musl/src/signal/i386/sigsetjmp.s
@@ -0,0 +1,26 @@
+.global sigsetjmp
+.global __sigsetjmp
+.type sigsetjmp,@function
+.type __sigsetjmp,@function
+sigsetjmp:
+__sigsetjmp:
+ mov 8(%esp),%ecx
+ jecxz 1f
+
+ mov 4(%esp),%eax
+ popl 24(%eax)
+ mov %ebx,28+8(%eax)
+ mov %eax,%ebx
+
+.hidden ___setjmp
+ call ___setjmp
+
+ pushl 24(%ebx)
+ mov %ebx,4(%esp)
+ mov %eax,8(%esp)
+ mov 28+8(%ebx),%ebx
+
+.hidden __sigsetjmp_tail
+ jmp __sigsetjmp_tail
+
+1: jmp ___setjmp