summaryrefslogtreecommitdiff
path: root/gdb/ada-lang.h
diff options
context:
space:
mode:
authorPaul N. Hilfinger <hilfinger@adacore.com>2004-06-16 08:18:06 +0000
committerPaul N. Hilfinger <hilfinger@adacore.com>2004-06-16 08:18:06 +0000
commit77c6d2b38840a7d1d6434c28ea3ae9ba3d47e70c (patch)
tree6932f9dc56f4e2beb92aa79839cc98d958251307 /gdb/ada-lang.h
parent3d6c3afcf02bd8ebb505353362130bbb445fff16 (diff)
downloadgdb-77c6d2b38840a7d1d6434c28ea3ae9ba3d47e70c.tar.gz
* ada-tasks.c: Rename build_task_list to ada_build_task_list, and
make it non-static. * ada-lang.h (task_control_block): declaration moved from ada-task.c to ada-lang.h; this is needed to be able to implement the kill command in multi-task mode. (task_ptid): Ditto. (task_entry): Ditto. (task_list): Ditto. (ada_build_task_list): Ditto. * ada-lang.c: Conditionalize routines and data structures related to breakpoints, exceptions, completion, and symbol caching on GNAT_GDB, since these are not yet used in the submitted public sources. (ada_main_name): Editorial: Move definition out of exception-related code.
Diffstat (limited to 'gdb/ada-lang.h')
-rw-r--r--gdb/ada-lang.h44
1 files changed, 42 insertions, 2 deletions
diff --git a/gdb/ada-lang.h b/gdb/ada-lang.h
index 0381eff2c4e..5f5a7f5ea81 100644
--- a/gdb/ada-lang.h
+++ b/gdb/ada-lang.h
@@ -124,6 +124,41 @@ struct ada_symbol_info {
struct symtab* symtab;
};
+/* Ada task structures. */
+
+/* Ada task control block, as defined in the GNAT runt-time library. */
+
+struct task_control_block
+{
+ char state;
+ CORE_ADDR parent;
+ int priority;
+ char image [32];
+ int image_len; /* This field is not always present in the ATCB. */
+ CORE_ADDR call;
+ CORE_ADDR thread;
+ CORE_ADDR lwp; /* This field is not always present in the ATCB. */
+};
+
+struct task_ptid
+{
+ int pid; /* The Process id */
+ long lwp; /* The Light Weight Process id */
+ long tid; /* The Thread id */
+};
+typedef struct task_ptid task_ptid_t;
+
+struct task_entry
+{
+ CORE_ADDR task_id;
+ struct task_control_block atcb;
+ int task_num;
+ int known_tasks_index;
+ struct task_entry *next_task;
+ task_ptid_t task_ptid;
+ int stack_per;
+};
+
extern struct type *builtin_type_ada_int;
extern struct type *builtin_type_ada_short;
extern struct type *builtin_type_ada_long;
@@ -136,9 +171,13 @@ extern struct type *builtin_type_ada_natural;
extern struct type *builtin_type_ada_positive;
extern struct type *builtin_type_ada_system_address;
-/* The maximum number of tasks known to the Ada runtime */
+/* The maximum number of tasks known to the Ada runtime. */
extern const int MAX_NUMBER_OF_KNOWN_TASKS;
+/* task entry list. */
+extern struct task_entry *task_list;
+
+
/* Assuming V points to an array of S objects, make sure that it contains at
least M objects, updating V and S as necessary. */
@@ -393,6 +432,8 @@ extern void ada_find_printable_frame (struct frame_info *fi);
extern void ada_reset_thread_registers (void);
+extern int ada_build_task_list (void);
+
/* Look up a symbol by name using the search conventions of
a specific language (optional block, optional symtab).
FIXME: Should be symtab.h. */
@@ -403,5 +444,4 @@ extern struct symbol *lookup_symbol_in_language (const char *,
enum language,
int *,
struct symtab **);
-
#endif