RE: [PATCH] debug: Do not permit CONFIG_DEBUG_STACK_USAGE=y on IA64or PARISC

From: Luck, Tony
Date: Wed Jul 25 2012 - 14:23:15 EST


> Since the problem is an invalid assumption about how the stack grows,
> why not just condition it on that. We actually have a config option for
> this: CONFIG_STACK_GROWSUP. But for some reason ia64 doesn't define
> this, why not, Tony? It looks deliberate because you have replaced a
> lot of
>
> #ifdef CONFIG_STACK_GROWSUP
>
> with
>
> #if defined(CONFIG_STACK_GROWSUP) || defined(CONFIG_IA64)
>
> but not all of them.

ia64 is special - we have stacks that grow both upwards and downwards!

The typical "C" stack for local function variables that need to be allocated in
memory (arrays, structures, things we take the address of, things that just
don't fit because we run out of registers) grows downwards. But local
variables assigned to registers get quietly saved away to an upwards growing
stack by the register stack engine (working somewhat asynchronously from
the cpu).l

-Tony
N‹§²æìr¸›yúèšØb²X¬¶ÇvØ^–)Þ{.nÇ+‰·¥Š{±‘êçzX§¶›¡Ü}©ž²ÆzÚ&j:+v‰¨¾«‘êçzZ+€Ê+zf£¢·hšˆ§~†­†Ûiÿûàz¹®w¥¢¸?™¨è­Ú&¢)ßf”ù^jÇy§m…á@A«a¶Úÿ 0¶ìh®å’i