-
Andy Green authored
This a) directly discovers cgi stdout POLLUP and b) modulates rx flow control on CGI STDOUT according to the outgoing writeable service. When the outgoing writeable service finally sees 0 read() waiting for it even though it was signalled for POLLIN, it knows it is a POLLHUP. Critically when it sees POLLHUP like that, it leaves the rx flow control defeating any further stdout POLLIN signalling while the rest of the CGI lifecycle completes, eliminating busywaiting during the CGI.
Andy Green authoredThis a) directly discovers cgi stdout POLLUP and b) modulates rx flow control on CGI STDOUT according to the outgoing writeable service. When the outgoing writeable service finally sees 0 read() waiting for it even though it was signalled for POLLIN, it knows it is a POLLHUP. Critically when it sees POLLHUP like that, it leaves the rx flow control defeating any further stdout POLLIN signalling while the rest of the CGI lifecycle completes, eliminating busywaiting during the CGI.