This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug exp/21717] "print $fpscr" says "<unavailable>" until some VFP data register is printed
- From: "qiyao at gcc dot gnu.org" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: Fri, 21 Jul 2017 14:58:18 +0000
- Subject: [Bug exp/21717] "print $fpscr" says "<unavailable>" until some VFP data register is printed
- Auto-submitted: auto-generated
- References: <bug-21717-4717@http.sourceware.org/bugzilla/>
https://sourceware.org/bugzilla/show_bug.cgi?id=21717
Yao Qi <qiyao at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |ASSIGNED
Last reconfirmed| |2017-07-21
Assignee|unassigned at sourceware dot org |qiyao at gcc dot gnu.org
Ever confirmed|0 |1
--- Comment #5 from Yao Qi <qiyao at gcc dot gnu.org> ---
(In reply to Ruslan from comment #4)
> OK, here's what happens: in arm_linux_fetch_inferior_registers the last
> branch
>
> else if (tdep->vfp_register_count > 0
> && regno >= ARM_D0_REGNUM
> && regno <= ARM_D0_REGNUM + tdep->vfp_register_count)
> fetch_vfp_regs (regcache);
>
> has tdep->vfp_register_count==16, while regno=90 (ARM_FPSCR_REGNUM). As
> ARM_D0_REGNUM==58, the call to fetch_vfp_regs(regcache) doesn't happen.
>
> What seems to mismatch here is that VFP register count is 16, i.e. D0-D15,
> but enum gdb_regnum contains values up to ARM_D31_REGNUM, thus the next
> value, ARM_FPSCR_REGNUM, is not reached by the comparisons. Thus it's not
> surprising that the code does work on VFPv3, where there're 32 VFP
> double-precision registers.
>
> I suppose there should be a "|| regno==ARM_FPSCR_REGNUM" or something like
> that inside the if-condition.
Indeed, I'll fix it.
--
You are receiving this mail because:
You are on the CC list for the bug.