Represents a concrete IR function with the first argument as its return type.
More...
|
| using | BaseT = SRetFunction< SignatureT, IRFunction< SignatureT >> |
| |
| using | Ptr = std::shared_ptr< SRetFunction< SignatureT, IRFunction< SignatureT > >> |
| |
| using | Traits = FunctionTraits< SignatureT > |
| |
| using | GeneratorNativeCb = std::function< Value(const NativeArguments &, llvm::IRBuilder<> &)> |
| | The IR callback function which will write the LLVM IR for this function's body. More...
|
| |
| using | GeneratorArgumentsCb = std::function< Value(const Arguments &, llvm::IRBuilder<> &)> |
| |
| using | GeneratorCb = std::function< llvm::Value *(const std::vector< llvm::Value * > &, llvm::IRBuilder<> &)> |
| | Legacy callback, will eventually be deprecated in favour of using the GeneratorArgumentsCb. More...
|
| |
| enum | SignatureMatch {
None = 0,
Size,
Implicit,
Ambiguous,
Explicit
} |
| | The result type from calls to Function::match. More...
|
| |
|
| | IRFunctionSRet (const std::string &symbol, const IRFunctionBase::GeneratorCb &gen) |
| |
| | IRFunctionSRet (const std::string &symbol, const IRFunctionBase::GeneratorNativeCb &gen) |
| |
| | IRFunctionSRet (const std::string &symbol, const IRFunctionBase::GeneratorArgumentsCb &gen) |
| |
| | ~IRFunctionSRet () override=default |
| |
| ArgInfo | types (ArgInfoVector &args, llvm::LLVMContext &C) const override |
| | Overide the ArgInfo type method. This does NOT change the arg order, it simply marks the first argument as a return argument. Note that the void ret type is also left as a return type. More...
|
| |
| llvm::Type * | types (std::vector< llvm::Type * > &types, llvm::LLVMContext &C) const override |
| |
| Function::SignatureMatch | match (const ArgInfoVector &args, llvm::LLVMContext &C) const override |
| | Override of match which inserts the SRET type such that the base class methods ignore it. More...
|
| |
| Function::SignatureMatch | match (const std::vector< llvm::Type * > &args, llvm::LLVMContext &C) const override |
| |
| llvm::Value * | call (const std::vector< llvm::Value * > &args, llvm::IRBuilder<> &B) const override |
| | Override of call which allocates the required SRET llvm::Value for this function. More...
|
| |
| Value | call (const Arguments &args, llvm::IRBuilder<> &B) const override |
| |
| llvm::Value * | call (const std::vector< llvm::Value * > &args, llvm::IRBuilder<> &B, const bool cast) const override |
| |
| Value | call (const NativeArguments &args, llvm::IRBuilder<> &B) const |
| |
| void | print (llvm::LLVMContext &C, std::ostream &os, const char *name=nullptr, const bool axTypes=true) const override |
| | Override of print to avoid printing out the SRET type. More...
|
| |
| void | setEmbedIR (bool on) |
| | Enable or disable the embedding of IR. Embedded IR is currently required for function which use parent function parameters. More...
|
| |
| bool | hasEmbedIR () const |
| |
| llvm::Function * | create (llvm::LLVMContext &C, llvm::Module *M) const override |
| | Override for the creation of an IR function. This ensures that the body and prototype of the function are generated if a Module is provided. More...
|
| |
| llvm::Function * | create (llvm::Module &M) const |
| | Convenience method which always uses the provided module to find the function or insert it if necessary. More...
|
| |
| llvm::Function * | get (const llvm::Module &M) const |
| | Convenience method for calling M.getFunction(symbol). Returns a nullptr if the function has not yet been created or if it is embedded IR. More...
|
| |
| size_t | size () const |
| | The number of arguments that this function has. More...
|
| |
| const char * | symbol () const |
| | The function symbol name. More...
|
| |
| const char * | argName (const size_t idx) const |
| | Returns the descriptive name of the given argument index. More...
|
| |
| const SmallArgumentVector< const char * > & | dependencies () const |
| |
| bool | hasParamAttribute (const size_t i, const llvm::Attribute::AttrKind &kind) const |
| | Deprecated builder methods, no longer public. More...
|
| |
| void | setArgumentNames (std::vector< const char * > names) |
| |
| void | setDependencies (std::vector< const char * > deps) |
| |
| void | setFnAttributes (const std::vector< llvm::Attribute::AttrKind > &in) |
| |
| void | setRetAttributes (const std::vector< llvm::Attribute::AttrKind > &in) |
| |
| void | setParamAttributes (const size_t i, const std::vector< llvm::Attribute::AttrKind > &in) |
| |
template<typename SignatureT>
struct openvdb::v13_0::ax::codegen::IRFunctionSRet< SignatureT >
Represents a concrete IR function with the first argument as its return type.