How do i calculate the physical address of any given interrupt (INT22H or INT15H for instance) in the interrupt vector table for 8086 microprocessor?
How to find the physical address of interrupts in interrupt vector table?
6.6k views Asked by Ahsan Sadeeb At
1
Physical address where the
int 15h
instruction finds the far pointer that it shouldcall
.This is an offset within the Interrupt Vector Table, and so gives a physical address aka linear address from the list {0,4,8,12, ... , 1016,1020}.
Since each vector is 4 bytes long, all it takes is multiplying the interrupt number by 4.
(*) I like all my linear addresses expressed as DX:AX. That's why I used the seemingly unnecessary
cwd
instruction.Physical address where
int 15h
ultimately gets handled.This can be anywhere in the 1MB memory. (On 8086 there's no memory beyond 1MB).
Each 4 byte vector consists of an offset word followed by a segment word. The order is important.
The linear address is calculated from multiplying the segment value by 16 and adding the offset value.