summaryrefslogtreecommitdiff
path: root/lib/mlibc/options/internal/x86/setjmp.S
diff options
context:
space:
mode:
authorIan Moffett <ian@osmora.org>2024-03-07 17:28:52 -0500
committerIan Moffett <ian@osmora.org>2024-03-07 18:24:51 -0500
commitf5e48e94a2f4d4bbd6e5628c7f2afafc6dbcc459 (patch)
tree93b156621dc0303816b37f60ba88051b702d92f6 /lib/mlibc/options/internal/x86/setjmp.S
parentbd5969fc876a10b18613302db7087ef3c40f18e1 (diff)
build: Build mlibc + add distclean target
Signed-off-by: Ian Moffett <ian@osmora.org>
Diffstat (limited to 'lib/mlibc/options/internal/x86/setjmp.S')
-rw-r--r--lib/mlibc/options/internal/x86/setjmp.S53
1 files changed, 0 insertions, 53 deletions
diff --git a/lib/mlibc/options/internal/x86/setjmp.S b/lib/mlibc/options/internal/x86/setjmp.S
deleted file mode 100644
index fa6644c..0000000
--- a/lib/mlibc/options/internal/x86/setjmp.S
+++ /dev/null
@@ -1,53 +0,0 @@
-
-.type __setjmp, "function"
-__setjmp:
- mov 4(%esp), %eax # Save argument (buffer) in edi
- mov %ebx, 0x00(%eax)
- mov %ebp, 0x04(%eax)
- mov %esi, 0x08(%eax)
- mov %edi, 0x0c(%eax)
-
- lea 4(%esp), %ecx # esp before return eip is pushed
- mov %ecx, 0x10(%eax)
- mov (%esp), %ecx # Return eip
- mov %ecx, 0x14(%eax)
-
- test %edx, %edx
- jnz 1f
- xor %eax, %eax
- ret
-
-1:
- jmp __sigsetjmp@PLT
-
-.global setjmp
-.type setjmp, "function"
-setjmp:
- xor %edx, %edx
- jmp __setjmp
-
-.global sigsetjmp
-.type sigsetjmp, "function"
-sigsetjmp:
- mov $1, %edx
- jmp __setjmp
-
-.global longjmp
-.type longjmp, "function"
-longjmp:
- mov 4(%esp), %ecx
- mov 0x00(%ecx), %ebx
- mov 0x04(%ecx), %ebp
- mov 0x08(%ecx), %esi
- mov 0x0c(%ecx), %edi
-
- mov 8(%esp), %eax
- test %eax, %eax
- jnz 1f
- inc %eax
-1:
- mov 0x10(%ecx), %esp
- jmp *0x14(%ecx)
-
-.section .note.GNU-stack,"",%progbits
-