Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(239)

Unified Diff: fusl/src/setjmp/powerpc/setjmp.s

Issue 1573973002: Add a "fork" of musl as //fusl. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « fusl/src/setjmp/powerpc/longjmp.s ('k') | fusl/src/setjmp/setjmp.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: fusl/src/setjmp/powerpc/setjmp.s
diff --git a/fusl/src/setjmp/powerpc/setjmp.s b/fusl/src/setjmp/powerpc/setjmp.s
new file mode 100644
index 0000000000000000000000000000000000000000..122177f142b670b3452b77b5b5783bc137e4f573
--- /dev/null
+++ b/fusl/src/setjmp/powerpc/setjmp.s
@@ -0,0 +1,61 @@
+ .global ___setjmp
+ .hidden ___setjmp
+ .global __setjmp
+ .global _setjmp
+ .global setjmp
+ .type __setjmp,@function
+ .type _setjmp,@function
+ .type setjmp,@function
+___setjmp:
+__setjmp:
+_setjmp:
+setjmp:
+ # 0) store IP int 0, then into the jmpbuf pointed to by r3 (first arg)
+ mflr 0
+ stw 0, 0(3)
+ # 1) store reg1 (SP)
+ stw 1, 4(3)
+ # 2) store cr
+ mfcr 0
+ stw 0, 8(3)
+ # 3) store r14-31
+ stw 14, 12(3)
+ stw 15, 16(3)
+ stw 16, 20(3)
+ stw 17, 24(3)
+ stw 18, 28(3)
+ stw 19, 32(3)
+ stw 20, 36(3)
+ stw 21, 40(3)
+ stw 22, 44(3)
+ stw 23, 48(3)
+ stw 24, 52(3)
+ stw 25, 56(3)
+ stw 26, 60(3)
+ stw 27, 64(3)
+ stw 28, 68(3)
+ stw 29, 72(3)
+ stw 30, 76(3)
+ stw 31, 80(3)
+ stfd 14,88(3)
+ stfd 15,96(3)
+ stfd 16,104(3)
+ stfd 17,112(3)
+ stfd 18,120(3)
+ stfd 19,128(3)
+ stfd 20,136(3)
+ stfd 21,144(3)
+ stfd 22,152(3)
+ stfd 23,160(3)
+ stfd 24,168(3)
+ stfd 25,176(3)
+ stfd 26,184(3)
+ stfd 27,192(3)
+ stfd 28,200(3)
+ stfd 29,208(3)
+ stfd 30,216(3)
+ stfd 31,224(3)
+ # 4) set return value to 0
+ li 3, 0
+ # 5) return
+ blr
« no previous file with comments | « fusl/src/setjmp/powerpc/longjmp.s ('k') | fusl/src/setjmp/setjmp.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698