public inbox for linux-ia64@vger.kernel.org
 help / color / mirror / Atom feed
* [Linux-ia64] Re: [PATCH] 2.5 - Another user stack size patch
@ 2003-05-23 22:04 David Mosberger
  0 siblings, 0 replies; only message in thread
From: David Mosberger @ 2003-05-23 22:04 UTC (permalink / raw)
  To: linux-ia64

>>>>> On Fri, 23 May 2003 14:15:55 -0400, Martin Hicks <mort@wildopensource.com> said:

  Martin> I hope this user stack size patch is better.

It's better, yes.

  Martin> This one places the RBS based on the max size of the stack.
  Martin> The max size of the user stack is 1TB.

vmareas may not cross region-boundaries.  We set:

# define STACK_TOP	(0x6000000000000000UL + (1UL << (4*PAGE_SHIFT - 12)) - PAGE_SIZE)

so the hard limit on the stack size if (1UL << (4*PAGE_SHIFT - 12)) -
PAGE_SIZE).  I suggest we add:

# define MAX_USER_STACK_SIZE	(1UL << (4*PAGE_SHIFT - 12)) - PAGE_SIZE)
# define STACK_TOP		(0x6000000000000000UL + MAX_USER_STACK_SIZE)

I'm not sure it's a good idea to recalculate the RBS starting address
everything IA64_RBS_BOT is used.  I suspect we should add an rbs_bot
member to the thread-data structure instead (similar to the
start_stack member in the task_struct).  Otherwise, I worry about
getting inconsistencies when RLIMIT_STACK is changed after the
bspstore value has been selected (no, there is probably no issue at
the moment, but I bet it would come around to haunt us in the future).

The rest of the patch looks OK to me (watch your formatting though:
please follow the style of the file you're modifying and use tabs
instead of blanks).  Also, I don't think there is any point declaring

	--david


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2003-05-23 22:04 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-05-23 22:04 [Linux-ia64] Re: [PATCH] 2.5 - Another user stack size patch David Mosberger

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox