public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
From: Jan Beulich <jbeulich@suse.com>
To: Alan Modra <amodra@gmail.com>
Cc: Binutils <binutils@sourceware.org>,
	Peter Bergner <bergner@vnet.ibm.com>,
	Geoff Keating <geoffk@geoffk.org>,
	"H.J. Lu" <hjl.tools@gmail.com>
Subject: Re: [PATCH] gas: equates of registers
Date: Mon, 24 Apr 2023 10:12:51 +0200	[thread overview]
Message-ID: <86117339-43e9-06a5-511d-6eadeb0243eb@suse.com> (raw)
In-Reply-To: <ZEXHxo7mll9YrHpR@squeak.grove.modra.org>

On 24.04.2023 02:05, Alan Modra wrote:
> On Fri, Apr 21, 2023 at 02:17:54PM +0200, Jan Beulich wrote:
>> For ppc I wonder whether the "looking through" equates really should be
>> limited to registers only: This might be as applicable to constants
>> (including O_big), and finding e.g. O_illegal right away might be
>> helpful too.
> 
> I'm happy enough with the patch as-is, or with this further
> simplification.  The only concern I have is that there may be backends
> other than ppc that need symbol equate resolved early.  (But I haven't
> looked, I'm leaving that to you!)

Well, so far I've gone by testsuite results (albeit on ppc I expected
that I'd need to make a change somewhere, and running the testsuite was
mainly to help find where the change is needed), but of course there's
a fair chance that some backends simply lack respective testing. Yet to
be honest, trying to understand every target's backend code just to
figure whether they also need something similar is a little beyond of
what I'm feeling up to. (I did look for certain patterns, and I'll try
to think of more which might be relevant ...)

As to the further simplification - I meanwhile think that I perhaps
better shouldn't do that: Registers (when looking for insn operands of
certain types) are quite special, and forward reference equates aren't
(normally) okay to use in such places. Forward reference equates are,
otoh, at least sometimes okay to use for e.g. constants (when a
suitable internal relocation type is available to express it), and
even finding O_illegal might (via some magic) disappear by the time we
process relocations.

Do you have any thoughts on the other two remarks (equates of constants
not being recognized as equates, and the place where to set O_register)?

Jan

  reply	other threads:[~2023-04-24  8:12 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-21 12:17 Jan Beulich
2023-04-24  0:05 ` Alan Modra
2023-04-24  8:12   ` Jan Beulich [this message]
2023-04-26  7:02     ` Alan Modra

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=86117339-43e9-06a5-511d-6eadeb0243eb@suse.com \
    --to=jbeulich@suse.com \
    --cc=amodra@gmail.com \
    --cc=bergner@vnet.ibm.com \
    --cc=binutils@sourceware.org \
    --cc=geoffk@geoffk.org \
    --cc=hjl.tools@gmail.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).