IR-code¶
Front ends generate this IR-code. Backends transform it into machine code.
The IR-code is implemented in the ir package.
- class ppci.ir.Module(name)¶
Container unit for variables and functions.
- class ppci.ir.Function(name, module=None)¶
Represents a function.
- class ppci.ir.Block(name, function=None)¶
Uninterrupted sequence of instructions with a label at the start.
A block contains a sequence of statements.
- class ppci.ir.Load(address, name, ty, volatile=False)¶
Load a value from memory
- class ppci.ir.Store(value, address, volatile=False)¶
Store a value into memory
- class ppci.ir.Const(value, name, ty)¶
Represents a constant value
- class ppci.ir.Binop(a, operation, b, name, ty)¶
Generic binary operation
- class ppci.ir.Call(function, arguments, name, ty)¶
Call a function with some arguments
- class ppci.ir.Jump(target)¶
Jump statement to another block within the same function
- class ppci.ir.CJump(a, cond, b, lab_yes, lab_no)¶
Conditional jump to true or false labels.