summaryrefslogtreecommitdiff
path: root/gdb/jit.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/jit.c')
-rw-r--r--gdb/jit.c37
1 files changed, 22 insertions, 15 deletions
diff --git a/gdb/jit.c b/gdb/jit.c
index 6302052321e..fbc0d02f81d 100644
--- a/gdb/jit.c
+++ b/gdb/jit.c
@@ -285,7 +285,7 @@ get_jit_objfile_data (struct objfile *objf)
{
struct jit_objfile_data *objf_data;
- objf_data = objfile_data (objf, jit_objfile_data);
+ objf_data = (struct jit_objfile_data *) objfile_data (objf, jit_objfile_data);
if (objf_data == NULL)
{
objf_data = XCNEW (struct jit_objfile_data);
@@ -315,7 +315,9 @@ get_jit_program_space_data (void)
{
struct jit_program_space_data *ps_data;
- ps_data = program_space_data (current_program_space, jit_program_space_data);
+ ps_data
+ = ((struct jit_program_space_data *)
+ program_space_data (current_program_space, jit_program_space_data));
if (ps_data == NULL)
{
ps_data = XCNEW (struct jit_program_space_data);
@@ -791,7 +793,7 @@ jit_object_close_impl (struct gdb_symbol_callbacks *cb,
struct objfile *objfile;
jit_dbg_reader_data *priv_data;
- priv_data = cb->priv_data;
+ priv_data = (jit_dbg_reader_data *) cb->priv_data;
objfile = allocate_objfile (NULL, "<< JIT compiled code >>",
OBJF_NOT_FILENAME);
@@ -989,7 +991,8 @@ jit_find_objf_with_entry_addr (CORE_ADDR entry_addr)
{
struct jit_objfile_data *objf_data;
- objf_data = objfile_data (objf, jit_objfile_data);
+ objf_data
+ = (struct jit_objfile_data *) objfile_data (objf, jit_objfile_data);
if (objf_data != NULL && objf_data->addr == entry_addr)
return objf;
}
@@ -1011,7 +1014,8 @@ jit_breakpoint_deleted (struct breakpoint *b)
{
struct jit_program_space_data *ps_data;
- ps_data = program_space_data (iter->pspace, jit_program_space_data);
+ ps_data = ((struct jit_program_space_data *)
+ program_space_data (iter->pspace, jit_program_space_data));
if (ps_data != NULL && ps_data->jit_breakpoint == iter->owner)
{
ps_data->cached_code_address = 0;
@@ -1100,7 +1104,7 @@ jit_unwind_reg_set_impl (struct gdb_unwind_callbacks *cb, int dwarf_regnum,
struct jit_unwind_private *priv;
int gdb_reg;
- priv = cb->priv_data;
+ priv = (struct jit_unwind_private *) cb->priv_data;
gdb_reg = gdbarch_dwarf2_reg_to_regnum (get_frame_arch (priv->this_frame),
dwarf_regnum);
@@ -1133,7 +1137,7 @@ jit_unwind_reg_get_impl (struct gdb_unwind_callbacks *cb, int regnum)
int gdb_reg, size;
struct gdbarch *frame_arch;
- priv = cb->priv_data;
+ priv = (struct jit_unwind_private *) cb->priv_data;
frame_arch = get_frame_arch (priv->this_frame);
gdb_reg = gdbarch_dwarf2_reg_to_regnum (frame_arch, regnum);
@@ -1153,7 +1157,7 @@ jit_unwind_reg_get_impl (struct gdb_unwind_callbacks *cb, int regnum)
static void
jit_dealloc_cache (struct frame_info *this_frame, void *cache)
{
- struct jit_unwind_private *priv_data = cache;
+ struct jit_unwind_private *priv_data = (struct jit_unwind_private *) cache;
struct gdbarch *frame_arch;
int i;
@@ -1196,7 +1200,7 @@ jit_frame_sniffer (const struct frame_unwind *self,
gdb_assert (!*cache);
*cache = XCNEW (struct jit_unwind_private);
- priv_data = *cache;
+ priv_data = (struct jit_unwind_private *) *cache;
priv_data->registers =
XCNEWVEC (struct gdb_reg_value *,
gdbarch_num_regs (get_frame_arch (this_frame)));
@@ -1258,7 +1262,7 @@ jit_frame_this_id (struct frame_info *this_frame, void **cache,
static struct value *
jit_frame_prev_register (struct frame_info *this_frame, void **cache, int reg)
{
- struct jit_unwind_private *priv = *cache;
+ struct jit_unwind_private *priv = (struct jit_unwind_private *) *cache;
struct gdb_reg_value *value;
if (priv == NULL)
@@ -1303,7 +1307,8 @@ jit_prepend_unwinder (struct gdbarch *gdbarch)
{
struct jit_gdbarch_data_type *data;
- data = gdbarch_data (gdbarch, jit_gdbarch_data);
+ data
+ = (struct jit_gdbarch_data_type *) gdbarch_data (gdbarch, jit_gdbarch_data);
if (!data->unwinder_registered)
{
frame_unwind_prepend_unwinder (gdbarch, &jit_frame_unwind);
@@ -1391,8 +1396,8 @@ jit_inferior_exit_hook (struct inferior *inf)
ALL_OBJFILES_SAFE (objf, temp)
{
- struct jit_objfile_data *objf_data = objfile_data (objf,
- jit_objfile_data);
+ struct jit_objfile_data *objf_data
+ = (struct jit_objfile_data *) objfile_data (objf, jit_objfile_data);
if (objf_data != NULL && objf_data->addr != 0)
jit_unregister_code (objf);
@@ -1443,13 +1448,15 @@ jit_event_handler (struct gdbarch *gdbarch)
static void
free_objfile_data (struct objfile *objfile, void *data)
{
- struct jit_objfile_data *objf_data = data;
+ struct jit_objfile_data *objf_data = (struct jit_objfile_data *) data;
if (objf_data->register_code != NULL)
{
struct jit_program_space_data *ps_data;
- ps_data = program_space_data (objfile->pspace, jit_program_space_data);
+ ps_data
+ = ((struct jit_program_space_data *)
+ program_space_data (objfile->pspace, jit_program_space_data));
if (ps_data != NULL && ps_data->objfile == objfile)
ps_data->objfile = NULL;
}