OLD | NEW |
1 /* Main simulator entry points specific to the CRIS. | 1 /* Main simulator entry points specific to the CRIS. |
2 Copyright (C) 2004-2012 Free Software Foundation, Inc. | 2 Copyright (C) 2004-2012 Free Software Foundation, Inc. |
3 Contributed by Axis Communications. | 3 Contributed by Axis Communications. |
4 | 4 |
5 This file is part of the GNU simulators. | 5 This file is part of the GNU simulators. |
6 | 6 |
7 This program is free software; you can redistribute it and/or modify | 7 This program is free software; you can redistribute it and/or modify |
8 it under the terms of the GNU General Public License as published by | 8 it under the terms of the GNU General Public License as published by |
9 the Free Software Foundation; either version 3 of the License, or | 9 the Free Software Foundation; either version 3 of the License, or |
10 (at your option) any later version. | 10 (at your option) any later version. |
11 | 11 |
12 This program is distributed in the hope that it will be useful, | 12 This program is distributed in the hope that it will be useful, |
13 but WITHOUT ANY WARRANTY; without even the implied warranty of | 13 but WITHOUT ANY WARRANTY; without even the implied warranty of |
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
15 GNU General Public License for more details. | 15 GNU General Public License for more details. |
16 | 16 |
17 You should have received a copy of the GNU General Public License | 17 You should have received a copy of the GNU General Public License |
18 along with this program. If not, see <http://www.gnu.org/licenses/>. */ | 18 along with this program. If not, see <http://www.gnu.org/licenses/>. */ |
19 | 19 |
20 /* Based on the fr30 file, mixing in bits from the i960 and pruning of | 20 /* Based on the fr30 file, mixing in bits from the i960 and pruning of |
21 dead code. */ | 21 dead code. */ |
22 | 22 |
| 23 #include "config.h" |
23 #include "libiberty.h" | 24 #include "libiberty.h" |
24 #include "bfd.h" | 25 #include "bfd.h" |
25 #include "elf-bfd.h" | 26 #include "elf-bfd.h" |
26 | 27 |
27 #include "sim-main.h" | 28 #include "sim-main.h" |
28 #ifdef HAVE_STDLIB_H | 29 #ifdef HAVE_STDLIB_H |
29 #include <stdlib.h> | 30 #include <stdlib.h> |
30 #endif | 31 #endif |
31 #include <errno.h> | 32 #include <errno.h> |
32 #include "sim-options.h" | 33 #include "sim-options.h" |
(...skipping 1080 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1113 sfile.buffer = sfile.current = buf; | 1114 sfile.buffer = sfile.current = buf; |
1114 INIT_DISASSEMBLE_INFO (disasm_info, (FILE *) &sfile, | 1115 INIT_DISASSEMBLE_INFO (disasm_info, (FILE *) &sfile, |
1115 (fprintf_ftype) sim_disasm_sprintf); | 1116 (fprintf_ftype) sim_disasm_sprintf); |
1116 disasm_info.endian = BFD_ENDIAN_LITTLE; | 1117 disasm_info.endian = BFD_ENDIAN_LITTLE; |
1117 disasm_info.read_memory_func = sim_disasm_read_memory; | 1118 disasm_info.read_memory_func = sim_disasm_read_memory; |
1118 disasm_info.memory_error_func = sim_disasm_perror_memory; | 1119 disasm_info.memory_error_func = sim_disasm_perror_memory; |
1119 disasm_info.application_data = (PTR) cpu; | 1120 disasm_info.application_data = (PTR) cpu; |
1120 pinsn = cris_get_disassembler (STATE_PROG_BFD (sd)); | 1121 pinsn = cris_get_disassembler (STATE_PROG_BFD (sd)); |
1121 (*pinsn) (pc, &disasm_info); | 1122 (*pinsn) (pc, &disasm_info); |
1122 } | 1123 } |
OLD | NEW |