Message ID | 1409233743-26944-1-git-send-email-omair.javaid@linaro.org |
---|---|
State | New |
Headers | show |
Omair Javaid <omair.javaid@linaro.org> writes: > 2014-08-28 Omair Javaid <omair.javaid@linaro.org> > > * aarch64-linux-tdep.c (aarch64_linux_init_abi): Install AArch64 ^^ One redundant space. > register note sections. > (struct core_regset_section aarch64_linux_regset_sections[]): Declare > AArch64 register note sections. I don't understand how does this patch relate to your whole patch series, which is about process record and reverse debugging for aarch64. If it is not related, please submit separately with a NEWS entry for it.
On 30 August 2014 07:56, Yao Qi <yao@codesourcery.com> wrote: > Omair Javaid <omair.javaid@linaro.org> writes: > >> 2014-08-28 Omair Javaid <omair.javaid@linaro.org> >> >> * aarch64-linux-tdep.c (aarch64_linux_init_abi): Install AArch64 > ^^ > One redundant space. OK. > >> register note sections. >> (struct core_regset_section aarch64_linux_regset_sections[]): Declare >> AArch64 register note sections. > > I don't understand how does this patch relate to your whole patch > series, which is about process record and reverse debugging for > aarch64. If it is not related, please submit separately with a NEWS > entry for it. Record/Replay requires corefiles support as pre-req, record data is stored in the form of core files. > > -- > Yao (齐尧)
Omair Javaid <omair.javaid@linaro.org> writes: > @@ -376,6 +385,9 @@ aarch64_linux_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch) > /* Enable longjmp. */ > tdep->jb_pc = 11; > > + /* Install supported register note sections. */ > + set_gdbarch_core_regset_sections (gdbarch, aarch64_linux_regset_sections); > + > set_gdbarch_regset_from_core_section (gdbarch, > aarch64_linux_regset_from_core_section); Is this patch stale? I don't see the definition of set_gdbarch_core_regset_sections. On the other hand, I see aarch64-linux-tdep.c already has: /* Implement the "regset_from_core_section" gdbarch method. */ static void aarch64_linux_iterate_over_regset_sections (struct gdbarch *gdbarch, iterate_over_regset_sections_cb *cb, void *cb_data, const struct regcache *regcache) { cb (".reg", AARCH64_LINUX_SIZEOF_GREGSET, &aarch64_linux_gregset, NULL, cb_data); cb (".reg2", AARCH64_LINUX_SIZEOF_FPREGSET, &aarch64_linux_fpregset, NULL, cb_data); } ... set_gdbarch_iterate_over_regset_sections (gdbarch, aarch64_linux_iterate_over_regset_sections); I assume this patch is no longer needed.
On 21 October 2014 18:24, Yao Qi <yao@codesourcery.com> wrote: > Omair Javaid <omair.javaid@linaro.org> writes: > >> @@ -376,6 +385,9 @@ aarch64_linux_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch) >> /* Enable longjmp. */ >> tdep->jb_pc = 11; >> >> + /* Install supported register note sections. */ >> + set_gdbarch_core_regset_sections (gdbarch, aarch64_linux_regset_sections); >> + >> set_gdbarch_regset_from_core_section (gdbarch, >> aarch64_linux_regset_from_core_section); > > Is this patch stale? I don't see the definition of > set_gdbarch_core_regset_sections. On the other hand, I see > aarch64-linux-tdep.c already has: > > /* Implement the "regset_from_core_section" gdbarch method. */ > > static void > aarch64_linux_iterate_over_regset_sections (struct gdbarch *gdbarch, > iterate_over_regset_sections_cb *cb, > void *cb_data, > const struct regcache *regcache) > { > cb (".reg", AARCH64_LINUX_SIZEOF_GREGSET, &aarch64_linux_gregset, > NULL, cb_data); > cb (".reg2", AARCH64_LINUX_SIZEOF_FPREGSET, &aarch64_linux_fpregset, > NULL, cb_data); > } > > ... > set_gdbarch_iterate_over_regset_sections > (gdbarch, aarch64_linux_iterate_over_regset_sections); > > I assume this patch is no longer needed. Agreed! > > -- > Yao (齐尧)
diff --git a/gdb/aarch64-linux-tdep.c b/gdb/aarch64-linux-tdep.c index 6377977..e5565a8 100644 --- a/gdb/aarch64-linux-tdep.c +++ b/gdb/aarch64-linux-tdep.c @@ -231,6 +231,15 @@ aarch64_linux_regset_from_core_section (struct gdbarch *gdbarch, return NULL; } +/* Core file register set sections. */ + +static struct core_regset_section aarch64_linux_regset_sections[] = +{ + { ".reg", AARCH64_LINUX_SIZEOF_GREGSET, "general-purpose" }, + { ".reg2", AARCH64_LINUX_SIZEOF_FPREGSET, "floating-point" }, + { NULL, 0} +}; + /* Implementation of `gdbarch_stap_is_single_operand', as defined in gdbarch.h. */ @@ -376,6 +385,9 @@ aarch64_linux_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch) /* Enable longjmp. */ tdep->jb_pc = 11; + /* Install supported register note sections. */ + set_gdbarch_core_regset_sections (gdbarch, aarch64_linux_regset_sections); + set_gdbarch_regset_from_core_section (gdbarch, aarch64_linux_regset_from_core_section);