public inbox for libc-hacker@sourceware.org
 help / color / mirror / Atom feed
From: Jakub Jelinek <jakub@redhat.com>
To: Ulrich Drepper <drepper@cygnus.com>
Cc: libc-hacker@sourceware.cygnus.com
Subject: Re: [PATCH] shut up warnings in bits/string2.h
Date: Wed, 08 Dec 1999 07:56:00 -0000	[thread overview]
Message-ID: <19991208165752.K822@mff.cuni.cz> (raw)
In-Reply-To: <m3yab5suij.fsf@localhost.localnet>

> > gets compiled with -O2 -m32 by gcc 2.96 (but similarly by egcs 1.1.2) into:
> > foo:	save	%sp, -224, %sp
> > 	sethi	%hi(.LLC0+1), %o0
> > 	or	%o0, %lo(.LLC0+1), %o0
> > 	add	%o0, -1, %o5
> > 	sub	%o0, %o5, %o0
> > 	cmp	%o0, 1
> > 	bne	.LL145
> > 	mov	%i0, %o0
> > 	mov	115, %o1
> > [...]
> 
> This certainly is a SPARC problem.  Maybe some other platform, but not
> x86 and presumably not m68k.

Are you sure about this?
If I do on i686:

mkdir bits
touch bits/string.h
cat > test.c <<EOF
#include <string.h>
void foo(char *p) { strcpy(p, "strn"); }
EOF
gcc -S -O2 -o test1.s test.c
gcc -S -O2 -o test2.s test.c -D__NO_STRING_INLINES

test1.s is far longer and slower than test2.s (9 vs. 47 insns).
The fact that you're not normaly seeing it seems that i386 string.h defines
its own versions of the problematic glibc inlines.

BTW: I was posting a bugfix for bits/errno.h yesterday as well, could you
look at it and if it is ok commit it? Thanks.

Cheers,
    Jakub
___________________________________________________________________
Jakub Jelinek | jakub@redhat.com | http://sunsite.mff.cuni.cz/~jj
Linux version 2.3.18 on a sparc64 machine (1343.49 BogoMips)
___________________________________________________________________

      reply	other threads:[~1999-12-08  7:56 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-12-07 13:02 Jakub Jelinek
1999-12-07 18:41 ` Richard Henderson
1999-12-07 23:41 ` Ulrich Drepper
1999-12-08  0:22   ` Jakub Jelinek
1999-12-08  0:34     ` Ulrich Drepper
1999-12-08  7:56       ` Jakub Jelinek [this message]

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=19991208165752.K822@mff.cuni.cz \
    --to=jakub@redhat.com \
    --cc=drepper@cygnus.com \
    --cc=libc-hacker@sourceware.cygnus.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).