Bug 379748 - [PATCH] Missing pselect syscall (OS X 10.11)
Summary: [PATCH] Missing pselect syscall (OS X 10.11)
Status: RESOLVED FIXED
Alias: None
Product: valgrind
Classification: Developer tools
Component: general (show other bugs)
Version: 3.13 SVN
Platform: macOS (DMG) macOS
: NOR normal
Target Milestone: ---
Assignee: Rhys Kidd
URL:
Keywords:
Depends on:
Blocks: 365327
  Show dependency treegraph
 
Reported: 2017-05-12 11:47 UTC by Louis Brunner
Modified: 2017-09-03 17:10 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Adds the pselect handler (3.72 KB, patch)
2017-05-12 11:47 UTC, Louis Brunner
Details
Adds the pselect handler (Darwin specific) (2.99 KB, patch)
2017-05-15 15:45 UTC, Louis Brunner
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Louis Brunner 2017-05-12 11:47:58 UTC
Created attachment 105473 [details]
Adds the pselect handler

Adds the pselect handler in the generic syscall file because it is defined by POSIX and the implementation is fairly basic (select with an extra check).
It is only included by Darwin (Linux seems to have its own handler).
Comment 1 Ivo Raisr 2017-05-13 05:38:37 UTC
POSIX does not mandate pselect kernel interface; it mandates only pselect system (library) interface. Therefore placing pselect syscall wrapper in syswrap-generic. is not very fortunate.
Have a look at other OSes and their kernel interfaces - Linux has pselect6, Solaris has no pselect at all (libc bases it directly on ppoll). Only *BSD seems to have the same kernel interface as OS X does.
Comment 2 Louis Brunner 2017-05-15 15:45:36 UTC
Created attachment 105563 [details]
Adds the pselect handler (Darwin specific)

Ivo,

My bad, thanks for the correction!
I moved it to Darwin instead of generic.
Comment 3 Rhys Kidd 2017-09-03 17:10:00 UTC
Based on xnu source this syscall #394 as pselect was added in OS X 10.11 (El Capitan).

Thanks for the patch Louis. A version based upon it was committed as 55fe390.