Idris2Doc : ControlFlow.CBlock

ControlFlow.CBlock

(source)

Definitions

MbPhis : (Listlbl->Type) ->Neighborslbl->Type
  Constructs the type of the phi assignment list of a `CBlock` based on its
predecessors (`ins`).

* For an undefined list of predecessors (`Nothing`), the "list" is of the
unit type, as the phi assignments are impossible to construct in such case.

* For a defined list of predecessors (`Just ins`), the list is an actual
list of phi assignemtns, whose "inputs" coincide with the inputs
(predecessors) of the block.

@ lbl the type of vertex identifiers / block labels
@ phi the type that represents a phi assignment,
parametrized by its input labels
@ ins the predecessors of the block

Visibility: public export
MbTerm : (Listlbl->Type) ->Neighborslbl->Type
  Constructs the type of the terminating instruction of a `CBlock` based on
its successors (`outs`)

* For an undefined list of successors (`Nothing`), the terminator is of the
unit type, as it is impossible to determine its type in such case.

* For a defined list of successors (`Just outs`), the terminator an a ctual
terminating instruction, whose "outputs" concide with the
outputs (successors) of the block.

@ lbl the type of vertex identifiers / block labels
@ term the type that represents the terminating instruction,
parametrized by its output labels
@ outs the succcessors of the block

Visibility: public export
recordCBlock : (Listl->Type) ->Type-> (Listl->Type) ->l->Neighborsl->Neighborsl->Type
  A potentially incomplete basic block.

@ l the type of vertex identifiers / block labels
@ phi the type that represents a phi assignment,
parametrized by its input labels
@ instr the type that represents the simple (non-terminating,
non-phi-assignments)) instructions that the block consists of
@ term the type that represents the terminating instruction,
parametrized by its output labels
@ lbl the label of the block (its identifier)
@ ins the potentially undefined list of the predecessors of the block
@ outs the potentially undefined list of the successors of the block

Totality: total
Visibility: public export
Constructor: 
MkBB : Singletonlbl->MbPhisphiins->Listinstr->MbTermterminatorouts->CBlockphiinstrterminatorlblinsouts
  Make a potentially incomplete basic block

Projections:
.body : CBlockphiinstrterminatorlblinsouts->Listinstr
  The body of the block, i.e. the instructions it consists of.
.phis : CBlockphiinstrterminatorlblinsouts->MbPhisphiins
  The potentially undefined list of phi assignments of the block
.term : CBlockphiinstrterminatorlblinsouts->MbTermterminatorouts
  The potentially undefined instruction that terminates the block
.theLabel : CBlockphiinstrterminatorlblinsouts->Singletonlbl
  the runtime manifestation of the label (the identifier) of the block.

Wrapped in the `Singleton` type constructor to avoid shadowing the type
parameter by the field or vice versa.

Hint: 
Connectable (CBlockphiinstrterminator)
.theLabel : CBlockphiinstrterminatorlblinsouts->Singletonlbl
  the runtime manifestation of the label (the identifier) of the block.

Wrapped in the `Singleton` type constructor to avoid shadowing the type
parameter by the field or vice versa.

Visibility: public export
theLabel : CBlockphiinstrterminatorlblinsouts->Singletonlbl
  the runtime manifestation of the label (the identifier) of the block.

Wrapped in the `Singleton` type constructor to avoid shadowing the type
parameter by the field or vice versa.

Visibility: public export
.phis : CBlockphiinstrterminatorlblinsouts->MbPhisphiins
  The potentially undefined list of phi assignments of the block

Visibility: public export
phis : CBlockphiinstrterminatorlblinsouts->MbPhisphiins
  The potentially undefined list of phi assignments of the block

Visibility: public export
.body : CBlockphiinstrterminatorlblinsouts->Listinstr
  The body of the block, i.e. the instructions it consists of.

Visibility: public export
body : CBlockphiinstrterminatorlblinsouts->Listinstr
  The body of the block, i.e. the instructions it consists of.

Visibility: public export
.term : CBlockphiinstrterminatorlblinsouts->MbTermterminatorouts
  The potentially undefined instruction that terminates the block

Visibility: public export
term : CBlockphiinstrterminatorlblinsouts->MbTermterminatorouts
  The potentially undefined instruction that terminates the block

Visibility: public export
emptyCBlock : CBlockphiinstrtrmlblNothingNothing
  Create `CBlock` that has no instructions
@ lbl the block label

Visibility: export
(++) : CBlockphiinstrterminatorlblinsNothing->CBlockphiinstrterminatorlblNothingouts->CBlockphiinstrterminatorlblinsouts
  Concatenates two blocks
Appends a postfix with undefine inputs to a prefix with undefined outputs.
@ pre the prefix
@ post the postfix

Visibility: export
Fixity Declaration: infixr operator, level 7
(<++) : CBlockphiinstrtrmlblinsNothing->Listinstr->CBlockphiinstrtrmlblinsNothing
  Append a list of simple instructions to the block
Leaves the type signature of the block unchanged
@ pre the block (the prefix)
@ post the instructions (the postfix)

Visibility: export
Fixity Declaration: infixr operator, level 7
(<+) : CBlockphiinstrtrmlblinsNothing->instr->CBlockphiinstrtrmlblinsNothing
  Append a single simple instruction to the block
Leaves the type signature of the block unchanged
@ pre the block (the prefix)
@ post the instruction (the postfix)

Visibility: export
Fixity Declaration: infixr operator, level 7
(<+|) : CBlockphiinstrtrmlblinsNothing->trmouts->CBlockphiinstrtrmlblins (Justouts)
  Defines the outputs of a block by appending to it a terminating
insrtruction
@ pre the block (the prefix)
@ post the terminator (the postfix)

Visibility: export
Fixity Declaration: infixr operator, level 6
(|++>) : List (phiinputs) ->CBlockphiinstrtrmlblNothingouts->CBlockphiinstrtrmlbl (Justinputs) outs
  Defines the inputs of a block by prepending to it a list of phi assignemts
@ pre the phi assignments (the prefix)
@ post the block (the postfix)

Visibility: export
Fixity Declaration: infixr operator, level 6
(|+>) : phiinputs->CBlockphiinstrtrmlblNothingouts->CBlockphiinstrtrmlbl (Justinputs) outs
  Defines the inputs of a block by prepending to it a single phi assignemt
@ pre the phi assignment (the prefix)
@ post the block (the postfix)

Visibility: export
Fixity Declaration: infixr operator, level 6
(+|) : phiinputs->CBlockphiinstrtrmlbl (Justinputs) outs->CBlockphiinstrtrmlbl (Justinputs) outs
  Prepends a phi assignment to a block with already defined inputs
@ pre the phi assignment (the prefix)
@ post the block (the postfix)

Visibility: export
Fixity Declaration: infixr operator, level 5
(++|) : List (phiinputs) ->CBlockphiinstrtrmlbl (Justinputs) outs->CBlockphiinstrtrmlbl (Justinputs) outs
  Prepends a list of phi assignments to a block with already defined inputs
@ pre the phi assignments (the prefix)
@ post the block (the postfix)

Visibility: export
Fixity Declaration: infixr operator, level 5
emptyCFG : CFG (CBlockphiinstrterminatorrt) (Undefinedlbl) (Undefinedlbl)
  Make a graph that consists of a single empty block
@ lbl the label of the block

Visibility: export