Subject: Re: Kernel profiling - solved? (or where, oh where has nullproc gone?)
To: Jason Thorpe <thorpej@nas.nasa.gov>
From: Jonathan Stone <jonathan@DSG.Stanford.EDU>
List: tech-kern
Date: 02/28/1999 12:57:16
I think the mips problem is that the mips switch_exit() is clobbering
the proc0 stack pointer. Instead of running on top of any existing
proc0 kernel stack, the mips switch_exit() is re-setting the kernel
stack pointer as if proc0 had no stack.
When switch_exit()'s stack puking grows beyond the frames into which
uvm_scheduler never returns (main()?), that clobbers uvm_scheduler's
stack.
if we fix mips switch_exit() to slurp the current sp from proc0's
regs, it should Just Work, SW tlb misses and all.
Sure,, we'll need multiple idle threads for one-big-lock {a}symmetric
MP. Thinking of it as `multiple interrupt stacks' with idle() running
on the per-CPU interrupt stack works for me.