- Notifications
You must be signed in to change notification settings - Fork28
Commitecb0d20
committed
Use unnamed POSIX semaphores, if available, on Linux and FreeBSD.
We've had support for using unnamed POSIX semaphores instead of System Vsemaphores for quite some time, but it was not used by default on anyplatform. Since many systems have rather small limits on the number ofSysV semaphores allowed, it seems desirable to switch to POSIX semaphoreswhere they're available and don't create performance or kernel resourceproblems. Experimentation by me shows that unnamed POSIX semaphoresare at least as good as SysV semaphores on Linux, and we previously hada report from Maksym Sobolyev that FreeBSD is significantly worse withSysV semaphores than POSIX ones. So adjust those two platforms to useunnamed POSIX semaphores, if configure can find the necessary libraryfunctions. If this goes well, we may switch other platforms as well,but it would be advisable to test them individually first.It's not currently contemplated that we'd encourage users to selecta semaphore API for themselves, but anyone who wants to experimentcan add PREFERRED_SEMAPHORES=UNNAMED_POSIX (or NAMED_POSIX, or SYSV)to their configure command line to do so.I also tweaked configure to report which API it's selected, mainlyso that we can tell that from buildfarm reports.I did not touch the user documentation's discussion about semaphores;that will need some adjustment once the dust settles.Discussion: <8536.1475704230@sss.pgh.pa.us>1 parentac4a9d9 commitecb0d20
4 files changed
+148
-0
lines changedLines changed: 125 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
14855 | 14855 |
| |
14856 | 14856 |
| |
14857 | 14857 |
| |
| 14858 | + | |
| 14859 | + | |
| 14860 | + | |
| 14861 | + | |
| 14862 | + | |
| 14863 | + | |
| 14864 | + | |
| 14865 | + | |
| 14866 | + | |
| 14867 | + | |
| 14868 | + | |
| 14869 | + | |
| 14870 | + | |
| 14871 | + | |
| 14872 | + | |
| 14873 | + | |
| 14874 | + | |
| 14875 | + | |
| 14876 | + | |
| 14877 | + | |
| 14878 | + | |
| 14879 | + | |
| 14880 | + | |
| 14881 | + | |
| 14882 | + | |
| 14883 | + | |
| 14884 | + | |
| 14885 | + | |
| 14886 | + | |
| 14887 | + | |
| 14888 | + | |
| 14889 | + | |
| 14890 | + | |
| 14891 | + | |
| 14892 | + | |
| 14893 | + | |
| 14894 | + | |
| 14895 | + | |
| 14896 | + | |
| 14897 | + | |
| 14898 | + | |
| 14899 | + | |
| 14900 | + | |
| 14901 | + | |
| 14902 | + | |
| 14903 | + | |
| 14904 | + | |
| 14905 | + | |
| 14906 | + | |
| 14907 | + | |
| 14908 | + | |
| 14909 | + | |
| 14910 | + | |
| 14911 | + | |
| 14912 | + | |
| 14913 | + | |
| 14914 | + | |
| 14915 | + | |
| 14916 | + | |
| 14917 | + | |
| 14918 | + | |
| 14919 | + | |
| 14920 | + | |
| 14921 | + | |
| 14922 | + | |
| 14923 | + | |
| 14924 | + | |
| 14925 | + | |
| 14926 | + | |
| 14927 | + | |
| 14928 | + | |
| 14929 | + | |
| 14930 | + | |
| 14931 | + | |
| 14932 | + | |
| 14933 | + | |
| 14934 | + | |
| 14935 | + | |
| 14936 | + | |
| 14937 | + | |
| 14938 | + | |
| 14939 | + | |
| 14940 | + | |
| 14941 | + | |
| 14942 | + | |
| 14943 | + | |
| 14944 | + | |
| 14945 | + | |
| 14946 | + | |
| 14947 | + | |
| 14948 | + | |
| 14949 | + | |
| 14950 | + | |
| 14951 | + | |
| 14952 | + | |
| 14953 | + | |
| 14954 | + | |
| 14955 | + | |
| 14956 | + | |
| 14957 | + | |
| 14958 | + | |
| 14959 | + | |
| 14960 | + | |
| 14961 | + | |
| 14962 | + | |
| 14963 | + | |
| 14964 | + | |
| 14965 | + | |
| 14966 | + | |
| 14967 | + | |
| 14968 | + | |
| 14969 | + | |
| 14970 | + | |
| 14971 | + | |
| 14972 | + | |
| 14973 | + | |
| 14974 | + | |
| 14975 | + | |
| 14976 | + | |
| 14977 | + | |
14858 | 14978 |
| |
14859 | 14979 |
| |
14860 | 14980 |
| |
14861 | 14981 |
| |
14862 | 14982 |
| |
| 14983 | + | |
14863 | 14984 |
| |
14864 | 14985 |
| |
14865 | 14986 |
| |
14866 | 14987 |
| |
14867 | 14988 |
| |
14868 | 14989 |
| |
| 14990 | + | |
14869 | 14991 |
| |
14870 | 14992 |
| |
14871 | 14993 |
| |
14872 | 14994 |
| |
14873 | 14995 |
| |
| 14996 | + | |
14874 | 14997 |
| |
| 14998 | + | |
| 14999 | + | |
14875 | 15000 |
| |
14876 | 15001 |
| |
14877 | 15002 |
| |
|
Lines changed: 13 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1939 | 1939 |
| |
1940 | 1940 |
| |
1941 | 1941 |
| |
| 1942 | + | |
| 1943 | + | |
| 1944 | + | |
| 1945 | + | |
| 1946 | + | |
| 1947 | + | |
| 1948 | + | |
| 1949 | + | |
| 1950 | + | |
1942 | 1951 |
| |
1943 | 1952 |
| |
1944 | 1953 |
| |
| 1954 | + | |
1945 | 1955 |
| |
1946 | 1956 |
| |
1947 | 1957 |
| |
1948 | 1958 |
| |
| 1959 | + | |
1949 | 1960 |
| |
1950 | 1961 |
| |
1951 | 1962 |
| |
| 1963 | + | |
1952 | 1964 |
| |
| 1965 | + | |
1953 | 1966 |
| |
1954 | 1967 |
| |
1955 | 1968 |
| |
|
Lines changed: 5 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1 | 1 |
| |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + |
Lines changed: 5 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1 | 1 |
| |
2 | 2 |
| |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
3 | 8 |
| |
4 | 9 |
| |
5 | 10 |
| |
|
0 commit comments
Comments
(0)