OpenCores
URL https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk

Subversion Repositories openrisc_2011-10-31

[/] [openrisc/] [tags/] [gnu-src/] [newlib-1.18.0/] [newlib-1.18.0-or32-1.0rc1/] [newlib/] [libc/] [machine/] [mt/] [setjmp.S] - Diff between revs 207 and 345

Only display areas with differences | Details | Blame | View Log

Rev 207 Rev 345
# setjmp/longjmp for mt.
# setjmp/longjmp for mt.
#
#
# The jmpbuf looks like this:
# The jmpbuf looks like this:
#
#
# Register      jmpbuf offset
# Register      jmpbuf offset
# R0            ---             --
# R0            ---             --
# R1            0x4              4
# R1            0x4              4
# R2            0x8              8
# R2            0x8              8
# R3            0xc             12
# R3            0xc             12
# R4            0x10            16
# R4            0x10            16
# R5            0x14            20
# R5            0x14            20
# R6            0x18            24
# R6            0x18            24
# R7            0x1c            28
# R7            0x1c            28
# R8            0x20            32
# R8            0x20            32
# R9            ----            --
# R9            ----            --
# R10           ----            --
# R10           ----            --
# R11           0x2c            44
# R11           0x2c            44
# R12           0x30            48
# R12           0x30            48
# R13           0x34            52
# R13           0x34            52
# R14           0x38            56
# R14           0x38            56
# R15           0x3c            60
# R15           0x3c            60
#
#
# R1 contains the pointer to jmpbuf
# R1 contains the pointer to jmpbuf
        .text
        .text
        .global setjmp
        .global setjmp
        .type   setjmp ,@function
        .type   setjmp ,@function
setjmp:
setjmp:
        stw     r1, r1, #4
        stw     r1, r1, #4
        or      r0, r0, r0
        or      r0, r0, r0
        stw     r2, r1, #8
        stw     r2, r1, #8
        or      r0, r0, r0
        or      r0, r0, r0
        stw     r3, r1, #12
        stw     r3, r1, #12
        or      r0, r0, r0
        or      r0, r0, r0
        stw     r4, r1, #16
        stw     r4, r1, #16
        or      r0, r0, r0
        or      r0, r0, r0
        stw     r5, r1, #20
        stw     r5, r1, #20
        or      r0, r0, r0
        or      r0, r0, r0
        stw     r6, r1, #24
        stw     r6, r1, #24
        or      r0, r0, r0
        or      r0, r0, r0
        stw     r7, r1, #28
        stw     r7, r1, #28
        or      r0, r0, r0
        or      r0, r0, r0
        stw     r8, r1, #32
        stw     r8, r1, #32
        or      r0, r0, r0
        or      r0, r0, r0
        stw     r11, r1, #44
        stw     r11, r1, #44
        or      r0, r0, r0
        or      r0, r0, r0
        stw     r12, r1, #48
        stw     r12, r1, #48
        or      r0, r0, r0
        or      r0, r0, r0
        stw     r13, r1, #52
        stw     r13, r1, #52
        or      r0, r0, r0
        or      r0, r0, r0
        stw     r14, r1, #56
        stw     r14, r1, #56
        or      r0, r0, r0
        or      r0, r0, r0
        stw     r15, r1, #60
        stw     r15, r1, #60
        jal     r0, r14
        jal     r0, r14
        addi    r11, r0, #0
        addi    r11, r0, #0
.Lend1:
.Lend1:
        .size   setjmp,.Lend1-setjmp
        .size   setjmp,.Lend1-setjmp
        .global longjmp
        .global longjmp
        .type   longjmp,@function
        .type   longjmp,@function
longjmp:
longjmp:
        or      r9, r1, r1
        or      r9, r1, r1
        or      r11, r2, r2
        or      r11, r2, r2
        ldw     r1, r1, #4
        ldw     r1, r1, #4
        or      r0, r0, r0
        or      r0, r0, r0
        ldw     r2, r1, #8
        ldw     r2, r1, #8
        or      r0, r0, r0
        or      r0, r0, r0
        ldw     r3, r1, #12
        ldw     r3, r1, #12
        or      r0, r0, r0
        or      r0, r0, r0
        ldw     r4, r1, #16
        ldw     r4, r1, #16
        or      r0, r0, r0
        or      r0, r0, r0
        ldw     r5, r1, #20
        ldw     r5, r1, #20
        or      r0, r0, r0
        or      r0, r0, r0
        ldw     r6, r1, #24
        ldw     r6, r1, #24
        or      r0, r0, r0
        or      r0, r0, r0
        ldw     r7, r1, #28
        ldw     r7, r1, #28
        or      r0, r0, r0
        or      r0, r0, r0
        ldw     r8, r1, #32
        ldw     r8, r1, #32
        or      r0, r0, r0
        or      r0, r0, r0
        ldw     r12, r1, #48
        ldw     r12, r1, #48
        or      r0, r0, r0
        or      r0, r0, r0
        ldw     r13, r1, #52
        ldw     r13, r1, #52
        or      r0, r0, r0
        or      r0, r0, r0
        ldw     r14, r1, #56
        ldw     r14, r1, #56
        or      r0, r0, r0
        or      r0, r0, r0
        ldw     r15, r1, #60
        ldw     r15, r1, #60
        brne    r0, r11, .L01
        brne    r0, r11, .L01
        or      r0, r0, r0
        or      r0, r0, r0
        addi    r11, r0, #1
        addi    r11, r0, #1
.L01:
.L01:
        jal     r0, r14
        jal     r0, r14
        or      r0, r0, r0
        or      r0, r0, r0
.Lend2:
.Lend2:
        .size   longjmp,.Lend2-longjmp2
        .size   longjmp,.Lend2-longjmp2
 
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.