Documentation
¶
Index ¶
Constants ¶
View Source
const ( LLGOAuthor = "Andrew Wilkins <[email protected]>" LLGOProducer = "llgo " + LLGOVersion + " (" + LLGOAuthor + ")" )
llgo constants.
View Source
const ( LLGOVersion = "0.1" LLGORuntimeVersion = 0 )
View Source
const AttributeCommentPrefix = "#llgo "
View Source
const PNaClTriple = "armv7-none-linux-gnueabi"
PNaClTriple is the LLVM target triple that should be used to compile modules to be compatible with PNaCl (Portable Native Client).
Variables ¶
This section is empty.
Functions ¶
func NewLLVMTypeMap ¶
func NewLLVMTypeMap(target llvm.TargetData) *llvmTypeMap
Types ¶
type AlgorithmKind ¶
type AlgorithmKind int
const ( AlgorithmHash AlgorithmKind = iota AlgorithmEqual AlgorithmPrint AlgorithmCopy )
type Attribute ¶
type Attribute interface {
Apply(Value)
}
Attribute represents an attribute associated with a global variable or function.
type Compiler ¶
type Compiler interface {
Compile(filenames []string, importpath string) (*Module, error)
Dispose()
}
func NewCompiler ¶
func NewCompiler(opts CompilerOptions) (Compiler, error)
type CompilerOptions ¶
type CompilerOptions struct {
// TargetTriple is the LLVM triple for the target.
TargetTriple string
// GenerateDebug decides whether debug data is
// generated in the output module.
GenerateDebug bool
// Logger is a logger used for tracing compilation.
Logger *log.Logger
// OrderedCompilation attempts to do some sorting to compile
// functions in a deterministic order
OrderedCompilation bool
}
type FuncResolver ¶
type LLVMValue ¶
type LLVMValue struct {
// contains filtered or unexported fields
}
LLVMValue represents a dynamic value produced as the result of an expression.
type MethodResolver ¶
type TypeMap ¶
type TypeMap struct {
// contains filtered or unexported fields
}
func NewTypeMap ¶
func NewTypeMap(pkgpath string, llvmtm *llvmTypeMap, module llvm.Module, r *runtimeInterface, mr MethodResolver) *TypeMap
type Value ¶
type Value interface {
// BinaryOp applies the specified binary operator to this value and the
// specified right-hand operand, and returns a new Value.
BinaryOp(op token.Token, rhs Value) Value
// UnaryOp applies the specified unary operator and returns a new Value.
UnaryOp(op token.Token) Value
// Convert returns a new Value which has been converted to the specified
// type.
Convert(typ types.Type) Value
// LLVMValue returns an llvm.Value for this value.
LLVMValue() llvm.Value
// Type returns the Type of the value.
Type() types.Type
}
Value is an interface for representing values returned by Go expressions.
Source Files
¶
Directories
¶
| Path | Synopsis |
|---|---|
|
cmd
|
|
|
llgo-build
command
|
|
|
llgo-dist
command
|
|
|
pkg
|
|
|
runtime
Package runtime contains operations that interact with Go's runtime system, such as functions to control goroutines.
|
Package runtime contains operations that interact with Go's runtime system, such as functions to control goroutines. |
Click to show internal directories.
Click to hide internal directories.
