Aleph-w 3.0
A C++ Library for Data Structures and Algorithms
Loading...
Searching...
No Matches
Aleph::Compiler_Bytecode_Instruction Struct Reference

One lowered bytecode instruction. More...

#include <Bytecode.H>

Collaboration diagram for Aleph::Compiler_Bytecode_Instruction:
[legend]

Public Attributes

Compiler_Bytecode_PC pc = compiler_bytecode_invalid_id()
 Program counter within the function code array.
 
Compiler_Bytecode_Opcode opcode = Compiler_Bytecode_Opcode::Trap
 Operation category.
 
Compiler_Bytecode_Register_Id destination = 0
 Destination register, or 0 for void instructions.
 
Compiler_Type_Id type_id = 0
 Result or stored type, when known.
 
Source_Span span
 Source region associated with the instruction.
 
Compiler_Operator_Kind op = Compiler_Operator_Kind::Invalid
 Unary/binary operator, when relevant.
 
Compiler_IR_Local_Slot_Id local_slot_id = compiler_ir_invalid_id()
 Referenced local slot, when relevant.
 
Compiler_IR_Global_Slot_Id global_slot_id = compiler_ir_invalid_id()
 Referenced global slot, when relevant.
 
Compiler_Bytecode_Constant_Id constant_id = compiler_bytecode_invalid_id()
 Referenced constant pool entry, when relevant.
 
Compiler_Bytecode_Function_Id function_id = compiler_bytecode_invalid_id()
 Referenced function id, when relevant.
 
DynArray< Compiler_Bytecode_Register_Id > operands
 Source registers in deterministic order.
 
Compiler_Bytecode_PC target_pc = compiler_bytecode_invalid_id()
 Jump target or branch true target.
 
Compiler_Bytecode_PC false_target_pc = compiler_bytecode_invalid_id()
 Branch false target.
 

Detailed Description

One lowered bytecode instruction.

Definition at line 193 of file Bytecode.H.

Member Data Documentation

◆ constant_id

Compiler_Bytecode_Constant_Id Aleph::Compiler_Bytecode_Instruction::constant_id = compiler_bytecode_invalid_id()

Referenced constant pool entry, when relevant.

Definition at line 203 of file Bytecode.H.

◆ destination

Compiler_Bytecode_Register_Id Aleph::Compiler_Bytecode_Instruction::destination = 0

Destination register, or 0 for void instructions.

Definition at line 197 of file Bytecode.H.

◆ false_target_pc

Compiler_Bytecode_PC Aleph::Compiler_Bytecode_Instruction::false_target_pc = compiler_bytecode_invalid_id()

Branch false target.

Definition at line 207 of file Bytecode.H.

Referenced by Aleph::Compiler_Bytecode_Lowering::lower_function().

◆ function_id

Compiler_Bytecode_Function_Id Aleph::Compiler_Bytecode_Instruction::function_id = compiler_bytecode_invalid_id()

Referenced function id, when relevant.

Definition at line 204 of file Bytecode.H.

◆ global_slot_id

Compiler_IR_Global_Slot_Id Aleph::Compiler_Bytecode_Instruction::global_slot_id = compiler_ir_invalid_id()

Referenced global slot, when relevant.

Definition at line 202 of file Bytecode.H.

◆ local_slot_id

Compiler_IR_Local_Slot_Id Aleph::Compiler_Bytecode_Instruction::local_slot_id = compiler_ir_invalid_id()

Referenced local slot, when relevant.

Definition at line 201 of file Bytecode.H.

◆ op

Compiler_Operator_Kind Aleph::Compiler_Bytecode_Instruction::op = Compiler_Operator_Kind::Invalid

Unary/binary operator, when relevant.

Definition at line 200 of file Bytecode.H.

◆ opcode

Compiler_Bytecode_Opcode Aleph::Compiler_Bytecode_Instruction::opcode = Compiler_Bytecode_Opcode::Trap

Operation category.

Definition at line 196 of file Bytecode.H.

Referenced by Aleph::Compiler_Bytecode_Lowering::lower_function().

◆ operands

DynArray<Compiler_Bytecode_Register_Id> Aleph::Compiler_Bytecode_Instruction::operands

Source registers in deterministic order.

Definition at line 205 of file Bytecode.H.

Referenced by Aleph::Compiler_Bytecode_Lowering::lower_function().

◆ pc

Compiler_Bytecode_PC Aleph::Compiler_Bytecode_Instruction::pc = compiler_bytecode_invalid_id()

Program counter within the function code array.

Definition at line 195 of file Bytecode.H.

Referenced by Aleph::Compiler_Bytecode_Lowering::lower_function().

◆ span

Source_Span Aleph::Compiler_Bytecode_Instruction::span

Source region associated with the instruction.

Definition at line 199 of file Bytecode.H.

Referenced by Aleph::Compiler_Bytecode_Lowering::lower_function().

◆ target_pc

Compiler_Bytecode_PC Aleph::Compiler_Bytecode_Instruction::target_pc = compiler_bytecode_invalid_id()

Jump target or branch true target.

Definition at line 206 of file Bytecode.H.

Referenced by Aleph::Compiler_Bytecode_Lowering::lower_function().

◆ type_id

Compiler_Type_Id Aleph::Compiler_Bytecode_Instruction::type_id = 0

Result or stored type, when known.

Definition at line 198 of file Bytecode.H.


The documentation for this struct was generated from the following file: