pipe performance problem

thomas tom@huno.net
Wed Nov 27 19:38:00 GMT 2002



It seems to be a mystery whats going on, at least i'm not clever enough
find it out :(
Both sides of the pipe (cat and dd) wait at the same time, but what for?
Is one waiting for the other and vice versa? I have no idea. Look here:

   23 2139047 [main] cat 3660 fhandler_base::write: binary write
 2234 2141281 [main] cat 3660 fhandler_base::write: DEBUG 0 fhandler.cc
28626 2169907 [main] cat 3660 fhandler_base::write: 1024 = write (0x10021748, 1024)

   25 2128939 [main] dd 1900 fhandler_base::ready_for_read: DEBUG 8.h select.cc
13787 2142726 [main] dd 1900 fhandler_base::ready_for_read: DEBUG 8.c select.cc


Now look at the code where DEBUG 0 is:

  if (get_w_binary ())
    {
      debug_printf ("binary write");
      res = raw_write (ptr, len);
      debug_printf ("DEBUG 0 fhandler.cc");
    }
   // there is an else here, but we dont call it anyway
    
  debug_printf ("%d = write (%p, %d)", res, ptr, len);
  return res;

There's nothing to wait for or is there.

DEBUG 8.h is the WaitForSingleObject.

Maybe i'm still looking at the wrong place.

thomas


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/



More information about the Cygwin mailing list