mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Tony Luck" <tony.luck@intel.com>
To: "KAMEZAWA Hiroyuki" <kamezawa.hiroyu@jp.fujitsu.com>
Cc: "linux-ia64@vger.kernel.org" <linux-ia64@vger.kernel.org>,
	"dmosberger@gmail.com" <dmosberger@gmail.com>,
	surinder.kumar@oracle.com, LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH][2/2] double stack limit (rfc)
Date: Thu, 22 Mar 2007 21:56:03 -0700	[thread overview]
Message-ID: <12c511ca0703222156u3cc09833rec636b47ad156029@mail.gmail.com> (raw)
In-Reply-To: <20070323122129.555a87fd.kamezawa.hiroyu@jp.fujitsu.com>

On 3/22/07, KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> wrote:
> I hear some people says that "When I set stack-size-limit to 32M,
> I want to use 32M of memory stack..." and register-stack expansion can
> fail because stack is used up by memory-stack.

An interesting dilemma.  If you apply this patch though, you might
get someone complain that they set the stack limit to 32M, but
execution continued as the program ran all the way to 64M!

Possibly you might argue that each of the memory stack and the
RBS stack should be allowed to grow to the stacklimit ... in which
case you'd need a more invasive patch that made separate vma
for each of the stack and the RBS stack, and checked at fault
time each would be allowed to grow to the stack limit.  But I'm
not sure that I like that ... ia64 happens to split different objects
in the stack between the RBS and the memory stack depending
on whether they happen to be allocated by the compiler to
stack registers (r32-r127) or to actual memory locations.  Both
types of allocation contribute to the total "stack" size of the
process so the existing behaivour of keeping the sum of the
size of the RBS stack and the memory stack below the
stack limit seems quite reasonable.  I'm willing to listen to
opposing arguments though.

-Tony

  reply	other threads:[~2007-03-23  4:56 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-03-23  3:21 KAMEZAWA Hiroyuki
2007-03-23  4:56 ` Tony Luck [this message]
2007-03-23  5:23   ` KAMEZAWA Hiroyuki

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=12c511ca0703222156u3cc09833rec636b47ad156029@mail.gmail.com \
    --to=tony.luck@intel.com \
    --cc=dmosberger@gmail.com \
    --cc=kamezawa.hiroyu@jp.fujitsu.com \
    --cc=linux-ia64@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=surinder.kumar@oracle.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

all inboxes | Powered by JetHome®