public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: Alexey Izbyshev <izbyshev@ispras.ru>
To: cygwin@cygwin.com
Subject: Re: Deadlock of the process tree when running make
Date: Mon, 11 Apr 2022 16:27:37 +0300	[thread overview]
Message-ID: <ac1a3221584c22a1f413db6cc2688c4c@ispras.ru> (raw)
In-Reply-To: <80ad73a8-16f0-81bd-aa92-1cd22550c2ba@SystematicSw.ab.ca>

On 2022-04-08 20:04, Brian Inglis wrote:
> On 2022-04-08 02:42, Alexey Izbyshev wrote:
>> There is also an additional detail that I forgot to mention: in the 
>> stack trace of all leaf processes as displayed by ProcessHacker, it 
>> seems that the executable entry point is not reached yet. The only 
>> non-Windows-DLL location is in cygwin1.dll, so I suspect that all 
>> processes hang at early initialization in Cygwin's DLL entry point.
> 
> That sounds like BLODA interference from AntiVirus programs:
> 
> 	https://cygwin.com/faq/faq.html#faq.using.bloda
> 
> and can also happen if you use Windows AD, and your users have a lot
> of rights, and a slow server, firewall filtering, or network link, but
> known issues were fixed a few releases ago.
> 

It seems that a potential cause of the hang has been identified in 
another discussion thread, and I'm now testing a patched version 
provided by Takashi Yano.

Anyway, thanks for your time! And just in case the identified cause 
turns out to be wrong, I'm answering your questions below.

We don't use any third-party AV products on this machine (it's an 
internal box used only for CI), and we've disabled Real-Time Protection 
in the Windows AV (it causes a terrible performance degradation, 
something like 1.5-2 times).

> Any idea how much address space is used by Cygwin DLLs, and memory by
> all the processes running: run rebase -is to see if you could be out
> of address space for Cygwin and DLLs, and how much is left for
> processes?
> 
> Do you have a decent amount of memory free on your system while
> running, and Windows paging space allocated to back it up - total
> twice memory, and do you have multiple drives to spread it across?
> Check your system memory and paging activity while those processes are 
> running.
> 
The peak memory consumption of our tests never exceeds 30% of RAM. Also, 
Cygwin is used (almost) exclusively for the test harness (the actual 
software under testing is native), and there are no heavyweight 
processes in it, mostly just make, bash and some coreutils. So I don't 
think we could hit address space issues even on 32-bit Cygwin.

> Could you try installing Cygwin64 packages and running those instead
> of Cygwin32 (recommended as Cygwin32 support will be dropped next
> release) as there is more address space available as well as usable
> memory for processes?

We test both 32-bit and 64-bit builds of our software, and a couple of 
tests need to run (Cygwin) make under debugging. Because a 32-bit 
process can't debug a 64-bit one, we simply use 32-bit Cygwin for both 
cases. But if need to reproduce under 64-bit Cygwin arises, I can simply 
exclude the problematic tests (they're unlikely to be relevant to the 
hang).

Alexey

  reply	other threads:[~2022-04-11 13:27 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-07 21:53 Alexey Izbyshev
2022-04-07 23:54 ` Brian Inglis
2022-04-08  8:42   ` Alexey Izbyshev
2022-04-08 17:04     ` Brian Inglis
2022-04-11 13:27       ` Alexey Izbyshev [this message]
2022-04-09 10:17 ` Takashi Yano
2022-04-09 11:00   ` Alexey Izbyshev
2022-04-09 11:02     ` Alexey Izbyshev
2022-04-09 11:46       ` Takashi Yano
2022-04-09 16:07         ` Alexey Izbyshev
2022-04-09 16:57           ` Takashi Yano
2022-04-09 17:23             ` Alexey Izbyshev
2022-04-09 17:54               ` Takashi Yano
2022-04-09 19:35                 ` Alexey Izbyshev
2022-04-09 20:26                   ` Alexey Izbyshev
2022-04-10  7:34                     ` Takashi Yano
2022-04-10 12:13                       ` Alexey Izbyshev
2022-04-10 20:49                         ` Alexey Izbyshev
2022-04-11  8:35                           ` Takashi Yano
2022-04-11 10:10                             ` Alexey Izbyshev
2022-04-13 16:48                               ` Alexey Izbyshev
2022-04-13 17:22                                 ` Takashi Yano
2022-04-13 17:27                                   ` Alexey Izbyshev
2022-04-13 23:17                                 ` Alexey Izbyshev
2022-04-16  9:39                                   ` Takashi Yano
2022-04-16 13:21                                     ` Alexey Izbyshev
2022-04-27 11:22                                       ` Takashi Yano
2022-04-27 12:19                                         ` Alexey Izbyshev
2022-04-11  5:23               ` Jeremy Drake
2022-04-11  8:36                 ` Takashi Yano
2022-04-11 15:28                 ` Alexey Izbyshev
2022-04-11 17:02                   ` Jeremy Drake

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ac1a3221584c22a1f413db6cc2688c4c@ispras.ru \
    --to=izbyshev@ispras.ru \
    --cc=cygwin@cygwin.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).