feldspar-compiler-0.1: Compiler for the Feldspar languageSource codeContentsIndex
Feldspar.Compiler.Imperative.Representation
Documentation
data Size Source
Constructors
S4
S8
S16
S32
S64
show/hide Instances
data Signedness Source
Constructors
ImpSigned
ImpUnsigned
show/hide Instances
data Type Source
Constructors
BoolType
FloatType
Numeric Signedness Size
ImpArrayType (Maybe Int) Type
Pointer Type
show/hide Instances
data ImpLangExpr Source
Constructors
Expr
exprCore :: UntypedExpression
exprType :: Type
show/hide Instances
data Variable Source
Constructors
Var
name :: String
kind :: ParameterKind
vartype :: Type
show/hide Instances
data LeftValue Source
Constructors
LVar Variable
ArrayElem LeftValue ImpLangExpr
PointedVal LeftValue
show/hide Instances
data UntypedExpression Source
Constructors
LeftExpr LeftValue
AddressOf LeftValue
ConstExpr Constant
FunCall FunRole String [ImpLangExpr]
show/hide Instances
data Constant Source
Constructors
IntConst Int
FloatConst Float
BoolConst Bool
ArrayConst Int [Constant]
show/hide Instances
data FunRole Source
Constructors
SimpleFun
InfixOp
PrefixOp
show/hide Instances
data Instruction Source
Constructors
Assign LeftValue ImpLangExpr
CFun String [Parameter]
show/hide Instances
data Parameter Source
Constructors
In ImpLangExpr
Out (ParameterKind, ImpLangExpr)
show/hide Instances
data ParameterKind Source
Constructors
Normal
OutKind
show/hide Instances
data ImpFunction Source
Constructors
Fun
funName :: String
inParameters :: [Declaration]
outParameters :: [Declaration]
prg :: CompleteProgram
show/hide Instances
data CompleteProgram Source
Constructors
CompPrg
locals :: [Declaration]
body :: Program
show/hide Instances
data Declaration Source
Constructors
Decl
var :: Variable
declType :: Type
initVal :: Maybe ImpLangExpr
semInfVar :: SemInfVar
show/hide Instances
data Program Source
Constructors
Empty
Primitive Instruction SemInfPrim
Seq [Program] SemInfPrgSeq
IfThenElse Variable CompleteProgram CompleteProgram SemInfIf
SeqLoop Variable CompleteProgram CompleteProgram SemInfSeqLoop
ParLoop Variable ImpLangExpr Int CompleteProgram SemInfParLoop
show/hide Instances
data Array Source
Constructors
Array Variable Type Int
show/hide Instances
class ToC a whereSource
Methods
toC :: Int -> a -> StringSource
show/hide Instances
compToC :: ToC a => a -> StringSource
toCArray :: Constant -> StringSource
arrayDepths :: Type -> StringSource
simpleType :: Type -> BoolSource
toCPrimType :: Type -> StringSource
isArrayType :: Type -> StringSource
listprint :: (a -> String) -> String -> [a] -> StringSource
toLeftValue :: ImpLangExpr -> LeftValueSource
replicateArrayDepth :: Type -> String -> Int -> StringSource
arrayDepth :: Type -> IntSource
getVariable :: ImpLangExpr -> Maybe VariableSource
contains :: String -> ImpLangExpr -> BoolSource
getVarName :: LeftValue -> StringSource
getLeftValue :: ImpLangExpr -> LeftValueSource
type VariableMap = Map String SemInfVarSource
data SemInfPrim Source
Constructors
SemInfPrim
varMap :: VariableMap
output :: Bool
show/hide Instances
data SemInfVar Source
Constructors
SemInfVar
usedLeft :: LeftUse
usedRight :: RightUse
show/hide Instances
data LeftUse Source
Constructors
UnknownL
None
Single (Maybe ImpLangExpr)
MultipleL
show/hide Instances
data RightUse Source
Constructors
UnknownR
Times Int
MultipleR
show/hide Instances
getValue :: SemInfVar -> ImpLangExprSource
leftVars :: VariableMap -> [String]Source
type SemInfPrgSeq = [String]Source
type SemInfBr = [String]Source
type SemInfParLoop = [String]Source
type SemInfIf = [String]Source
type SemInfSeqLoop = [String]Source
type SemInfSeq = [String]Source
class RightVarMap a whereSource
Methods
rightVarMap :: a -> VariableMapSource
show/hide Instances
leftVarMap :: LeftValue -> Maybe ImpLangExpr -> VariableMapSource
addVarMap :: VariableMap -> VariableMap -> VariableMapSource
Produced by Haddock version 2.6.0