atom-1.0.10: A DSL for embedded hard realtime applications.

Language.Atom.Elaboration

Contents

Synopsis

Atom monad and container.

data Atom a Source

The Atom monad holds variable and rule declarations.

Instances

data AtomDB Source

Constructors

AtomDB 

Instances

data Global Source

Constructors

Global 

data Rule Source

Constructors

Rule 
Assert 
Cover 

Instances

buildAtom :: UeMap -> Global -> Name -> Atom a -> IO (a, AtomSt)Source

Type Aliases and Utilities

type UID = IntSource

type Name = StringSource

A name.

data Phase Source

A phase is either the minimum phase or the exact phase.

Constructors

MinPhase Int 
ExactPhase Int 

type Path = [Name]Source

A hierarchical name.

elaborate :: UeMap -> Name -> Atom () -> IO (Maybe (UeMap, (StateHierarchy, [Rule], [Name], [Name], [(Name, Type)])))Source

A Relation is used for relative performance constraints between Actions. data Relation = Higher UID | Lower UID deriving (Show, Eq)

Given a top level name and design, elaborates design and returns a design database.

var :: Expr a => Name -> a -> Atom (V a)Source

Generic local variable declaration.

var' :: Name -> Type -> V aSource

Generic external variable declaration.

array :: Expr a => Name -> [a] -> Atom (A a)Source

Generic array declaration.

array' :: Expr a => Name -> Type -> A aSource

Generic external array declaration.

get :: Atom AtomStSource

put :: AtomSt -> Atom ()Source

allUVs :: UeMap -> [Rule] -> Hash -> [MUV]Source

All the variables that directly and indirectly control the value of an expression.

allUEs :: Rule -> [Hash]Source

All primary expressions used in a rule.