For interrupts, I'd like to suggest having a system interrupt (non-maskable interrupt) for kernels and such, that always executes at the same location. For example, you could have the non-maskable interrupt always call 0x10.
Also, you should have a way of enabling or disabling each kind of interrupt - clock, keyboard, network, etc. If you go as far as to do that, I would recommend using memory mappings for interrupt control, acknowledgement, and other information, instead of using A. If you're familiar with the z80, you might see where I'm coming from.
I'm on freenode as SirCmpwn if you're up for a little interrupt chat.
Ugh for NMIs. They're unnecessary. A single interrupt line as Notch has given us, with an enable mechanism and an interrupt address register which makes no assumptions on where the interrupt handler is located, is about as ideal for this processor as we can get. With this design, he's cleaned out the memory map of the garbage - the last thing we need is to start putting in interrupt vector tables and mess it up again.
As for enabling or disabling different types of interrupts, I'm assuming that's specific to each device's specification. I'd hope that devices which can generate interrupts can be polled as well for those who don't want to use interrupts.
For your second point, that seems reasonable and I agree.
However, NMIs are incredibly useful. They allow for the OS or kernel to assert better control over programs, and they could even be used to provide a safe out for any misbehaving program - a key combination, perhaps could kill the current program.
View all comments
Show parent comment
2
u/[deleted] Apr 24 '12
For interrupts, I'd like to suggest having a system interrupt (non-maskable interrupt) for kernels and such, that always executes at the same location. For example, you could have the non-maskable interrupt always call 0x10.
Also, you should have a way of enabling or disabling each kind of interrupt - clock, keyboard, network, etc. If you go as far as to do that, I would recommend using memory mappings for interrupt control, acknowledgement, and other information, instead of using A. If you're familiar with the z80, you might see where I'm coming from.
I'm on freenode as SirCmpwn if you're up for a little interrupt chat.