Re: [HACKERS] [PATCH v4] [libpq] Try to avoid manually masking SIGPIPEs on every send()

2009-07-24 Thread Tom Lane
Jeremy Kerr writes: > Currently, libpq will wrap each send() call on the connection with > two system calls to mask SIGPIPEs. This results in 3 syscalls instead > of one, and (on Linux) can lead to high contention on the signal > mask locks in threaded apps. > We have a couple of other methods to

[HACKERS] [PATCH v4] [libpq] Try to avoid manually masking SIGPIPEs on every send()

2009-07-23 Thread Jeremy Kerr
Currently, libpq will wrap each send() call on the connection with two system calls to mask SIGPIPEs. This results in 3 syscalls instead of one, and (on Linux) can lead to high contention on the signal mask locks in threaded apps. We have a couple of other methods to avoid SIGPIPEs: sockopt(SO_NOS