This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: bash, find | xargs grep



>I wish that fork would fail with errno set, so that bash's error message
>is not so confusing; but that is besides the point.  Running out of memory
>during forks is not a bug in bash, find, or xargs, but a limitation of
>Windows.  If anyone has ideas on how to reduce the frequency of fork
>failures, patches are more than welcome, but the main developers have
>pretty much tried everything imaginable.  The solutions (workarounds?) on
>this list have generally been to disable the third-party .dll that is
>causing the interference.

Hi Eric,
Regarding your previous message, regarding Microsoft information, if you are talking about the SharedSection limitation which makes program running out of memory even if lot of memory is free, the only solution is not to link & use user32 objects as defined in this Microsoft technote (http://support.microsoft.com/default.aspx?scid=kb;EN-US;184802) :
"Desktop heap is allocated by User32.dll when a process is in need of user objects. If an application is not dependent on User32.dll, it will not consume desktop heap. "

& One another problem is to be sure that no other third parties program introduces user32 dependencies in the running process like antivirus as you said Eric  ...

& so to be sure that all others implemented libraries don't call also APIs in user32..

Another way, is to write a Desktop Manager for configuring the number of cygwin process you want to run inside & to have a new desktop created automatically when this limit is reached & to re-attach the instance of a new cygwin process under one of these desktop when another cygwin program exited from it...
But it needs also more communication through pipes & other in cygwin1.dll for having cygwin programs communicating with the cygwin desktop manager...
That's only an idea, but it is not also really simple to configure & needs to add more parameter in cygwin like :
number_of_desktops
number_of_process_in_a_desktop
....
& maybe another option like : attach_non_process_desktop_to_caller_one meaning that if cygwin try to start a non cygwin application it will attach this application in the winstation/desktop of the caller/launcher of the first cygwin program in the tree....


I don't know if you could consider my mail as a contribution, but I hope (in the case of you was talking about this limitation ;) ) ;)
Louis


- --
Life is short - so eat dessert first!

Eric Blake             ebb9@byu.net
volunteer cygwin findutils maintainer
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.1 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFEF5XP84KuGfSFAYARAkiEAKCkbErPJD+ODomDTpXuIEtFPdSy4gCgh9se
Gr7JO9j78dVgJVKP+1/D8Og=
=/TqW
-----END PGP SIGNATURE-----

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]