In article <[EMAIL PROTECTED]>, Marcel Moolenaar  <[EMAIL PROTECTED]> wrote:
> Doug Rabson wrote:
> > On Wed, 13 Oct 1999, John Polstra wrote:
> > 
> > > and the fix is to add sigpending.o and sigsuspend.o to the
> > > definition of HIDDEN_SYSCALLS in "src/lib/libc_r/Makefile".
> > >
> > 
> > I'm pretty sure that this is the right fix. My guess as to why it didn't
> > pop up on i386 is that the old and new implementations were sufficiently
> > close in size that rounding up to 16bytes made them look identical.
> > 
> 
> I've just committed this.

Thanks.

> I'm also pretty sure this is the right fix. I don't know why ld/i386
> doesn't complain. It may be a bug, because the difference in size
> is probably more than 16 bytes. Compare for example sigprocmask, it
> originally also wasn't added to HIDDEN_SYSCALLS and therefore was
> also defined twice. I'm very much surprised if both versions end op
> being the same size...

I know now why it worked on the i386 but not on the Alpha.  On the
i386 a system call "read", for example, produces a strong (normal
global) symbol "_read" and a weak alias "read".  Because the symbols
were weak, the linker didn't complain about the multiple definitions.
But on the Alpha, only a strong symbol "read" is emitted.  So multiple
definitions caused a diagnostic there.

On a related topic, we should fix the Alpha to emit the weak alias
like the i386 does.  That's for ANSI/ISO C compliance, so that if a
user defines his own version of read(), it won't affect the behavior
of, say, getc().  We need a lot more of this throughout the C library
for both target platforms.  And we need to fix the calls inside there
to use the "_xxx" symbols rather than the "xxx" versions.

Don't ya just love people who say "we" need to do stuff? :-)

John
-- 
  John Polstra                                               [EMAIL PROTECTED]
  John D. Polstra & Co., Inc.                        Seattle, Washington USA
  "No matter how cynical I get, I just can't keep up."        -- Nora Ephron


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message

Reply via email to