K 10 svn:author V 6 marcel K 8 svn:date V 27 2011-05-14T14:55:15.778279Z K 7 svn:log V 589 Prefer switching the memory stack from user to kernel *before* switching the register stack. While the ordering doesn't matter, it creates an invariant not previously there: the memory stack pointer will always be larger than the register stack pointer. With this invariant in place, it's easier to add instrumentation code that detects a stack overflow because in such a scenario the memory stack pointer and register stack pointers have crossed each other. Aside: basic kernel operation needs about half the stack size (~16K) at most. We have plenty of head room on the kernel stack... END