public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Pedro Alves <pedro@palves.net>
To: Luis Machado <luis.machado@arm.com>, gdb-patches@sourceware.org
Subject: Re: [PATCH] [Arm] Remove dead FPA code
Date: Mon, 10 Oct 2022 15:56:40 +0100	[thread overview]
Message-ID: <8b615b88-26d8-a480-ad9f-51be749169cb@palves.net> (raw)
In-Reply-To: <dabad50a-5a0c-4661-6c94-9ac1ce784786@arm.com>

Hi,

On 2022-10-04 9:43 a.m., Luis Machado wrote:
> 
> 
>>> -   The packet format which
>>> -   includes FPA registers should be considered deprecated for
>>> -   M-profile targets.  */
>>> -
>>> -static void
>>> -arm_register_g_packet_guesses (struct gdbarch *gdbarch)
>>> -{
>>> -  arm_gdbarch_tdep *tdep = gdbarch_tdep<arm_gdbarch_tdep> (gdbarch);
>>> -
>>> -  if (tdep->is_m)
>>> -    {
>>> -      const target_desc *tdesc;
>>> -
>>> -      /* If we know from the executable this is an M-profile target,
>>> -     cater for remote targets whose register set layout is the
>>> -     same as the FPA layout.  */
>>> -      tdesc = arm_read_mprofile_description (ARM_M_TYPE_WITH_FPA);
>>> -      register_remote_g_packet_guess (gdbarch,
>>> -                      ARM_CORE_REGS_SIZE + ARM_FP_REGS_SIZE,
>>> -                      tdesc);
>>> -
>>> -      /* The regular M-profile layout.  */
>>> -      tdesc = arm_read_mprofile_description (ARM_M_TYPE_M_PROFILE);
>>> -      register_remote_g_packet_guess (gdbarch, ARM_CORE_REGS_SIZE,
>>> -                      tdesc);
>>> -
>>> -      /* M-profile plus M4F VFP.  */
>>> -      tdesc = arm_read_mprofile_description (ARM_M_TYPE_VFP_D16);
>>> -      register_remote_g_packet_guess (gdbarch,
>>> -                      ARM_CORE_REGS_SIZE + ARM_VFP2_REGS_SIZE,
>>> -                      tdesc);
>>> -      /* M-profile plus MVE.  */
>>> -      tdesc = arm_read_mprofile_description (ARM_M_TYPE_MVE);
>>> -      register_remote_g_packet_guess (gdbarch, ARM_CORE_REGS_SIZE
>>> -                      + ARM_VFP2_REGS_SIZE
>>> -                      + ARM_INT_REGISTER_SIZE, tdesc);
>>> -
>>> -      /* M-profile system (stack pointers).  */
>>> -      tdesc = arm_read_mprofile_description (ARM_M_TYPE_SYSTEM);
>>> -      register_remote_g_packet_guess (gdbarch, 2 * ARM_INT_REGISTER_SIZE, tdesc);
>>
>> And what about all these other non-FPA guesses?  Do you really mean to drop them?
>>
> 
> More recently we've added two new guesses for MVE and M-profile system registers, but it doesn't
> make sense to do so, as these features are advertised as XML already. 

What was the justification for adding them back then, then?

> So in my opinion, we should
> drop the g packet guesses completely and rely solely on XML descriptions.

Then I think that it should be proposed in a separate patch, as it has nothing to
do with dropping FPA support.

Off hand, I don't really see what you win much removing the guesses.  The code that it allows
removing isn't something that would block any redesign or big cleanup in gdb, as gdb needs to know
how to create built-in tdescs for core files, anyhow (even if not these particular tdescs),
and the tdesc generation code is even shared with gdbserver.

  parent reply	other threads:[~2022-10-10 14:56 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-20 12:30 Luis Machado
2022-09-20 12:47 ` Eli Zaretskii
2022-10-02 13:39 ` Enze Li
2022-10-03  8:27   ` Luis Machado
2022-10-03 17:33 ` John Baldwin
2022-10-03 19:16 ` Pedro Alves
2022-10-04  8:43   ` Luis Machado
2022-10-04 17:08     ` John Baldwin
2022-10-04 17:43       ` Luis Machado
2022-10-04 21:36         ` John Baldwin
2022-10-05  8:26           ` Luis Machado
2022-10-05  8:36             ` David Spickett
2022-10-05  8:36               ` David Spickett
2022-10-05 16:48             ` John Baldwin
2022-10-05 16:57               ` Richard Earnshaw
2022-10-06 13:02                 ` Luis Machado
2022-10-10 14:58             ` Pedro Alves
2022-10-13  7:23               ` Luis Machado
2022-10-13  8:29                 ` Pedro Alves
2022-10-13  9:40                   ` Luis Machado
2022-10-25 13:54                     ` Luis Machado
2022-11-14 14:30                     ` Simon Marchi
2022-10-10 14:56     ` Pedro Alves [this message]
2022-10-13  7:18       ` Luis Machado
2022-10-13  8:44         ` Pedro Alves
2022-10-13  9:15           ` Luis Machado

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8b615b88-26d8-a480-ad9f-51be749169cb@palves.net \
    --to=pedro@palves.net \
    --cc=gdb-patches@sourceware.org \
    --cc=luis.machado@arm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).