This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: assembler syntax: low(sym) vs. sym@l
- To: Greg McGary <greg at mcgary dot org>
- Subject: Re: assembler syntax: low(sym) vs. sym@l
- From: Michael Meissner <meissner at cygnus dot com>
- Date: Fri, 26 Jan 2001 13:14:04 -0500
- Cc: binutils at sources dot redhat dot com
- References: <200101260528.WAA05872@kayak.mcgary.org>
On Thu, Jan 25, 2001 at 10:28:00PM -0700, Greg McGary wrote:
> PPC provides this syntax for specifying 16-bit pieces of a word:
> sym@h, sym@ha, sym@l. m32r, OTOH, uses this syntax: high(sym),
> shigh(sym), low(sym).
>
> I need to choose a syntax for a new gas port. Is there a substantial
> reason (i.e., other than aesthetics) for choosing one over the other?
> I'll likely go with @xx suffixes if there's no good reason to prefer
> the other notation.
You do have to make sure that no matter which syntax you use, you can specify
an addition of a constant, ie:
(foo+1)@l
or foo+1@l
or low(foo+1)
That being said, it is probably slightly easier to parse <ref>@l instead of
low(<ref>). Note, if you use the low(...) form, you might want to use some
leading character like '%' such as %low(...).
--
Michael Meissner, Red Hat, Inc. (GCC group)
PMB 198, 174 Littleton Road #3, Westford, Massachusetts 01886, USA
Work: meissner@redhat.com phone: +1 978-486-9304
Non-work: meissner@spectacle-pond.org fax: +1 978-692-4482