This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


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: Principles for syscall wrappers, again


On Thu, 4 Jun 2015, Torvald Riegel wrote:

> Also, why would anyone multiplex several logically different operations,
> with type-unsafe parameter multiplexing and all that, into a single C
> function -- instead of just using several C functions?  I can't think of
> any reason but wanting to limit the number of functions/syscalls.

Well, I think ioctl is better as a libc interface than providing large 
numbers of extremely specialized functions - limiting the size of the libc 
interface, while still providing access to specialized operations not 
known at the time the interface is added to libc, can make sense.  And 
then in a few cases we provide higher-level interfaces to ioctls (e.g. 
termios).

> OK.  I notice you said "only providing higher-level" interfaces; so, do
> I understand you correctly that you're primary concern here is to
> provide futex(), and that you don't necessarily object to a proper
> interface, nor think that offering futex() renders offering a proper
> interface obsolete?

Yes.

-- 
Joseph S. Myers
joseph@codesourcery.com


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