projects
/
musl
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
Merge remote-tracking branch 'ppc-port/ppc-squashed'
[musl]
/
src
/
setjmp
/
powerpc
/
setjmp.s
1
.global __setjmp
2
.global _setjmp
3
.global setjmp
4
.type __setjmp,@function
5
.type _setjmp,@function
6
.type setjmp,@function
7
__setjmp:
8
_setjmp:
9
setjmp:
10
# 0) store IP int 0, then into the jmpbuf pointed to by r3 (first arg)
11
mflr 0
12
stw 0, 0(3)
13
# 1) store reg1 (SP)
14
stw 1, 4(3)
15
# 2) store cr
16
mfcr 0
17
stw 0, 8(3)
18
# 3) store r14-31
19
stw 14, 12(3)
20
stw 15, 16(3)
21
stw 16, 20(3)
22
stw 17, 24(3)
23
stw 18, 28(3)
24
stw 19, 32(3)
25
stw 20, 36(3)
26
stw 21, 40(3)
27
stw 22, 44(3)
28
stw 23, 48(3)
29
stw 24, 52(3)
30
stw 25, 56(3)
31
stw 26, 60(3)
32
stw 27, 64(3)
33
stw 28, 68(3)
34
stw 29, 72(3)
35
stw 30, 76(3)
36
stw 31, 80(3)
37
# 4) set return value to 0
38
li 3, 0
39
# 5) return
40
blr