Line | |
---|
1 | .sect .text; .sect .rom; .sect .data; .sect .bss
|
---|
2 | .define .error
|
---|
3 | .define .Xtrp
|
---|
4 |
|
---|
5 | ! eax is trap number
|
---|
6 | ! all registers must be saved
|
---|
7 | ! because return is possible
|
---|
8 | ! May only be called with error no's <16
|
---|
9 | .sect .text
|
---|
10 | .error:
|
---|
11 | mov ecx,eax
|
---|
12 | mov ebx,1
|
---|
13 | sal ebx,cl
|
---|
14 | .extern .ignmask
|
---|
15 | .extern .trp
|
---|
16 | test ebx,(.ignmask)
|
---|
17 | jne 2f
|
---|
18 | call .trp
|
---|
19 | 2:
|
---|
20 | ret
|
---|
21 |
|
---|
22 | .Xtrp:
|
---|
23 | pusha
|
---|
24 | cmp eax,16
|
---|
25 | jge 1f
|
---|
26 | call .error
|
---|
27 | popa
|
---|
28 | ret
|
---|
29 | 1:
|
---|
30 | call .trp
|
---|
31 | popa
|
---|
32 | ret
|
---|
Note:
See
TracBrowser
for help on using the repository browser.