| 1 |
(* unimplemented-c-calls.sml |
| 2 |
* |
| 3 |
* A dummy (placeholder) "implementation" of the c-calls interface. |
| 4 |
* |
| 5 |
* Copyright (c) 2004 by The Fellowship of SML/NJ |
| 6 |
*) |
| 7 |
functor UnimplementedCCallsFn |
| 8 |
(structure T: MLTREE |
| 9 |
val impossible: string -> 'a) :> C_CALLS (* where T = T *) |
| 10 |
where type T.Basis.cond = T.Basis.cond |
| 11 |
and type T.Basis.div_rounding_mode = T.Basis.div_rounding_mode |
| 12 |
and type T.Basis.ext = T.Basis.ext |
| 13 |
and type T.Basis.fcond = T.Basis.fcond |
| 14 |
and type T.Basis.rounding_mode = T.Basis.rounding_mode |
| 15 |
and type T.Constant.const = T.Constant.const |
| 16 |
and type ('s,'r,'f,'c) T.Extension.ccx = ('s,'r,'f,'c) T.Extension.ccx |
| 17 |
and type ('s,'r,'f,'c) T.Extension.fx = ('s,'r,'f,'c) T.Extension.fx |
| 18 |
and type ('s,'r,'f,'c) T.Extension.rx = ('s,'r,'f,'c) T.Extension.rx |
| 19 |
and type ('s,'r,'f,'c) T.Extension.sx = ('s,'r,'f,'c) T.Extension.sx |
| 20 |
and type T.I.div_rounding_mode = T.I.div_rounding_mode |
| 21 |
and type T.Region.region = T.Region.region |
| 22 |
and type T.ccexp = T.ccexp |
| 23 |
and type T.fexp = T.fexp |
| 24 |
(* and type T.labexp = T.labexp *) |
| 25 |
and type T.mlrisc = T.mlrisc |
| 26 |
and type T.oper = T.oper |
| 27 |
and type T.rep = T.rep |
| 28 |
and type T.rexp = T.rexp |
| 29 |
and type T.stm = T.stm = |
| 30 |
struct |
| 31 |
structure T = T |
| 32 |
|
| 33 |
datatype c_arg |
| 34 |
= ARG of T.rexp |
| 35 |
| FARG of T.fexp |
| 36 |
| ARGS of c_arg list |
| 37 |
|
| 38 |
fun genCall _ = impossible "C-calls not implemented (genCall)" |
| 39 |
|
| 40 |
val paramAreaOffset = 0 |
| 41 |
|
| 42 |
val naturalIntSz = 32 |
| 43 |
|
| 44 |
datatype arg_location |
| 45 |
= Reg of T.ty * T.reg * T.I.machine_int option |
| 46 |
| FReg of T.fty * T.reg * T.I.machine_int option |
| 47 |
| Stk of T.ty * T.I.machine_int |
| 48 |
| FStk of T.fty * T.I.machine_int |
| 49 |
| Args of arg_location list |
| 50 |
|
| 51 |
fun layout _ = impossible "C-calls not implemented (layout)" |
| 52 |
|
| 53 |
val calleeSaveRegs : T.reg list = [] |
| 54 |
val calleeSaveFRegs : T.reg list = [] |
| 55 |
end |