cygrunsrv + sshd + rsync = 20 times too slow -- throttled?

Takashi Yano takashi.yano@nifty.ne.jp
Fri Sep 10 03:41:21 GMT 2021


On Fri, 10 Sep 2021 06:53:34 +0900
Takashi Yano wrote:
> On Thu, 9 Sep 2021 21:42:46 +0900
> Takashi Yano wrote:
> > On Thu, 9 Sep 2021 21:19:40 +0900
> > Takashi Yano wrote:
> > > On Thu, 9 Sep 2021 17:05:49 +0900
> > > Takashi Yano wrote:
> > > > On Thu, 9 Sep 2021 12:41:15 +0900
> > > > Takashi Yano wrote:
> > > > > diff --git a/winsup/cygwin/fhandler_fifo.cc b/winsup/cygwin/fhandler_fifo.cc
> > > > > index 6709fb974..c40573783 100644
> > > > > --- a/winsup/cygwin/fhandler_fifo.cc
> > > > > +++ b/winsup/cygwin/fhandler_fifo.cc
> > > > > @@ -1047,6 +1047,12 @@ writer_shmem:
> > > > >    ResetEvent (writer_opening);
> > > > >    nwriters_unlock ();
> > > > >  success:
> > > > > +  if (!select_sem)
> > > > > +    {
> > > > > +      char name[MAX_PATH];
> > > > > +      __small_sprintf(name, "semaphore-%W", get_pipe_name ()->Buffer);
> > > > > +      select_sem = CreateSemaphore (&sec_none, 0, INT32_MAX, name);
> > > > > +    }
> > > > >    return 1;
> > > > >  err_close_reader:
> > > > >    saved_errno = get_errno ();
> > > > 
> > > > Should this be:
> > > > > +      select_sem = CreateSemaphore (sa_buf, 0, INT32_MAX, name);
> > > > ?
> > > 
> > > I revised the patch a bit.
> > 
> > Sorry, I revised the patch again.
> 
> The patch still has a mistake. Revised again.

Partially commonize the codes regarding ReleaseSemaphore() in raw_read().

-- 
Takashi Yano <takashi.yano@nifty.ne.jp>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Cygwin-fifo-Utilize-select_sem-for-fifo-as-well-as-p.patch
Type: application/octet-stream
Size: 5271 bytes
Desc: not available
URL: <https://cygwin.com/pipermail/cygwin-developers/attachments/20210910/5618fe45/attachment.obj>


More information about the Cygwin-developers mailing list