Initial revision
[binutils.git] / include / coff / symconst.h
blobf40eef2a3115686050fd0e6fc7e273284d9f946a
1 /* Declarations of constants for internal format of MIPS ECOFF symbols.
2 Originally contributed by MIPS Computer Systems and Third Eye Software.
3 Changes contributed by Cygnus Support are in the public domain.
5 This file is just aggregated with the files that make up the GNU
6 release; it is not considered part of GAS, GDB, or other GNU
7 programs. */
9 /*
10 * |-----------------------------------------------------------|
11 * | Copyright (c) 1992, 1991, 1990 MIPS Computer Systems, Inc.|
12 * | MIPS Computer Systems, Inc. grants reproduction and use |
13 * | rights to all parties, PROVIDED that this comment is |
14 * | maintained in the copy. |
15 * |-----------------------------------------------------------|
18 /* (C) Copyright 1984 by Third Eye Software, Inc.
20 * Third Eye Software, Inc. grants reproduction and use rights to
21 * all parties, PROVIDED that this comment is maintained in the copy.
23 * Third Eye makes no claims about the applicability of this
24 * symbol table to a particular use.
27 /* glevels for field in FDR */
28 #define GLEVEL_0 2
29 #define GLEVEL_1 1
30 #define GLEVEL_2 0 /* for upward compat reasons. */
31 #define GLEVEL_3 3
33 /* magic number fo symheader */
34 #define magicSym 0x7009
35 /* The Alpha uses this value instead, for some reason. */
36 #define magicSym2 0x1992
38 /* Language codes */
39 #define langC 0
40 #define langPascal 1
41 #define langFortran 2
42 #define langAssembler 3 /* one Assembley inst might map to many mach */
43 #define langMachine 4
44 #define langNil 5
45 #define langAda 6
46 #define langPl1 7
47 #define langCobol 8
48 #define langStdc 9 /* FIXME: Collides with SGI langCplusplus */
49 #define langCplusplus 9 /* FIXME: Collides with langStdc */
50 #define langCplusplusV2 10 /* SGI addition */
51 #define langMax 11 /* maximun allowed 32 -- 5 bits */
53 /* The following are value definitions for the fields in the SYMR */
56 * Storage Classes
59 #define scNil 0
60 #define scText 1 /* text symbol */
61 #define scData 2 /* initialized data symbol */
62 #define scBss 3 /* un-initialized data symbol */
63 #define scRegister 4 /* value of symbol is register number */
64 #define scAbs 5 /* value of symbol is absolute */
65 #define scUndefined 6 /* who knows? */
66 #define scCdbLocal 7 /* variable's value is IN se->va.?? */
67 #define scBits 8 /* this is a bit field */
68 #define scCdbSystem 9 /* variable's value is IN CDB's address space */
69 #define scDbx 9 /* overlap dbx internal use */
70 #define scRegImage 10 /* register value saved on stack */
71 #define scInfo 11 /* symbol contains debugger information */
72 #define scUserStruct 12 /* address in struct user for current process */
73 #define scSData 13 /* load time only small data */
74 #define scSBss 14 /* load time only small common */
75 #define scRData 15 /* load time only read only data */
76 #define scVar 16 /* Var parameter (fortran,pascal) */
77 #define scCommon 17 /* common variable */
78 #define scSCommon 18 /* small common */
79 #define scVarRegister 19 /* Var parameter in a register */
80 #define scVariant 20 /* Variant record */
81 #define scSUndefined 21 /* small undefined(external) data */
82 #define scInit 22 /* .init section symbol */
83 #define scBasedVar 23 /* Fortran or PL/1 ptr based var */
84 #define scXData 24 /* exception handling data */
85 #define scPData 25 /* Procedure section */
86 #define scFini 26 /* .fini section */
87 #define scRConst 27 /* .rconst section */
88 #define scMax 32
92 * Symbol Types
95 #define stNil 0 /* Nuthin' special */
96 #define stGlobal 1 /* external symbol */
97 #define stStatic 2 /* static */
98 #define stParam 3 /* procedure argument */
99 #define stLocal 4 /* local variable */
100 #define stLabel 5 /* label */
101 #define stProc 6 /* " " Procedure */
102 #define stBlock 7 /* beginnning of block */
103 #define stEnd 8 /* end (of anything) */
104 #define stMember 9 /* member (of anything - struct/union/enum */
105 #define stTypedef 10 /* type definition */
106 #define stFile 11 /* file name */
107 #define stRegReloc 12 /* register relocation */
108 #define stForward 13 /* forwarding address */
109 #define stStaticProc 14 /* load time only static procs */
110 #define stConstant 15 /* const */
111 #define stStaParam 16 /* Fortran static parameters */
112 /* These new symbol types have been recently added to SGI machines. */
113 #define stStruct 26 /* Beginning of block defining a struct type */
114 #define stUnion 27 /* Beginning of block defining a union type */
115 #define stEnum 28 /* Beginning of block defining an enum type */
116 #define stIndirect 34 /* Indirect type specification */
117 /* Pseudo-symbols - internal to debugger */
118 #define stStr 60 /* string */
119 #define stNumber 61 /* pure number (ie. 4 NOR 2+2) */
120 #define stExpr 62 /* 2+2 vs. 4 */
121 #define stType 63 /* post-coersion SER */
122 #define stMax 64
124 /* definitions for fields in TIR */
126 /* type qualifiers for ti.tq0 -> ti.(itqMax-1) */
127 #define tqNil 0 /* bt is what you see */
128 #define tqPtr 1 /* pointer */
129 #define tqProc 2 /* procedure */
130 #define tqArray 3 /* duh */
131 #define tqFar 4 /* longer addressing - 8086/8 land */
132 #define tqVol 5 /* volatile */
133 #define tqConst 6 /* const */
134 #define tqMax 8
136 /* basic types as seen in ti.bt */
137 #define btNil 0 /* undefined (also, enum members) */
138 #define btAdr 1 /* address - integer same size as pointer */
139 #define btChar 2 /* character */
140 #define btUChar 3 /* unsigned character */
141 #define btShort 4 /* short */
142 #define btUShort 5 /* unsigned short */
143 #define btInt 6 /* int */
144 #define btUInt 7 /* unsigned int */
145 #define btLong 8 /* long */
146 #define btULong 9 /* unsigned long */
147 #define btFloat 10 /* float (real) */
148 #define btDouble 11 /* Double (real) */
149 #define btStruct 12 /* Structure (Record) */
150 #define btUnion 13 /* Union (variant) */
151 #define btEnum 14 /* Enumerated */
152 #define btTypedef 15 /* defined via a typedef, isymRef points */
153 #define btRange 16 /* subrange of int */
154 #define btSet 17 /* pascal sets */
155 #define btComplex 18 /* fortran complex */
156 #define btDComplex 19 /* fortran double complex */
157 #define btIndirect 20 /* forward or unnamed typedef */
158 #define btFixedDec 21 /* Fixed Decimal */
159 #define btFloatDec 22 /* Float Decimal */
160 #define btString 23 /* Varying Length Character String */
161 #define btBit 24 /* Aligned Bit String */
162 #define btPicture 25 /* Picture */
163 #define btVoid 26 /* void */
164 #define btLongLong 27 /* long long */
165 #define btULongLong 28 /* unsigned long long */
166 #define btMax 64
168 #if (_MFG == _MIPS)
169 /* optimization type codes */
170 #define otNil 0
171 #define otReg 1 /* move var to reg */
172 #define otBlock 2 /* begin basic block */
173 #define otProc 3 /* procedure */
174 #define otInline 4 /* inline procedure */
175 #define otEnd 5 /* whatever you started */
176 #define otMax 6 /* KEEP UP TO DATE */
177 #endif /* (_MFG == _MIPS) */