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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [newlib-1.17.0/] [newlib/] [libc/] [sys/] [sh/] [trap.S] - Blame information for rev 816

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 148 jeremybenn
#if __SH5__
2
        .mode   SHmedia
3
#if __SH5__ == 32 && __SHMEDIA__
4
        .section        .text..SHmedia32, "ax"
5
#else
6
        .text
7
#endif
8
        .global ___trap34
9
___trap34:
10
        movi    34, r0
11
        trapa   r0
12
        pt/l    ret, tr1
13
        ptabs/l r18, tr0
14
        beqi    r1, 0, tr1
15
#if __SH5__ == 64
16
        movi    ((_errno >> 48) & 65535), r0
17
        shori   ((_errno >> 32) & 65535), r0
18
        shori   ((_errno >> 16) & 65535), r0
19
#else
20
        movi    ((_errno >> 16) & 65535), r0
21
#endif
22
        shori   (_errno & 65535), r0
23
        stx.l   r0, r63, r1
24
ret:
25
        blink   tr0, r63
26
 
27
#else
28
        .text
29
        .global ___trap34
30
___trap34:
31
        trapa   #34
32
        tst     r1,r1   ! r1 is errno
33
        bt      ret
34
        mov.l   perrno,r2
35
        mov.l   r1,@r2
36
ret:
37
        rts
38
        nop
39
 
40
        .align  2
41
perrno:
42
        .long   _errno
43
#endif /* ! __SH5__ */

powered by: WebSVN 2.1.0

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