| OLD | NEW |
| 1 /* Target description support for GDB. | 1 /* Target description support for GDB. |
| 2 | 2 |
| 3 Copyright (C) 2006-2012 Free Software Foundation, Inc. | 3 Copyright (C) 2006-2013 Free Software Foundation, Inc. |
| 4 | 4 |
| 5 Contributed by CodeSourcery. | 5 Contributed by CodeSourcery. |
| 6 | 6 |
| 7 This file is part of GDB. | 7 This file is part of GDB. |
| 8 | 8 |
| 9 This program is free software; you can redistribute it and/or modify | 9 This program is free software; you can redistribute it and/or modify |
| 10 it under the terms of the GNU General Public License as published by | 10 it under the terms of the GNU General Public License as published by |
| 11 the Free Software Foundation; either version 3 of the License, or | 11 the Free Software Foundation; either version 3 of the License, or |
| 12 (at your option) any later version. | 12 (at your option) any later version. |
| 13 | 13 |
| 14 This program is distributed in the hope that it will be useful, | 14 This program is distributed in the hope that it will be useful, |
| 15 but WITHOUT ANY WARRANTY; without even the implied warranty of | 15 but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 17 GNU General Public License for more details. | 17 GNU General Public License for more details. |
| 18 | 18 |
| 19 You should have received a copy of the GNU General Public License | 19 You should have received a copy of the GNU General Public License |
| 20 along with this program. If not, see <http://www.gnu.org/licenses/>. */ | 20 along with this program. If not, see <http://www.gnu.org/licenses/>. */ |
| 21 | 21 |
| 22 #ifndef TARGET_DESCRIPTIONS_H | 22 #ifndef TARGET_DESCRIPTIONS_H |
| 23 #define TARGET_DESCRIPTIONS_H 1 | 23 #define TARGET_DESCRIPTIONS_H 1 |
| 24 | 24 |
| 25 struct tdesc_feature; | 25 struct tdesc_feature; |
| 26 struct tdesc_arch_data; | 26 struct tdesc_arch_data; |
| 27 struct tdesc_type; | 27 struct tdesc_type; |
| 28 struct tdesc_reg; | 28 struct tdesc_reg; |
| 29 struct target_desc; | 29 struct target_desc; |
| 30 struct target_ops; | 30 struct target_ops; |
| 31 struct target_desc; |
| 32 /* An inferior's target description info is stored in this opaque |
| 33 object. There's one such object per inferior. */ |
| 34 struct target_desc_info; |
| 35 struct inferior; |
| 31 | 36 |
| 32 /* Fetch the current target's description, and switch the current | 37 /* Fetch the current inferior's description, and switch its current |
| 33 architecture to one which incorporates that description. */ | 38 architecture to one which incorporates that description. */ |
| 34 | 39 |
| 35 void target_find_description (void); | 40 void target_find_description (void); |
| 36 | 41 |
| 37 /* Discard any description fetched from the current target, and switch | 42 /* Discard any description fetched from the target for the current |
| 38 the current architecture to one with no target description. */ | 43 inferior, and switch the current architecture to one with no target |
| 44 description. */ |
| 39 | 45 |
| 40 void target_clear_description (void); | 46 void target_clear_description (void); |
| 41 | 47 |
| 42 /* Return the global current target description. This should only be | 48 /* Return the current inferior's target description. This should only |
| 43 used by gdbarch initialization code; most access should be through | 49 be used by gdbarch initialization code; most access should be |
| 44 an existing gdbarch. */ | 50 through an existing gdbarch. */ |
| 45 | 51 |
| 46 const struct target_desc *target_current_description (void); | 52 const struct target_desc *target_current_description (void); |
| 47 | 53 |
| 54 /* Copy inferior target description data. Used for example when |
| 55 handling (v)forks, where child's description is the same as the |
| 56 parent's, since the child really is a copy of the parent. */ |
| 57 |
| 58 void copy_inferior_target_desc_info (struct inferior *destinf, |
| 59 struct inferior *srcinf); |
| 60 |
| 61 /* Free a target_desc_info object. */ |
| 62 |
| 63 void target_desc_info_free (struct target_desc_info *tdesc_info); |
| 64 |
| 65 /* Returns true if INFO indicates the target description had been |
| 66 supplied by the user. */ |
| 67 |
| 68 int target_desc_info_from_user_p (struct target_desc_info *info); |
| 69 |
| 48 /* Record architecture-specific functions to call for pseudo-register | 70 /* Record architecture-specific functions to call for pseudo-register |
| 49 support. If tdesc_use_registers is called and gdbarch_num_pseudo_regs | 71 support. If tdesc_use_registers is called and gdbarch_num_pseudo_regs |
| 50 is greater than zero, then these should be called as well. | 72 is greater than zero, then these should be called as well. |
| 51 They are equivalent to the gdbarch methods with similar names, | 73 They are equivalent to the gdbarch methods with similar names, |
| 52 except that they will only be called for pseudo registers. */ | 74 except that they will only be called for pseudo registers. */ |
| 53 | 75 |
| 54 void set_tdesc_pseudo_register_name | 76 void set_tdesc_pseudo_register_name |
| 55 (struct gdbarch *gdbarch, gdbarch_register_name_ftype *pseudo_name); | 77 (struct gdbarch *gdbarch, gdbarch_register_name_ftype *pseudo_name); |
| 56 | 78 |
| 57 void set_tdesc_pseudo_register_type | 79 void set_tdesc_pseudo_register_type |
| (...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 217 struct tdesc_type *field_type); | 239 struct tdesc_type *field_type); |
| 218 void tdesc_add_bitfield (struct tdesc_type *type, const char *field_name, | 240 void tdesc_add_bitfield (struct tdesc_type *type, const char *field_name, |
| 219 int start, int end); | 241 int start, int end); |
| 220 void tdesc_add_flag (struct tdesc_type *type, int start, | 242 void tdesc_add_flag (struct tdesc_type *type, int start, |
| 221 const char *flag_name); | 243 const char *flag_name); |
| 222 void tdesc_create_reg (struct tdesc_feature *feature, const char *name, | 244 void tdesc_create_reg (struct tdesc_feature *feature, const char *name, |
| 223 int regnum, int save_restore, const char *group, | 245 int regnum, int save_restore, const char *group, |
| 224 int bitsize, const char *type); | 246 int bitsize, const char *type); |
| 225 | 247 |
| 226 #endif /* TARGET_DESCRIPTIONS_H */ | 248 #endif /* TARGET_DESCRIPTIONS_H */ |
| OLD | NEW |