annotate testproject/test.mod @ 18:6129643f5c34

Fixed interrupt issue, ds, es, ss, fs and gs were not initialized to 0
author windel
date Sun, 20 Nov 2011 20:35:51 +0100
parents edd70006d3e4
children
rev   line source
8
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
1 module test;
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
2 var
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
3 a,b,c : integer;
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
4
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
5 procedure test(x:integer);
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
6 var y,z:integer;
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
7 begin
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
8 y := x * 3 + 2;
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
9 z := x + y + a;
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
10 end test;
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
11
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
12 procedure add(a:integer; b:integer):integer;
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
13 var
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
14 tmp : integer;
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
15 begin
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
16 tmp := a + b;
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
17 return tmp
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
18 end add;
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
19
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
20 begin
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
21 a := 12;
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
22 b := a * 12 + 33;
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
23 c := a div b + a * b * 99;
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
24 end test.
edd70006d3e4 Started with MDI functions
windel
parents:
diff changeset
25