Re: Remove pthread_is_threaded_np() checks in postmaster

2024-01-24 Thread Thomas Munro
On Wed, Jan 24, 2024 at 1:39 PM Andres Freund wrote: > On 2024-01-23 17:26:19 -0600, Tristan Partin wrote: > > On Tue Jan 23, 2024 at 4:23 PM CST, Andres Freund wrote: > > > A fork() while threads are running is undefined behavior IIRC, and > > > undefined > > > behavior isn't limited to a single

Re: Remove pthread_is_threaded_np() checks in postmaster

2024-01-23 Thread Andres Freund
Hi, On 2024-01-23 17:26:19 -0600, Tristan Partin wrote: > On Tue Jan 23, 2024 at 4:23 PM CST, Andres Freund wrote: > > Hi, > > > > On 2024-01-23 15:50:11 -0600, Tristan Partin wrote: > > > What is keeping us from using pthread_sigmask(3) instead of > > > sigprocmask(2)? > > > > We would need to

Re: Remove pthread_is_threaded_np() checks in postmaster

2024-01-23 Thread Tristan Partin
On Tue Jan 23, 2024 at 4:23 PM CST, Andres Freund wrote: Hi, On 2024-01-23 15:50:11 -0600, Tristan Partin wrote: > What is keeping us from using pthread_sigmask(3) instead of sigprocmask(2)? We would need to make sure to compile with threading support everywhere. One issue is that on some platf

Re: Remove pthread_is_threaded_np() checks in postmaster

2024-01-23 Thread Andres Freund
Hi, On 2024-01-23 15:50:11 -0600, Tristan Partin wrote: > What is keeping us from using pthread_sigmask(3) instead of sigprocmask(2)? We would need to make sure to compile with threading support everywhere. One issue is that on some platforms things get slower once you actually start using pthrea

Re: Remove pthread_is_threaded_np() checks in postmaster

2024-01-23 Thread Tristan Partin
On Tue Jan 23, 2024 at 2:10 PM CST, Tristan Partin wrote: On Tue Jan 23, 2024 at 1:47 PM CST, Andres Freund wrote: > Hi, > On 2024-01-23 13:20:15 -0600, Tristan Partin wrote: > > These checks are not effective for what they are trying to prevent. A recent > > commit[0] in libcurl when used on mac

Re: Remove pthread_is_threaded_np() checks in postmaster

2024-01-23 Thread Tristan Partin
On Tue Jan 23, 2024 at 1:47 PM CST, Andres Freund wrote: Hi, On 2024-01-23 13:20:15 -0600, Tristan Partin wrote: > These checks are not effective for what they are trying to prevent. A recent > commit[0] in libcurl when used on macOS has been tripping the > pthread_is_threaded_np() check in postm

Re: Remove pthread_is_threaded_np() checks in postmaster

2024-01-23 Thread Andres Freund
Hi, On 2024-01-23 13:20:15 -0600, Tristan Partin wrote: > These checks are not effective for what they are trying to prevent. A recent > commit[0] in libcurl when used on macOS has been tripping the > pthread_is_threaded_np() check in postmaster.c for shared_preload_libraries > entries which use li

Remove pthread_is_threaded_np() checks in postmaster

2024-01-23 Thread Tristan Partin
mit/8b7cbe9decc205b08ec8258eb184c89a33e3084b [1]: https://developer.apple.com/documentation/systemconfiguration/1517088-scdynamicstorecopyproxies -- Tristan Partin Neon (https://neon.tech) <> From 0a514e7a8ea2af21d98cbcc2e4da799745786155 Mon Sep 17 00:00:00 2001 From: Tristan Partin Date