Deleted Added
sdiff udiff text old ( 2632:1bb2f91485ea ) new ( 2665:a124942bacb8 )
full compact
1/*
2 * Copyright (c) 2003-2005 The Regents of The University of Michigan
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are
7 * met: redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer;
9 * redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the
11 * documentation and/or other materials provided with the distribution;
12 * neither the name of the copyright holders nor the names of its
13 * contributors may be used to endorse or promote products derived from
14 * this software without specific prior written permission.
15 *
16 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
17 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
18 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
19 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
20 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
21 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
22 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
23 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
24 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
26 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27 */
28
29#include "arch/alpha/osfpal.hh"
30
31namespace {
32 const char *strings[PAL::NumCodes] = {
33 // Priviledged PAL instructions
34 "halt", // 0x00
35 "cflush", // 0x01
36 "draina", // 0x02
37 0, // 0x03
38 0, // 0x04
39 0, // 0x05
40 0, // 0x06
41 0, // 0x07
42 0, // 0x08
43 "cserve", // 0x09
44 "swppal", // 0x0a
45 0, // 0x0b
46 0, // 0x0c
47 "wripir", // 0x0d
48 0, // 0x0e
49 0, // 0x0f
50 "rdmces", // 0x10
51 "wrmces", // 0x11
52 0, // 0x12
53 0, // 0x13
54 0, // 0x14
55 0, // 0x15
56 0, // 0x16
57 0, // 0x17
58 0, // 0x18
59 0, // 0x19
60 0, // 0x1a
61 0, // 0x1b
62 0, // 0x1c
63 0, // 0x1d
64 0, // 0x1e
65 0, // 0x1f
66 0, // 0x20
67 0, // 0x21
68 0, // 0x22
69 0, // 0x23
70 0, // 0x24
71 0, // 0x25
72 0, // 0x26
73 0, // 0x27
74 0, // 0x28
75 0, // 0x29
76 0, // 0x2a
77 "wrfen", // 0x2b
78 0, // 0x2c
79 "wrvptptr", // 0x2d
80 0, // 0x2e
81 0, // 0x2f
82 "swpctx", // 0x30
83 "wrval", // 0x31
84 "rdval", // 0x32
85 "tbi", // 0x33
86 "wrent", // 0x34
87 "swpipl", // 0x35
88 "rdps", // 0x36
89 "wrkgp", // 0x37
90 "wrusp", // 0x38
91 "wrperfmon", // 0x39
92 "rdusp", // 0x3a
93 0, // 0x3b
94 "whami", // 0x3c
95 "retsys", // 0x3d
96 "wtint", // 0x3e
97 "rti", // 0x3f
98 0, // 0x40
99 0, // 0x41
100 0, // 0x42
101 0, // 0x43
102 0, // 0x44
103 0, // 0x45
104 0, // 0x46
105 0, // 0x47
106 0, // 0x48
107 0, // 0x49
108 0, // 0x4a
109 0, // 0x4b
110 0, // 0x4c
111 0, // 0x4d
112 0, // 0x4e
113 0, // 0x4f
114 0, // 0x50
115 0, // 0x51
116 0, // 0x52
117 0, // 0x53
118 0, // 0x54
119 0, // 0x55
120 0, // 0x56
121 0, // 0x57
122 0, // 0x58
123 0, // 0x59
124 0, // 0x5a
125 0, // 0x5b
126 0, // 0x5c
127 0, // 0x5d
128 0, // 0x5e
129 0, // 0x5f
130 0, // 0x60
131 0, // 0x61
132 0, // 0x62
133 0, // 0x63
134 0, // 0x64
135 0, // 0x65
136 0, // 0x66
137 0, // 0x67
138 0, // 0x68
139 0, // 0x69
140 0, // 0x6a
141 0, // 0x6b
142 0, // 0x6c
143 0, // 0x6d
144 0, // 0x6e
145 0, // 0x6f
146 0, // 0x70
147 0, // 0x71
148 0, // 0x72
149 0, // 0x73
150 0, // 0x74
151 0, // 0x75
152 0, // 0x76
153 0, // 0x77
154 0, // 0x78
155 0, // 0x79
156 0, // 0x7a
157 0, // 0x7b
158 0, // 0x7c
159 0, // 0x7d
160 0, // 0x7e
161 0, // 0x7f
162
163 // Unpriviledged PAL instructions
164 "bpt", // 0x80
165 "bugchk", // 0x81
166 0, // 0x82
167 "callsys", // 0x83
168 0, // 0x84
169 0, // 0x85
170 "imb", // 0x86
171 0, // 0x87
172 0, // 0x88
173 0, // 0x89
174 0, // 0x8a
175 0, // 0x8b
176 0, // 0x8c
177 0, // 0x8d
178 0, // 0x8e
179 0, // 0x8f
180 0, // 0x90
181 0, // 0x91
182 "urti", // 0x92
183 0, // 0x93
184 0, // 0x94
185 0, // 0x95
186 0, // 0x96
187 0, // 0x97
188 0, // 0x98
189 0, // 0x99
190 0, // 0x9a
191 0, // 0x9b
192 0, // 0x9c
193 0, // 0x9d
194 "rdunique", // 0x9e
195 "wrunique", // 0x9f
196 0, // 0xa0
197 0, // 0xa1
198 0, // 0xa2
199 0, // 0xa3
200 0, // 0xa4
201 0, // 0xa5
202 0, // 0xa6
203 0, // 0xa7
204 0, // 0xa8
205 0, // 0xa9
206 "gentrap", // 0xaa
207 0, // 0xab
208 0, // 0xac
209 0, // 0xad
210 "clrfen", // 0xae
211 0, // 0xaf
212 0, // 0xb0
213 0, // 0xb1
214 0, // 0xb2
215 0, // 0xb3
216 0, // 0xb4
217 0, // 0xb5
218 0, // 0xb6
219 0, // 0xb7
220 0, // 0xb8
221 0, // 0xb9
222 0, // 0xba
223 0, // 0xbb
224 0, // 0xbc
225 0, // 0xbd
226 "nphalt", // 0xbe
227 "copypal", // 0xbf
228#if 0
229 0, // 0xc0
230 0, // 0xc1
231 0, // 0xc2
232 0, // 0xc3
233 0, // 0xc4
234 0, // 0xc5
235 0, // 0xc6
236 0, // 0xc7
237 0, // 0xc8
238 0, // 0xc9
239 0, // 0xca
240 0, // 0xcb
241 0, // 0xcc
242 0, // 0xcd
243 0, // 0xce
244 0, // 0xcf
245 0, // 0xd0
246 0, // 0xd1
247 0, // 0xd2
248 0, // 0xd3
249 0, // 0xd4
250 0, // 0xd5
251 0, // 0xd6
252 0, // 0xd7
253 0, // 0xd8
254 0, // 0xd9
255 0, // 0xda
256 0, // 0xdb
257 0, // 0xdc
258 0, // 0xdd
259 0, // 0xde
260 0, // 0xdf
261 0, // 0xe0
262 0, // 0xe1
263 0, // 0xe2
264 0, // 0xe3
265 0, // 0xe4
266 0, // 0xe5
267 0, // 0xe6
268 0, // 0xe7
269 0, // 0xe8
270 0, // 0xe9
271 0, // 0xea
272 0, // 0xeb
273 0, // 0xec
274 0, // 0xed
275 0, // 0xee
276 0, // 0xef
277 0, // 0xf0
278 0, // 0xf1
279 0, // 0xf2
280 0, // 0xf3
281 0, // 0xf4
282 0, // 0xf5
283 0, // 0xf6
284 0, // 0xf7
285 0, // 0xf8
286 0, // 0xf9
287 0, // 0xfa
288 0, // 0xfb
289 0, // 0xfc
290 0, // 0xfd
291 0, // 0xfe
292 0 // 0xff
293#endif
294 };
295}
296
297const char *
298PAL::name(int index)
299{
300 if (index > NumCodes || index < 0)
301 return 0;
302
303 return strings[index];
304}