Commit | Line | Data |
---|---|---|
cb7a6892 MM |
1 | /* This file is part of the program psim. |
2 | ||
3 | Copyright (C) 1994-1995, Andrew Cagney <cagney@highland.com.au> | |
4 | ||
5 | This program is free software; you can redistribute it and/or modify | |
6 | it under the terms of the GNU General Public License as published by | |
7 | the Free Software Foundation; either version 2 of the License, or | |
8 | (at your option) any later version. | |
9 | ||
10 | This program is distributed in the hope that it will be useful, | |
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
13 | GNU General Public License for more details. | |
14 | ||
15 | You should have received a copy of the GNU General Public License | |
16 | along with this program; if not, write to the Free Software | |
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | |
18 | ||
19 | */ | |
20 | ||
21 | ||
22 | /* | |
23 | * Interface for the Instruction execution routines | |
24 | */ | |
25 | ||
26 | /* | |
27 | * Macro's that define the parts of an instruction | |
28 | */ | |
29 | ||
30 | #define FLOATING_POINT_ENABLED_PROGRAM_INTERRUPT \ | |
31 | program_interrupt(processor, \ | |
32 | cia, \ | |
33 | floating_point_enabled_program_interrupt) | |
34 | ||
35 | #define ILLEGAL_INSN_PROGRAM_INTERRUPT \ | |
36 | program_interrupt(processor, \ | |
37 | cia, \ | |
38 | illegal_instruction_program_interrupt) | |
39 | #define PRIVILEGED_INSN_PROGRAM_INTERRUPT \ | |
40 | program_interrupt(processor, \ | |
41 | cia, \ | |
42 | privileged_instruction_program_interrupt) | |
43 | ||
44 | #define TRAP_PROGRAM_INTERRUPT \ | |
45 | program_interrupt(processor, \ | |
46 | cia, \ | |
47 | trap_program_interrupt) | |
48 | ||
49 | #define FLOATING_POINT_UNAVAILABLE_INTERRUPT \ | |
50 | floating_point_unavailable_interrupt(processor, \ | |
51 | cia) | |
52 | ||
53 | #define FLOATING_POINT_ASSIST_INTERRUPT \ | |
54 | floating_point_assist_interrupt(processor, \ | |
55 | cia) | |
56 | ||
57 | #define BREAKPOINT \ | |
58 | do { \ | |
59 | ITRACE(trace_breakpoint, \ | |
60 | ("breakpoint - cia0x%x\n", \ | |
61 | cia)); \ | |
62 | cpu_halt(processor, cia, was_trap, 0); \ | |
63 | } while (0) | |
64 | ||
65 | #define SYSTEM_CALL_INTERRUPT \ | |
66 | system_call_interrupt(processor, \ | |
67 | cia) |