summaryrefslogtreecommitdiffstats
path: root/libc-top-half/musl/src/setjmp/s390x
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/setjmp/s390x
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/setjmp/s390x')
-rw-r--r--libc-top-half/musl/src/setjmp/s390x/longjmp.s23
-rw-r--r--libc-top-half/musl/src/setjmp/s390x/setjmp.s25
2 files changed, 48 insertions, 0 deletions
diff --git a/libc-top-half/musl/src/setjmp/s390x/longjmp.s b/libc-top-half/musl/src/setjmp/s390x/longjmp.s
new file mode 100644
index 0000000..b2310f8
--- /dev/null
+++ b/libc-top-half/musl/src/setjmp/s390x/longjmp.s
@@ -0,0 +1,23 @@
+ .global _longjmp
+ .global longjmp
+ .type _longjmp,@function
+ .type longjmp,@function
+_longjmp:
+longjmp:
+
+1:
+ lmg %r6, %r15, 0(%r2)
+
+ ld %f8, 10*8(%r2)
+ ld %f9, 11*8(%r2)
+ ld %f10, 12*8(%r2)
+ ld %f11, 13*8(%r2)
+ ld %f12, 14*8(%r2)
+ ld %f13, 15*8(%r2)
+ ld %f14, 16*8(%r2)
+ ld %f15, 17*8(%r2)
+
+ ltgr %r2, %r3
+ bnzr %r14
+ lhi %r2, 1
+ br %r14
diff --git a/libc-top-half/musl/src/setjmp/s390x/setjmp.s b/libc-top-half/musl/src/setjmp/s390x/setjmp.s
new file mode 100644
index 0000000..afae1b6
--- /dev/null
+++ b/libc-top-half/musl/src/setjmp/s390x/setjmp.s
@@ -0,0 +1,25 @@
+ .global ___setjmp
+ .hidden ___setjmp
+ .global __setjmp
+ .global _setjmp
+ .global setjmp
+ .type __setjmp,@function
+ .type _setjmp,@function
+ .type setjmp,@function
+___setjmp:
+__setjmp:
+_setjmp:
+setjmp:
+ stmg %r6, %r15, 0(%r2)
+
+ std %f8, 10*8(%r2)
+ std %f9, 11*8(%r2)
+ std %f10, 12*8(%r2)
+ std %f11, 13*8(%r2)
+ std %f12, 14*8(%r2)
+ std %f13, 15*8(%r2)
+ std %f14, 16*8(%r2)
+ std %f15, 17*8(%r2)
+
+ lghi %r2, 0
+ br %r14