This is the mail archive of the libc-hacker@sources.redhat.com mailing list for the glibc project.

Note that libc-hacker is a closed list. You may look at the archives of this list, but subscription and posting are not open.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: build failure


On Sat, Jan 04, 2003 at 12:57:15AM +0100, Jakub Jelinek wrote:
> No longer wonder. I think it is writev. And alloca-cutoff.c is not needed
> in ld.so on IA-32/x86-64/IA-64/sparc/sparc64 because it has INTERNAL_SYSCALL
> macro implemented, while Alpha does not.
> That one would be good to have...

The interface is lousy.

  (1) I'd have to generate an error return value.

      Unlike x86, the error indication is out of band from the
      return value.  Normally, this is a Good Thing.

  (2) The single place the error return value is checked, it's
      done with a variable that's too narrow.

I suggest that INTERNAL_SYSCALL be re-architected to return an error
indication as an output argument to the macro, i.e.

  result = INTERNAL_SYSCALL (errno, name, nr, args...) 

with errno == 0 on success.  This lets you get rid of 
INTERNAL_SYSCALL_ERROR_P and INTERNAL_SYSCALL_ERRNO.
In theory, you're not doing any additional work on x86
(or others, since all callers should be checking the
return result anyway, right?  And if you don't, the
computation should be removed as dead code.


r~


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]