Re:Writing an OS in Rust: Returning from Exceptions
by amluto on Wednesday September 21, 2016 @06:21PM
(#12552795)
No. In fact, that hardware support is mandatory. The SP0 field is used unconditionally on a cross-privilege exception.
Sadly, AMD64 came up with a terrible design for SYSCALL, and an exception right after SYSCALL will not automatically switch stacks. The result is a big mess.
Sadly, AMD64 came up with a terrible design for SYSCALL, and an exception right after SYSCALL will not automatically switch stacks. The result is a big mess.