[−][src]Module walrus::ir
Intermediate representation for expressions.
The goal is to match wasm instructions as closely as possible, but translate
the stack machine into an expression tree. Additionally all control frames
are representd as Block
s.
Modules
matcher | Matching expressions. |
Structs
AtomicNotify | The |
AtomicNotifyId | An identifier to a |
AtomicRmw | An atomic read/modify/write operation |
AtomicRmwId | An identifier to a |
AtomicWait | The |
AtomicWaitId | An identifier to a |
Binop | Binary operations, those requiring two operands |
BinopId | An identifier to a |
Block | A block of multiple expressions, and also a control frame. |
BlockId | An identifier to a |
Br |
|
BrId | An identifier to a |
BrIf |
|
BrIfId | An identifier to a |
BrTable |
|
BrTableId | An identifier to a |
Call |
|
CallId | An identifier to a |
CallIndirect |
|
CallIndirectId | An identifier to a |
Cmpxchg | An atomic compare exchange operation |
CmpxchgId | An identifier to a |
Const |
|
ConstId | An identifier to a |
DataDrop | data.drop |
DataDropId | An identifier to a |
Drop |
|
DropId | An identifier to a |
GlobalGet |
|
GlobalGetId | An identifier to a |
GlobalSet |
|
GlobalSetId | An identifier to a |
IfElse |
|
IfElseId | An identifier to a |
Load | Loading a value from memory |
LoadId | An identifier to a |
Local | A local variable or parameter. |
LocalGet |
|
LocalGetId | An identifier to a |
LocalSet |
|
LocalSetId | An identifier to a |
LocalTee |
|
LocalTeeId | An identifier to a |
MemArg | Arguments to memory operations, containing a constant offset from a dynamic address as well as a predicted alignment. |
MemoryCopy | memory.copy |
MemoryCopyId | An identifier to a |
MemoryFill | memory.fill |
MemoryFillId | An identifier to a |
MemoryGrow | memory.grow |
MemoryGrowId | An identifier to a |
MemoryInit | memory.init |
MemoryInitId | An identifier to a |
MemorySize | memory.size |
MemorySizeId | An identifier to a |
Return |
|
ReturnId | An identifier to a |
Select |
|
SelectId | An identifier to a |
Store | Storing a value to memory |
StoreId | An identifier to a |
Unop | Unary operations, those requiring one operand |
UnopId | An identifier to a |
Unreachable |
|
UnreachableId | An identifier to a |
WithSideEffects | A value followed by one or more stack-neutral, side-effecting expressions. |
WithSideEffectsId | An identifier to a |
Enums
AtomicOp | The different kinds of atomic rmw operations |
AtomicWidth | The different kinds of atomic rmw operations |
BinaryOp | Possible binary operations in wasm |
BlockKind | Different kinds of blocks. |
Expr | An enum of all the different kinds of wasm expressions. |
ExtendedLoad | The kinds of extended loads which can happen |
LoadKind | The different kinds of load instructions that are part of a |
StoreKind | The different kinds of store instructions that are part of a |
UnaryOp | Possible unary operations in wasm |
Value | Constant values that can show up in WebAssembly |
Traits
Ast | A trait for anything that is an AST node in our IR. |
Visit | Anything that can be visited by a |
VisitMut | Anything that can be visited by a |
Visitor | A visitor walks over an IR expression tree. |
VisitorMut | A visitor walks over a mutable IR expression tree. |
Type Definitions
ExprId | An identifier for a particular expression. |
LocalId | The id of a local. |