Ok, it's more efficient to insert an interrupt call into the
instruction stream in the decoder: all the in-flight instructions will
be completed instead of going to waste. However, the interrupt will
usually be serviced later, and, as you point out, if the instruction
stream is redirected for some other reason, you may have to replay the >interrupt.
On Sat, 05 Oct 2024 17:57:12 GMT, [email protected]
(Anton Ertl) wrote:
Ok, it's more efficient to insert an interrupt call into the
instruction stream in the decoder: all the in-flight instructions will
be completed instead of going to waste. However, the interrupt will
usually be serviced later, and, as you point out, if the instruction
stream is redirected for some other reason, you may have to replay the
interrupt.
A _trap_ can be a problem on an out-of-order machine, since traps
result from exceptions, and so they have to be tied to the instruction stream.
An interrupt, on the other hand, just needs to get serviced. The
process being interrupted just needs not to be disturbed by it.
That leaves several alternatives.
You could somehow make the machine act as if it has a second core just
to serve interrupts. In fact, some early architectures anticipated SMT
by having a second set of registers for privileged operation.
Or, since interrupt routines _are_ at kernel level... when there's an interrupt, save the whole internal machine state, including the entire pipeline. After all, since interrupt routines are privileged, they can
use a special return instruction that sets up the machine's internals
instead of just restoring registers and branching somewhere.
So, while interrupts _can_ be an issue for an OoO machine, they don't
really have to be.
John Savard
On Sat, 05 Oct 2024 17:57:12 GMT, [email protected]
(Anton Ertl) wrote:
Ok, it's more efficient to insert an interrupt call into the
instruction stream in the decoder: all the in-flight instructions will
be completed instead of going to waste. However, the interrupt will >usually be serviced later, and, as you point out, if the instruction
stream is redirected for some other reason, you may have to replay the >interrupt.
A _trap_ can be a problem on an out-of-order machine, since traps
result from exceptions, and so they have to be tied to the instruction stream.
An interrupt, on the other hand, just needs to get serviced. The
process being interrupted just needs not to be disturbed by it.
That leaves several alternatives.
You could somehow make the machine act as if it has a second core just
to serve interrupts. In fact, some early architectures anticipated SMT
by having a second set of registers for privileged operation.
Or, since interrupt routines _are_ at kernel level... when there's an interrupt, save the whole internal machine state, including the entire pipeline. After all, since interrupt routines are privileged, they can
use a special return instruction that sets up the machine's internals
instead of just restoring registers and branching somewhere.
So, while interrupts _can_ be an issue for an OoO machine, they don't
really have to be.
John Savard--- Synchronet 3.22a-Linux NewsLink 1.2
| Sysop: | DaiTengu |
|---|---|
| Location: | Appleton, WI |
| Users: | 1,142 |
| Nodes: | 10 (0 / 10) |
| Uptime: | 91:05:54 |
| Calls: | 14,704 |
| Calls today: | 2 |
| Files: | 186,497 |
| D/L today: |
1,894 files (564M bytes) |
| Messages: | 2,551,613 |