source: Deliverables/D2.2/8051/src/ASM/I8051.mli @ 486

Last change on this file since 486 was 486, checked in by ayache, 9 years ago

Deliverable D2.2

File size: 1.3 KB
RevLine 
[486]1
2include Arch.S
3
4type opaccs =
5  | Mul
6  | Divu
7  | Modu
8
9type op1 =
10  | Cmpl
11  | Inc
12
13type op2 =
14  | Add
15  | Addc
16  | Sub
17  | And
18  | Or
19  | Xor
20
21val print_opaccs : opaccs -> string
22val print_op1 : op1 -> string
23val print_op2 : op2 -> string
24
25module Eval (Val : Value.S) : sig
26  val opaccs : opaccs -> Val.t -> Val.t -> Val.t
27  val op1    : op1 -> Val.t -> Val.t
28  val op2    : Val.t (* carry *) -> op2 -> Val.t -> Val.t ->
29               (Val.t (* returned value *) * Val.t (* new carry value *))
30end
31
32(* Not supported: signed division, signed modulo, shift operations. *)
33
34type register
35val compare_reg : register -> register -> int
36val eq_reg      : register -> register -> bool
37
38module RegisterSet : Set.S with type elt = register
39module RegisterMap : Map.S with type key = register
40
41val a : register
42val b : register
43val dpl : register
44val dph : register
45val spl : register
46val sph : register
47val st0 : register
48val st1 : register
49val sst : register
50val carry : register (* only used for the liveness analysis *)
51
52val registers : RegisterSet.t
53val parameters : register list
54val callee_saved : RegisterSet.t
55val caller_saved : RegisterSet.t
56val allocatable : RegisterSet.t
57val forbidden : RegisterSet.t
58
59val print_register : register -> string
60
61val reg_addr : register -> [> ASM.direct]
Note: See TracBrowser for help on using the repository browser.