From: Alex Zarochentsev <zam@namesys.com>
To: Hans Reiser <reiser@namesys.com>
Cc: Andrew Morton <akpm@osdl.org>,
cherry@osdl.org, linux-kernel@vger.kernel.org,
reiserfs-dev@namesys.com
Subject: Re: 2.6.8.1-mm2
Date: Fri, 20 Aug 2004 17:53:21 +0400 [thread overview]
Message-ID: <20040820135321.GY5154@backtop.namesys.com> (raw)
In-Reply-To: <4125AA35.6020900@namesys.com>
On Fri, Aug 20, 2004 at 12:37:25AM -0700, Hans Reiser wrote:
> Andrew Morton wrote:
>
> >Hans Reiser <reiser@namesys.com> wrote:
> >
> >
> >>John Cherry wrote:
> >>
> >>
> >>
> >>>The new "errors" are from reiser4 code and they all appear to be...
> >>>
> >>>fs/reiser4/reiser4.h:18:2: #error "Please turn 4k stack off"
> >>>
> >>>
> >>>
> >>>
> >>>
> >>zam, can you or Mr. Demidov work on using kmalloc to reduce stack usage?
> >>
> >>Andrew suggested that for statically sized objects kmalloc is quite fast
> >>(one instruction I think he said), so my objection to kmallocing a lot
> >>has faded.
> >>
> >>
> >
> >err, not that quick - but it's pretty quick.
> >
> >With a kmalloc with a constant size and, preferably, a constant gfp mask
> >we'll jump directly into __cache_alloc() and in the common case we'll pluck
> >an entry directly out of the cpu-local head array:
> >
> >So the kmalloc fastpath is, effectively:
> >
> > local_irq_save(save_flags);
> > ac = ac_data(cachep);
> > if (likely(ac->avail)) {
> > ac->touched = 1;
> > objp = ac_entry(ac)[--ac->avail];
> > }
> > local_irq_restore(save_flags);
> > return objp;
> >
> >
> >Not bad...
> >
> >
> >
> >
> but not trivial. Sigh. It means determining whether we can get below
> 4k without performance loss requires detailed code examination to
> determine what is using up the stack in practice, and discussion.
>
> Well, maybe zam has a comment.
yes. there are large objects (reiser4 context, balancing pools, ...) which
reiser4 allocates on stack. we will use kmalloc/slab for them and see how
performance is changed. not trivial things will be required if those fixes
would not enough.
>
> Hans
--
Alex.
next prev parent reply other threads:[~2004-08-20 13:59 UTC|newest]
Thread overview: 47+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-08-19 8:42 2.6.8.1-mm2 Andrew Morton
2004-08-19 9:10 ` 2.6.8.1-mm2 Ryan Cumming
2004-08-19 9:35 ` 2.6.8.1-mm2 Chris Wedgwood
2004-08-23 21:25 ` 2.6.8.1-mm2 Adrian Bunk
2004-08-25 18:32 ` 2.6.8.1-mm2 Bill Davidsen
2004-08-19 9:12 ` 2.6.8.1-mm2 Dipankar Sarma
2004-08-19 11:36 ` 2.6.8.1-mm2 Gene Heskett
2004-08-19 12:29 ` [PATCH] 2.6.8.1-mm2 --- UML build fixes Chris Wedgwood
2004-08-19 20:55 ` Sam Ravnborg
2004-08-19 21:19 ` Jeff Dike
2004-08-19 22:32 ` Sam Ravnborg
2004-08-19 14:43 ` 2.6.8.1-mm2 Michael Geithe
2004-08-19 14:52 ` 2.6.8.1-mm2 John Cherry
2004-08-19 14:29 ` 2.6.8.1-mm2 Alan Cox
2004-08-20 7:06 ` 2.6.8.1-mm2 Hans Reiser
2004-08-20 7:16 ` 2.6.8.1-mm2 Andrew Morton
2004-08-20 7:37 ` 2.6.8.1-mm2 Hans Reiser
2004-08-20 13:53 ` Alex Zarochentsev [this message]
2004-08-20 18:05 ` 2.6.8.1-mm2 Hans Reiser
[not found] ` <200408191245.46726.gene.heskett@verizon.net>
[not found] ` <20040819182752.GA3024@viasys.com>
2004-08-19 19:17 ` 2.6.8.1-mm2 Gene Heskett
2004-08-20 1:51 ` 2.6.8.1-mm2 Gene Heskett
2004-08-20 0:50 ` 2.6.8.1-mm2 Marcelo Tosatti
2004-08-20 1:08 ` 2.6.8.1-mm2 Nathan Lynch
2004-08-20 1:16 ` 2.6.8.1-mm2 Andrew Morton
2004-08-20 7:40 ` 2.6.8.1-mm2 Rusty Russell
2004-08-20 8:14 ` 2.6.8.1-mm2 Ingo Molnar
2004-08-20 8:29 ` 2.6.8.1-mm2 Srivatsa Vaddagiri
2004-08-20 8:59 ` 2.6.8.1-mm2 Ingo Molnar
2004-08-20 9:03 ` 2.6.8.1-mm2 Ingo Molnar
2004-08-21 7:51 ` 2.6.8.1-mm2 Rusty Russell
2004-08-20 8:33 ` 2.6.8.1-mm2 Ingo Molnar
2004-08-20 21:35 ` 2.6.8.1-mm2 Andrew Morton
2004-08-20 22:12 ` 2.6.8.1-mm2 Nathan Lynch
2004-08-20 6:17 ` 2.6.8.1-mm2 Srivatsa Vaddagiri
2004-08-20 6:59 ` 2.6.8.1-mm2 Paul Mackerras
2004-08-20 8:21 ` 2.6.8.1-mm2 ismail dönmez
2004-08-20 22:43 ` 2.6.8.1-mm2 Rik van Riel
2004-08-20 23:05 ` 2.6.8.1-mm2 - reiser4 Rik van Riel
2004-08-20 23:15 ` William Lee Irwin III
2004-08-20 23:20 ` Anton Blanchard
2004-08-20 23:34 ` Andrew Morton
2004-08-21 0:12 ` Rik van Riel
2004-08-21 6:24 ` Hans Reiser
2004-08-21 0:15 ` Rik van Riel
2004-08-21 8:57 ` Hans Reiser
2004-08-21 7:30 ` 2.6.8.1-mm2 Hans Reiser
2004-08-22 21:32 ` 2.6.8.1-mm2 Alex Zarochentsev
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=20040820135321.GY5154@backtop.namesys.com \
--to=zam@namesys.com \
--cc=akpm@osdl.org \
--cc=cherry@osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=reiser@namesys.com \
--cc=reiserfs-dev@namesys.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