sim: update device_error() prototype
[deliverable/binutils-gdb.git] / sim / sh64 / cpu.c
CommitLineData
cbb38b47
BE
1/* Misc. support for CPU family sh64.
2
3THIS FILE IS MACHINE GENERATED WITH CGEN.
4
0f51e9bf 5Copyright 1996-2010 Free Software Foundation, Inc.
cbb38b47 6
c7e628df 7This file is part of the GNU simulators.
cbb38b47 8
fda1c30b
DE
9 This file is free software; you can redistribute it and/or modify
10 it under the terms of the GNU General Public License as published by
11 the Free Software Foundation; either version 3, or (at your option)
12 any later version.
cbb38b47 13
fda1c30b
DE
14 It is distributed in the hope that it will be useful, but WITHOUT
15 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
16 or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
17 License for more details.
cbb38b47 18
fda1c30b
DE
19 You should have received a copy of the GNU General Public License along
20 with this program; if not, write to the Free Software Foundation, Inc.,
21 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
cbb38b47
BE
22
23*/
24
25#define WANT_CPU sh64
26#define WANT_CPU_SH64
27
28#include "sim-main.h"
29#include "cgen-ops.h"
30
31/* Get the value of h-pc. */
32
33UDI
34sh64_h_pc_get (SIM_CPU *current_cpu)
35{
36 return GET_H_PC ();
37}
38
39/* Set a value for h-pc. */
40
41void
42sh64_h_pc_set (SIM_CPU *current_cpu, UDI newval)
43{
44 SET_H_PC (newval);
45}
46
47/* Get the value of h-gr. */
48
49DI
50sh64_h_gr_get (SIM_CPU *current_cpu, UINT regno)
51{
52 return GET_H_GR (regno);
53}
54
55/* Set a value for h-gr. */
56
57void
58sh64_h_gr_set (SIM_CPU *current_cpu, UINT regno, DI newval)
59{
60 SET_H_GR (regno, newval);
61}
62
63/* Get the value of h-grc. */
64
65SI
66sh64_h_grc_get (SIM_CPU *current_cpu, UINT regno)
67{
68 return GET_H_GRC (regno);
69}
70
71/* Set a value for h-grc. */
72
73void
74sh64_h_grc_set (SIM_CPU *current_cpu, UINT regno, SI newval)
75{
76 SET_H_GRC (regno, newval);
77}
78
79/* Get the value of h-cr. */
80
81DI
82sh64_h_cr_get (SIM_CPU *current_cpu, UINT regno)
83{
84 return GET_H_CR (regno);
85}
86
87/* Set a value for h-cr. */
88
89void
90sh64_h_cr_set (SIM_CPU *current_cpu, UINT regno, DI newval)
91{
92 SET_H_CR (regno, newval);
93}
94
95/* Get the value of h-sr. */
96
97SI
98sh64_h_sr_get (SIM_CPU *current_cpu)
99{
100 return CPU (h_sr);
101}
102
103/* Set a value for h-sr. */
104
105void
106sh64_h_sr_set (SIM_CPU *current_cpu, SI newval)
107{
108 CPU (h_sr) = newval;
109}
110
111/* Get the value of h-fpscr. */
112
113SI
114sh64_h_fpscr_get (SIM_CPU *current_cpu)
115{
116 return CPU (h_fpscr);
117}
118
119/* Set a value for h-fpscr. */
120
121void
122sh64_h_fpscr_set (SIM_CPU *current_cpu, SI newval)
123{
124 CPU (h_fpscr) = newval;
125}
126
127/* Get the value of h-frbit. */
128
129BI
130sh64_h_frbit_get (SIM_CPU *current_cpu)
131{
132 return GET_H_FRBIT ();
133}
134
135/* Set a value for h-frbit. */
136
137void
138sh64_h_frbit_set (SIM_CPU *current_cpu, BI newval)
139{
140 SET_H_FRBIT (newval);
141}
142
143/* Get the value of h-szbit. */
144
145BI
146sh64_h_szbit_get (SIM_CPU *current_cpu)
147{
148 return GET_H_SZBIT ();
149}
150
151/* Set a value for h-szbit. */
152
153void
154sh64_h_szbit_set (SIM_CPU *current_cpu, BI newval)
155{
156 SET_H_SZBIT (newval);
157}
158
159/* Get the value of h-prbit. */
160
161BI
162sh64_h_prbit_get (SIM_CPU *current_cpu)
163{
164 return GET_H_PRBIT ();
165}
166
167/* Set a value for h-prbit. */
168
169void
170sh64_h_prbit_set (SIM_CPU *current_cpu, BI newval)
171{
172 SET_H_PRBIT (newval);
173}
174
175/* Get the value of h-sbit. */
176
177BI
178sh64_h_sbit_get (SIM_CPU *current_cpu)
179{
180 return GET_H_SBIT ();
181}
182
183/* Set a value for h-sbit. */
184
185void
186sh64_h_sbit_set (SIM_CPU *current_cpu, BI newval)
187{
188 SET_H_SBIT (newval);
189}
190
191/* Get the value of h-mbit. */
192
193BI
194sh64_h_mbit_get (SIM_CPU *current_cpu)
195{
196 return GET_H_MBIT ();
197}
198
199/* Set a value for h-mbit. */
200
201void
202sh64_h_mbit_set (SIM_CPU *current_cpu, BI newval)
203{
204 SET_H_MBIT (newval);
205}
206
207/* Get the value of h-qbit. */
208
209BI
210sh64_h_qbit_get (SIM_CPU *current_cpu)
211{
212 return GET_H_QBIT ();
213}
214
215/* Set a value for h-qbit. */
216
217void
218sh64_h_qbit_set (SIM_CPU *current_cpu, BI newval)
219{
220 SET_H_QBIT (newval);
221}
222
223/* Get the value of h-fr. */
224
225SF
226sh64_h_fr_get (SIM_CPU *current_cpu, UINT regno)
227{
228 return CPU (h_fr[regno]);
229}
230
231/* Set a value for h-fr. */
232
233void
234sh64_h_fr_set (SIM_CPU *current_cpu, UINT regno, SF newval)
235{
236 CPU (h_fr[regno]) = newval;
237}
238
239/* Get the value of h-fp. */
240
c7e628df 241SF
cbb38b47
BE
242sh64_h_fp_get (SIM_CPU *current_cpu, UINT regno)
243{
c7e628df 244 return GET_H_FP (regno);
cbb38b47
BE
245}
246
247/* Set a value for h-fp. */
248
249void
c7e628df 250sh64_h_fp_set (SIM_CPU *current_cpu, UINT regno, SF newval)
cbb38b47 251{
c7e628df 252 SET_H_FP (regno, newval);
cbb38b47
BE
253}
254
255/* Get the value of h-fv. */
256
257SF
258sh64_h_fv_get (SIM_CPU *current_cpu, UINT regno)
259{
260 return GET_H_FV (regno);
261}
262
263/* Set a value for h-fv. */
264
265void
266sh64_h_fv_set (SIM_CPU *current_cpu, UINT regno, SF newval)
267{
268 SET_H_FV (regno, newval);
269}
270
271/* Get the value of h-fmtx. */
272
273SF
274sh64_h_fmtx_get (SIM_CPU *current_cpu, UINT regno)
275{
276 return GET_H_FMTX (regno);
277}
278
279/* Set a value for h-fmtx. */
280
281void
282sh64_h_fmtx_set (SIM_CPU *current_cpu, UINT regno, SF newval)
283{
284 SET_H_FMTX (regno, newval);
285}
286
287/* Get the value of h-dr. */
288
289DF
290sh64_h_dr_get (SIM_CPU *current_cpu, UINT regno)
291{
292 return GET_H_DR (regno);
293}
294
295/* Set a value for h-dr. */
296
297void
298sh64_h_dr_set (SIM_CPU *current_cpu, UINT regno, DF newval)
299{
300 SET_H_DR (regno, newval);
301}
302
c7e628df
DB
303/* Get the value of h-fsd. */
304
305DF
306sh64_h_fsd_get (SIM_CPU *current_cpu, UINT regno)
307{
308 return GET_H_FSD (regno);
309}
310
311/* Set a value for h-fsd. */
312
313void
314sh64_h_fsd_set (SIM_CPU *current_cpu, UINT regno, DF newval)
315{
316 SET_H_FSD (regno, newval);
317}
318
319/* Get the value of h-fmov. */
320
321DF
322sh64_h_fmov_get (SIM_CPU *current_cpu, UINT regno)
323{
324 return GET_H_FMOV (regno);
325}
326
327/* Set a value for h-fmov. */
328
329void
330sh64_h_fmov_set (SIM_CPU *current_cpu, UINT regno, DF newval)
331{
332 SET_H_FMOV (regno, newval);
333}
334
cbb38b47
BE
335/* Get the value of h-tr. */
336
337DI
338sh64_h_tr_get (SIM_CPU *current_cpu, UINT regno)
339{
340 return CPU (h_tr[regno]);
341}
342
343/* Set a value for h-tr. */
344
345void
346sh64_h_tr_set (SIM_CPU *current_cpu, UINT regno, DI newval)
347{
348 CPU (h_tr[regno]) = newval;
349}
350
351/* Get the value of h-endian. */
352
353BI
354sh64_h_endian_get (SIM_CPU *current_cpu)
355{
356 return GET_H_ENDIAN ();
357}
358
359/* Set a value for h-endian. */
360
361void
362sh64_h_endian_set (SIM_CPU *current_cpu, BI newval)
363{
364 SET_H_ENDIAN (newval);
365}
366
367/* Get the value of h-ism. */
368
369BI
370sh64_h_ism_get (SIM_CPU *current_cpu)
371{
372 return GET_H_ISM ();
373}
374
375/* Set a value for h-ism. */
376
377void
378sh64_h_ism_set (SIM_CPU *current_cpu, BI newval)
379{
380 SET_H_ISM (newval);
381}
382
383/* Get the value of h-frc. */
384
385SF
386sh64_h_frc_get (SIM_CPU *current_cpu, UINT regno)
387{
388 return GET_H_FRC (regno);
389}
390
391/* Set a value for h-frc. */
392
393void
394sh64_h_frc_set (SIM_CPU *current_cpu, UINT regno, SF newval)
395{
396 SET_H_FRC (regno, newval);
397}
398
399/* Get the value of h-drc. */
400
401DF
402sh64_h_drc_get (SIM_CPU *current_cpu, UINT regno)
403{
404 return GET_H_DRC (regno);
405}
406
407/* Set a value for h-drc. */
408
409void
410sh64_h_drc_set (SIM_CPU *current_cpu, UINT regno, DF newval)
411{
412 SET_H_DRC (regno, newval);
413}
414
415/* Get the value of h-xf. */
416
417SF
418sh64_h_xf_get (SIM_CPU *current_cpu, UINT regno)
419{
420 return GET_H_XF (regno);
421}
422
423/* Set a value for h-xf. */
424
425void
426sh64_h_xf_set (SIM_CPU *current_cpu, UINT regno, SF newval)
427{
428 SET_H_XF (regno, newval);
429}
430
431/* Get the value of h-xd. */
432
433DF
434sh64_h_xd_get (SIM_CPU *current_cpu, UINT regno)
435{
436 return GET_H_XD (regno);
437}
438
439/* Set a value for h-xd. */
440
441void
442sh64_h_xd_set (SIM_CPU *current_cpu, UINT regno, DF newval)
443{
444 SET_H_XD (regno, newval);
445}
446
447/* Get the value of h-fvc. */
448
449SF
450sh64_h_fvc_get (SIM_CPU *current_cpu, UINT regno)
451{
452 return GET_H_FVC (regno);
453}
454
455/* Set a value for h-fvc. */
456
457void
458sh64_h_fvc_set (SIM_CPU *current_cpu, UINT regno, SF newval)
459{
460 SET_H_FVC (regno, newval);
461}
462
c7e628df 463/* Get the value of h-gbr. */
cbb38b47
BE
464
465SI
c7e628df 466sh64_h_gbr_get (SIM_CPU *current_cpu)
cbb38b47 467{
c7e628df 468 return GET_H_GBR ();
cbb38b47
BE
469}
470
c7e628df 471/* Set a value for h-gbr. */
cbb38b47
BE
472
473void
c7e628df 474sh64_h_gbr_set (SIM_CPU *current_cpu, SI newval)
cbb38b47 475{
c7e628df 476 SET_H_GBR (newval);
cbb38b47
BE
477}
478
c7e628df 479/* Get the value of h-vbr. */
cbb38b47
BE
480
481SI
c7e628df 482sh64_h_vbr_get (SIM_CPU *current_cpu)
cbb38b47 483{
c7e628df 484 return GET_H_VBR ();
cbb38b47
BE
485}
486
c7e628df 487/* Set a value for h-vbr. */
cbb38b47
BE
488
489void
c7e628df 490sh64_h_vbr_set (SIM_CPU *current_cpu, SI newval)
cbb38b47 491{
c7e628df 492 SET_H_VBR (newval);
cbb38b47
BE
493}
494
495/* Get the value of h-pr. */
496
497SI
498sh64_h_pr_get (SIM_CPU *current_cpu)
499{
500 return GET_H_PR ();
501}
502
503/* Set a value for h-pr. */
504
505void
506sh64_h_pr_set (SIM_CPU *current_cpu, SI newval)
507{
508 SET_H_PR (newval);
509}
510
511/* Get the value of h-macl. */
512
513SI
514sh64_h_macl_get (SIM_CPU *current_cpu)
515{
516 return GET_H_MACL ();
517}
518
519/* Set a value for h-macl. */
520
521void
522sh64_h_macl_set (SIM_CPU *current_cpu, SI newval)
523{
524 SET_H_MACL (newval);
525}
526
527/* Get the value of h-mach. */
528
529SI
530sh64_h_mach_get (SIM_CPU *current_cpu)
531{
532 return GET_H_MACH ();
533}
534
535/* Set a value for h-mach. */
536
537void
538sh64_h_mach_set (SIM_CPU *current_cpu, SI newval)
539{
540 SET_H_MACH (newval);
541}
542
543/* Get the value of h-tbit. */
544
545BI
546sh64_h_tbit_get (SIM_CPU *current_cpu)
547{
548 return GET_H_TBIT ();
549}
550
551/* Set a value for h-tbit. */
552
553void
554sh64_h_tbit_set (SIM_CPU *current_cpu, BI newval)
555{
556 SET_H_TBIT (newval);
557}
558
559/* Record trace results for INSN. */
560
561void
562sh64_record_trace_results (SIM_CPU *current_cpu, CGEN_INSN *insn,
563 int *indices, TRACE_RECORD *tr)
564{
565}
This page took 0.362713 seconds and 4 git commands to generate.