Class Func

Inheritance Relationships

Base Types

Class Documentation

class seq::Func : public seq::BaseFunc, public seq::Generic, public seq::SrcObject

Functions in a program are represented by this class.

Public Functions

Func()
Block *getBlock()
std::string genericName() override
void addCachedRealized(std::vector<types::Type*> types, Generic *x) override
Func *realize(std::vector<types::Type*> types)
std::vector<types::Type*> deduceTypesFromArgTypes(std::vector<types::Type*> argTypes)
std::vector<Expr*> rectifyCallArgs(std::vector<Expr*> args, std::vector<std::string> names, bool methodCall = false)
void setEnclosingFunc(Func *parentFunc)
void sawReturn(Return *ret)
void sawYield(Yield *yield)
void addAttribute(std::string attr)
std::vector<std::string> getAttributes()
bool hasAttribute(const std::string &attr)
void resolveTypes() override
void codegen(llvm::Module *module) override
void codegenReturn(llvm::Value *val, types::Type *type, llvm::BasicBlock *&block, bool dryrun = false)
void codegenYield(llvm::Value *val, types::Type *type, llvm::BasicBlock *&block, bool empty = false, bool dryrun = false)
llvm::Value *codegenYieldExpr(llvm::BasicBlock *&block, bool suspend = true)
bool isGen() override
Var *getArgVar(std::string name)
types::FuncType *getFuncType() override
void setExternal()
void setIns(std::vector<types::Type*> inTypes)
void setOut(types::Type *outType)
void setDefaults(std::vector<Expr*> defaultArgs)
void setName(std::string name)
std::vector<std::string> getArgNames()
void setArgNames(std::vector<std::string> argNames)
Func *clone(Generic *ref) override

Public Static Functions

Func *getBuiltin(const std::string &name)