public inbox for cygwin-developers@cygwin.com
 help / color / mirror / Atom feed
From: "Teemu Nätkinniemi" <tnatkinn@gmail.com>
To: "cygwin-developers@cygwin.com" <cygwin-developers@cygwin.com>
Subject: Re: Maybe consider rpmalloc
Date: Wed, 14 Apr 2021 21:36:12 +0300	[thread overview]
Message-ID: <CAEHcbmeURDJzni6a-dpEUv6BCYJe8o_Cc8+E+y8EPC1cpC=9WA@mail.gmail.com> (raw)
In-Reply-To: <93809c4f-7747-3611-0d20-bde09e091f1d@maxrnd.com>

ke 14. huhtik. 2021 klo 12.20 Mark Geisert (mark@maxrnd.com) kirjoitti:
>
> Teemu Nätkinniemi wrote:
> > Thanks a lot for looking into this issue! I wonder if there are any
> > other applications affected by this?
>
> We have several examples by now.  All are (relatively) long-lasting apps, with
> high to very high memory allocation churn, often multi-threaded.  I believe some
> specific rsync operations hit this.  Achim reported a zstd operation that
> exhibited the symptoms.  And I've been attempting to get a working replacement for
> Cygwin's malloc for some time but every malloc I've tested, several of them,
> exhibits similar symptoms: excessive time being spent in ntdll.dll presumably
> supporting the memory operations.

Bwa's author has a more recent program called bwa-mem2 which seems to
have exact same problem as bwa. I have tried the rpmalloc trick but it
did not work or I could not identify the correct routine(s).

https://github.com/bwa-mem2/bwa-mem2

> Your rpmalloc "hack" is interesting in that you aren't using Cygwin's mmap()
> underneath the malloc routines; you're calling Windows VM ops directly.  Not sure
> yet what all the implications are.

It was not my hack. Just a third party who managed to fix the problem
as bwa is actually a useful program and there was a need to get it
running on Windows/Cygwin.

> Lots of plausible directions to go...

I am thankful that you are looking into this. Does anyone else have
any input that could be useful? Corinna?

Teemu

  reply	other threads:[~2021-04-14 18:36 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-25  6:01 Cygwin malloc tune-up status Mark Geisert
2020-09-27 16:54 ` Johannes Schindelin
2020-09-29  2:22   ` Mark Geisert
2021-04-01  9:19     ` Teemu Nätkinniemi
2021-04-02  5:45       ` Maybe consider rpmalloc -- Was: " Mark Geisert
2021-04-03  2:53         ` Maybe consider rpmalloc Mark Geisert
2021-04-03  6:46           ` Teemu Nätkinniemi
2021-04-03  6:48             ` Teemu Nätkinniemi
2021-04-11  9:28               ` Mark Geisert
2021-04-12  8:48                 ` Teemu Nätkinniemi
2021-04-13  8:24                   ` Mark Geisert
2021-04-13 13:05                     ` Teemu Nätkinniemi
2021-04-14  8:19                       ` Mark Geisert
2021-04-14 18:36                         ` Teemu Nätkinniemi [this message]
2021-04-14 18:53                         ` Jon Turney
2021-04-19  5:16                           ` Mark Geisert
2021-04-20 19:34                             ` Jon Turney

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='CAEHcbmeURDJzni6a-dpEUv6BCYJe8o_Cc8+E+y8EPC1cpC=9WA@mail.gmail.com' \
    --to=tnatkinn@gmail.com \
    --cc=cygwin-developers@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).