summaryrefslogtreecommitdiff
path: root/src/setjmp/ppc/longjmp.S
blob: df13c7b1540cc5ef1c5e655a672f0a5d6fafe270 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#include <bits/asm.h>
        .global _longjmp
        .global longjmp
        .type   _longjmp,@function
        .type   longjmp,@function
_longjmp:
longjmp:
        cmpi    7, 0, r3, 0
        bne     7, 1f
        addi    r3, r3, 1
1:      lmw     r8, 4(r3)               // load r8-r31
        mr      r6, r4
        mtlr    r11
        mtcr    r12
        mr      r2, r9
        mr      r1, r10
        blr