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

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [config/] [mmix/] [crtn.asm] - Blame information for rev 414

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

Line No. Rev Author Line
1 282 jeremybenn
/* Copyright (C) 2001, 2002, 2009 Free Software Foundation, Inc.
2
   Contributed by Hans-Peter Nilsson 
3
 
4
This file is free software; you can redistribute it and/or modify it
5
under the terms of the GNU General Public License as published by the
6
Free Software Foundation; either version 3, or (at your option) any
7
later version.
8
 
9
This file is distributed in the hope that it will be useful, but
10
WITHOUT ANY WARRANTY; without even the implied warranty of
11
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
12
General Public License for more details.
13
 
14
Under Section 7 of GPL version 3, you are granted additional
15
permissions described in the GCC Runtime Library Exception, version
16
3.1, as published by the Free Software Foundation.
17
 
18
You should have received a copy of the GNU General Public License and
19
a copy of the GCC Runtime Library Exception along with this program;
20
see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
21
.  */
22
 
23
% This must be the last file on the link-line, allocating global registers
24
% from the top.
25
 
26
% Register $254 is the stack-pointer.
27
sp GREG
28
 
29
% Register $253 is frame-pointer.  It's not supposed to be used in most
30
% functions.
31
fp GREG
32
 
33
% $252 is the static chain register; nested functions receive the
34
% context of the surrounding function through a pointer passed in this
35
% register.
36
static_chain GREG
37
struct_value_reg GREG
38
 
39
% These registers are used to pass state at an exceptional return (C++).
40
eh_state_3 GREG
41
eh_state_2 GREG
42
eh_state_1 GREG
43
eh_state_0 GREG
44
 
45
#ifdef __MMIX_ABI_GNU__
46
 
47
% Allocate global registers used by the GNU ABI.
48
gnu_parm_reg_16 GREG
49
gnu_parm_reg_15 GREG
50
gnu_parm_reg_14 GREG
51
gnu_parm_reg_13 GREG
52
gnu_parm_reg_12 GREG
53
gnu_parm_reg_11 GREG
54
gnu_parm_reg_10 GREG
55
gnu_parm_reg_9 GREG
56
gnu_parm_reg_8 GREG
57
gnu_parm_reg_7 GREG
58
gnu_parm_reg_6 GREG
59
gnu_parm_reg_5 GREG
60
gnu_parm_reg_4 GREG
61
gnu_parm_reg_3 GREG
62
gnu_parm_reg_2 GREG
63
gnu_parm_reg_1 GREG
64
 
65
#endif /* __MMIX_ABI_GNU__ */
66
 
67
% Provide last part of _init and _fini.
68
 
69
% The return address is stored in the topmost stored register in the
70
% register-stack.  We ignore the current value in rJ.  It is probably
71
% garbage because each fragment of _init and _fini may have their own idea
72
% of the current stack frame, if they're cut out from a "real" function
73
% like in gcc/crtstuff.c.
74
 
75
        .section .init,"ax",@progbits
76
        GETA    $255,0F
77
        PUT     rJ,$255
78
        POP     0,0
79
0H      PUT     rJ,$0
80
        POP     0,0
81
 
82
        .section .fini,"ax",@progbits
83
        GETA    $255,0F
84
        PUT     rJ,$255
85
        POP     0,0
86
0H      PUT     rJ,$0
87
        POP     0,0

powered by: WebSVN 2.1.0

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