News for hackers. Stuff that matters.
Re:Reasons for using Golang by sid0 on Sunday June 12, 2011 @06:35AM (#2646244)
The process scheduler must have direct access to physical memory in order to perform this transition.

Given that a scheduler's going to be running in kernel mode, why can it not just muck around with kernel address space and leave it to the page table to do the translation?

Yeah, I did clarify my request a little -- by safe I meant safe with optional nullability.

Re:Reasons for using Golang by ori_b on Sunday June 12, 2011 @07:45AM (#2646309)
How does it muck about with the kernel address space again? Oh right, by writing to magic locations in memory. The same way that you interface with virtually all hardware, for that matter.
Re:Reasons for using Golang by sid0 on Sunday June 12, 2011 @03:03PM (#2647126)
No, you misunderstand: I believe most of the operations you need to perform a context switch are safe in the kernel's context. Sure, you'll need a bit of assembly code to copy out and set registers and stuff, and you can't do that bit in C either. But other than that, safe pointers should work.