1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43
|
(*
* This file was automatically generated by MDGen (v3.0)
* from the machine description file "ppc/ppc.md".
*)
functor PPCDelaySlots(structure I : PPCINSTR
structure P : INSN_PROPERTIES (* where I = I *)
where type I.addressing_mode = I.addressing_mode
and type I.ea = I.ea
and type I.instr = I.instr
and type I.instruction = I.instruction
and type I.operand = I.operand
) : DELAY_SLOT_PROPERTIES =
struct
structure I = I
datatype delay_slot = D_NONE | D_ERROR | D_ALWAYS | D_TAKEN | D_FALLTHRU
fun error msg = MLRiscErrorMsg.error("PPCDelaySlots",msg)
val delaySlotSize = 4
fun delaySlot {instr, backward} = let
fun delaySlot instr =
(
case instr of
_ => {nop=true, n=false, nOn=D_ERROR, nOff=D_NONE}
)
in delaySlot instr
end
fun enableDelaySlot _ = error "enableDelaySlot"
fun conflict _ = error "conflict"
fun delaySlotCandidate {jmp, delaySlot} = let
fun delaySlotCandidate delaySlot =
(
case delaySlot of
_ => true
)
in delaySlotCandidate delaySlot
end
fun setTarget _ = error "setTarget"
end
|