Skip to content

Commit

Permalink
Cygwin: pipe: Fix a regression that raw_write() slows down
Browse files Browse the repository at this point in the history
After the commit 7f3c22532577, writing to pipe extremely slows down.
This is because cygwait(select_sem, 10, cw_cancel) is called even
when write operation is already completed. With this patch, the
cygwait() is called only if the write operation is not completed.

Backported-from: 37ab3e0d55 (Cygwin: pipe: Fix a regression that raw_write() slows down, 2024-09-01)
Addresses: https://cygwin.com/pipermail/cygwin/2024-August/256398.html
Fixes: 7f3c22532577 ("Cygwin: pipe: handle signals explicitely in raw_write")
Reported-by: Jim Reisert AD1C <jjreisert@alum.mit.edu>
Reviewed-by: Corinna Vinschen <corinna@vinschen.de>
Signed-off-by: Takashi Yano <takashi.yano@nifty.ne.jp>
(cherry picked from commit f78009cb1ccf84cc343cf2441c76196461d87532)
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
  • Loading branch information
tyan0 authored and dscho committed Sep 25, 2024
1 parent 900a410 commit 8854bb4
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions winsup/cygwin/release/3.5.5
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,6 @@ Fixes:
- Fix undesired behaviour of console master thread in win32-input-mode
which is supported by Windows Termainal.
Addresses: https://cygwin.com/pipermail/cygwin/2024-August/256380.html

- Fix a regression in 3.5.4 that writing to pipe extremely slows down.
Addresses: https://cygwin.com/pipermail/cygwin/2024-August/256398.html

0 comments on commit 8854bb4

Please sign in to comment.