OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [newlib-1.17.0/] [newlib/] [libc/] [machine/] [hppa/] [setjmp.S] - Blame information for rev 826

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 148 jeremybenn
/* Copyright (c) 1995, 2002 Red Hat Incorporated.
2
 * All rights reserved.
3
 *
4
 * Redistribution and use in source and binary forms, with or without
5
 * modification, are permitted provided that the following conditions are met:
6
 *
7
 *    Redistributions of source code must retain the above copyright
8
 *    notice, this list of conditions and the following disclaimer.
9
 *
10
 *    Redistributions in binary form must reproduce the above copyright
11
 *    notice, this list of conditions and the following disclaimer in the
12
 *    documentation and/or other materials provided with the distribution.
13
 *
14
 *    The name of Red Hat Incorporated may not be used to endorse
15
 *    or promote products derived from this software without specific
16
 *    prior written permission.
17
 *
18
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
19
 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
20
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
21
 * ARE DISCLAIMED.  IN NO EVENT SHALL RED HAT INCORPORATED BE LIABLE FOR ANY
22
 * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
23
 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
24
 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
25
 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
27
 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28
 */
29
 
30
/* Note I don't know an easy way to get the FP version into the
31
   traditional C library and the non-FP version into the soft-float
32
   library.  Maybe we'll have to have -msoft-float trigger something
33
   like -DSOFT_FLOAT if this issue ever arises.  */
34
 
35
#include "DEFS.h"
36
 
37
#if 0
38
        .SPACE $PRIVATE$
39
        .SUBSPA $DATA$,QUAD=1,ALIGN=8,ACCESS=31
40
        .SUBSPA $BSS$,QUAD=1,ALIGN=8,ACCESS=31,ZERO,SORT=82
41
        .SPACE $TEXT$
42
        .SUBSPA $LIT$,QUAD=0,ALIGN=8,ACCESS=44
43
        .SUBSPA $CODE$,QUAD=0,ALIGN=8,ACCESS=44,CODE_ONLY
44
        .IMPORT $global$,DATA
45
        .IMPORT $$dyncall,MILLICODE
46
; gcc_compiled.:
47
#endif
48
        TEXT_SEGMENT
49
 
50
        .align 4
51
        .EXPORT setjmp,ENTRY,PRIV_LEV=3,ARGW0=GR,RTNVAL=GR
52
setjmp
53
        .PROC
54
        .CALLINFO FRAME=64,NO_CALLS,SAVE_SP,ENTRY_GR=3
55
        .ENTRY
56
        stwm  %r30,4(%r26)
57
        stwm  %r2,4(%r26)
58
        stwm  %r3,4(%r26)
59
        stwm  %r4,4(%r26)
60
        stwm  %r5,4(%r26)
61
        stwm  %r6,4(%r26)
62
        stwm  %r7,4(%r26)
63
        stwm  %r8,4(%r26)
64
        stwm  %r9,4(%r26)
65
        stwm  %r10,4(%r26)
66
        stwm  %r11,4(%r26)
67
        stwm  %r12,4(%r26)
68
        stwm  %r13,4(%r26)
69
        stwm  %r14,4(%r26)
70
        stwm  %r15,4(%r26)
71
        stwm  %r16,4(%r26)
72
        stwm  %r17,4(%r26)
73
        stwm  %r18,4(%r26)
74
        stwm  %r27,4(%r26)
75
#ifdef FP
76
        ; jmp_buf may only have a 4 byte alignment, so handle FP stores
77
        ; very carefully.
78
        fstds %fr12,-16(%r30)
79
        ldw -16(%r30),%r28
80
        stwm  %r28,4(%r26)
81
        ldw -12(%r30),%r28
82
        stwm  %r28,4(%r26)
83
        fstds %fr13,-16(%r30)
84
        ldw -16(%r30),%r28
85
        stwm  %r28,4(%r26)
86
        ldw -12(%r30),%r28
87
        stwm  %r28,4(%r26)
88
        fstds %fr14,-16(%r30)
89
        ldw -16(%r30),%r28
90
        stwm  %r28,4(%r26)
91
        ldw -12(%r30),%r28
92
        stwm  %r28,4(%r26)
93
        fstds %fr15,-16(%r30)
94
        ldw -16(%r30),%r28
95
        stwm  %r28,4(%r26)
96
        ldw -12(%r30),%r28
97
        stwm  %r28,4(%r26)
98
#endif
99
 
100
        bv 0(%r2)
101
        copy %r0,%r28
102
        .EXIT
103
        .PROCEND
104
        .align 4
105
        .EXPORT longjmp,ENTRY,PRIV_LEV=3,ARGW0=GR,ARGW1=GR,RTNVAL=GR
106
longjmp
107
        .PROC
108
        .CALLINFO FRAME=64,NO_CALLS,SAVE_SP,ENTRY_GR=3
109
        .ENTRY
110
        ldwm 4(%r26),%r30
111
        ldwm 4(%r26),%r2
112
        ldwm 4(%r26),%r3
113
        ldwm 4(%r26),%r4
114
        ldwm 4(%r26),%r5
115
        ldwm 4(%r26),%r6
116
        ldwm 4(%r26),%r7
117
        ldwm 4(%r26),%r8
118
        ldwm 4(%r26),%r9
119
        ldwm 4(%r26),%r10
120
        ldwm 4(%r26),%r11
121
        ldwm 4(%r26),%r12
122
        ldwm 4(%r26),%r13
123
        ldwm 4(%r26),%r14
124
        ldwm 4(%r26),%r15
125
        ldwm 4(%r26),%r16
126
        ldwm 4(%r26),%r17
127
        ldwm 4(%r26),%r18
128
        ldwm 4(%r26),%r27
129
#ifdef FP
130
        ldwm 4(%r26),%r28
131
        stw %r28,-16(%r30)
132
        ldwm 4(%r26),%r28
133
        stw %r28,-12(%r30)
134
        fldds -16(%r30),%fr12
135
        ldwm 4(%r26),%r28
136
        stw %r28,-16(%r30)
137
        ldwm 4(%r26),%r28
138
        stw %r28,-12(%r30)
139
        fldds -16(%r30),%fr13
140
        ldwm 4(%r26),%r28
141
        stw %r28,-16(%r30)
142
        ldwm 4(%r26),%r28
143
        stw %r28,-12(%r30)
144
        fldds -16(%r30),%fr14
145
        ldwm 4(%r26),%r28
146
        stw %r28,-16(%r30)
147
        ldwm 4(%r26),%r28
148
        stw %r28,-12(%r30)
149
        fldds -16(%r30),%fr15
150
#endif
151
        comclr,<> %r0,%r25,%r0
152
        ldi 1,%r25
153
        bv 0(%r2)
154
        copy %r25,%r28
155
        .EXIT
156
        .PROCEND

powered by: WebSVN 2.1.0

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