From: Milan Broz <mbroz@redhat.com>
To: lvm-devel@redhat.com
Subject: [PATCH 2/3] Set our own in/out buffers
Date: Sat, 26 Mar 2011 11:09:17 +0100 [thread overview]
Message-ID: <4D8DBB4D.9060604@redhat.com> (raw)
In-Reply-To: <49609a18834f11b833c31a164a2b467dd52095f3.1301089240.git.zkabelac@redhat.com>
On 03/25/2011 10:57 PM, Zdenek Kabelac wrote:
> Memory lock from critical_section is now being kept over the critical
> section - mallopt() should ensure, that mmap is not used for allocation,
> and we preallocate some memory to be able to satisfy some small
> alloc request. However when glibc needs buffers for line buffering of
> input and output buffers - it allocates these buffers in such way it
> adds memory page for each such buffer and size of unlock memory check will
> mismatch by 1 or 2 pages.
ack in principle, these warnings appears quite often on various places
and distract people form real problems.
> + static char inbuf[4096];
> + static char outbuf[4096];
Because we are handling stdin/stdout, I think this call is common
for glibc, right?
Shouldn't this be initialized only once (do we support multiple command
contexts, IOW reentrant code here)? Is create_toolcontext() the right
place for it?
Milan
next prev parent reply other threads:[~2011-03-26 10:09 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-03-25 21:57 [PATCH 0/3] Memory fixes Zdenek Kabelac
2011-03-25 21:57 ` [PATCH 1/3] Fix mem Zdenek Kabelac
2011-03-26 9:59 ` Milan Broz
2011-03-26 13:04 ` Zdenek Kabelac
2011-03-25 21:57 ` [PATCH 2/3] Set our own in/out buffers Zdenek Kabelac
2011-03-26 10:09 ` Milan Broz [this message]
2011-03-26 12:53 ` Zdenek Kabelac
2011-04-04 12:09 ` Zdenek Kabelac
2011-03-25 21:57 ` [PATCH 3/3] Valgrind updates Zdenek Kabelac
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=4D8DBB4D.9060604@redhat.com \
--to=mbroz@redhat.com \
--cc=lvm-devel@redhat.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.