home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Shareware 1 2 the Maxx
/
sw_1.zip
/
sw_1
/
PROGRAM
/
DJLSR106.ZIP
/
LIBSRC
/
C
/
DOS
/
INT86X.S
< prev
next >
Wrap
Text File
|
1992-03-02
|
786b
|
57 lines
.data
int86:
.byte 0xcd
int86_vec:
.byte 0x03
jmp int86_retjmp
.text
.globl _int86x
_int86x:
.globl _int86
_int86:
pushl %ebp
movl %esp,%ebp
pushl %ebx
pushl %esi
pushl %edi
pushf
movl 8(%ebp),%eax
movb %al,int86_vec
movl 12(%ebp),%eax
movl 4(%eax),%ebx
movl 8(%eax),%ecx
movl 12(%eax),%edx
movl 16(%eax),%esi
movl 20(%eax),%edi
movl (%eax),%eax
jmp int86
int86_retjmp:
pushf
pushl %eax
movl %esp,%ebp
addl $24,%ebp
movl 16(%ebp),%eax
popl (%eax)
movl %ebx,4(%eax)
movl %ecx,8(%eax)
movl %edx,12(%eax)
movl %esi,16(%eax)
movl %edi,20(%eax)
popl %ebx /* flags */
movl %ebx,28(%eax)
andl $1,%ebx
movl %ebx,24(%eax)
movl (%eax),%eax
popf
popl %edi
popl %esi
popl %ebx
popl %ebp
ret