public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Zack Weinberg <zack@codesourcery.com>
To: Richard Henderson <rth@redhat.com>,
	gcc-patches@gcc.gnu.org, Andrew Pinski <pinskia@physics.uc.edu>
Subject: Re: RFC/RFA: Improve definition of ASM_OUTPUT_MEASURED_SIZE
Date: Thu, 25 Jul 2002 23:54:00 -0000	[thread overview]
Message-ID: <20020726053048.GA16614@codesourcery.com> (raw)
In-Reply-To: <20020725185339.C27268@redhat.com>

On Thu, Jul 25, 2002 at 06:53:39PM -0700, Richard Henderson wrote:
> On Thu, Jul 25, 2002 at 05:20:49PM -0700, Zack Weinberg wrote:
> > It seems to me that any assembler with a
> > .size directive ought to be modern enough to accept the expression
> > ".-foo".
> 
> I don't think this is actually true.  Better try this
> on Solaris, Irix, and SCO.

Robert Lipe has reported it works on SCO.

On Solaris,

$ cat test.s
        .section ".text"
        .global foo
        .type    foo,#function
foo:
        retl
        sll     %o0, 1, %o0
        .size    foo, .-foo
$ /usr/ccs/bin/as -V test.s
as: Sun WorkShop 6 99/08/18
$ nm test.o
[Index]   Value      Size    Type  Bind  Other Shndx   Name
[1]     |         0|       0|SECT |LOCL |0    |2      |
[2]     |         0|       8|FUNC |GLOB |0    |2      |foo
$ uname -a
SunOS chili 5.8 Generic_108528-10 sun4u sparc SUNW,Ultra-5_10

2.8 is recent, yes, but the datestamp on that assembler is quite old.
(I no longer remember how to find out what patches have been applied
to a specific file.)

I have no access to IRIX.

> I'd be willing to go the other way and always use the intermediate
> symbol though.

I'd be willing to do that if we have to, but if we can make .-sym
work on all or even most of these systems I think that's a cleaner
solution.

zw

  reply	other threads:[~2002-07-26  5:30 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-07-25 18:22 Zack Weinberg
2002-07-25 19:56 ` Richard Henderson
2002-07-25 23:54   ` Zack Weinberg [this message]
2002-07-26  4:20     ` Richard Sandiford
2002-07-26 11:21       ` Richard Henderson
2002-07-26 16:35         ` Zack Weinberg
2002-07-27 14:48           ` Richard Henderson
2002-07-29 10:02         ` Mark Mitchell
2002-07-26 10:48     ` Mark Mitchell

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=20020726053048.GA16614@codesourcery.com \
    --to=zack@codesourcery.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=pinskia@physics.uc.edu \
    --cc=rth@redhat.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).