Contur 2
Educational OS kernel simulator
Loading...
Searching...
No Matches
contur::ProcessConfig Struct Reference

Configuration payload used to create a process. More...

#include <i_kernel.h>

Public Attributes

ProcessId id = INVALID_PID
 Optional explicit PID. INVALID_PID requests auto-assignment.
std::string name
 Human-readable process name.
std::vector< Blockcode
 Program code segment. Required for interpreter-backed processes.
Priority priority {}
 Initial scheduling priority.
Tick arrivalTime = 0
 Arrival timestamp override. Defaults to current clock tick.
std::string nativePath
 Optional path to a native host executable.

Detailed Description

Configuration payload used to create a process.

Definition at line 30 of file i_kernel.h.

Member Data Documentation

◆ arrivalTime

Tick contur::ProcessConfig::arrivalTime = 0

Arrival timestamp override. Defaults to current clock tick.

Definition at line 48 of file i_kernel.h.

◆ code

std::vector<Block> contur::ProcessConfig::code

Program code segment. Required for interpreter-backed processes.

For native processes (!nativePath.empty()) the kernel injects a single Halt block as a placeholder so the existing dispatcher invariants hold.

Definition at line 42 of file i_kernel.h.

Referenced by spawnDemoProcesses().

◆ id

ProcessId contur::ProcessConfig::id = INVALID_PID

Optional explicit PID. INVALID_PID requests auto-assignment.

Definition at line 33 of file i_kernel.h.

◆ name

std::string contur::ProcessConfig::name

Human-readable process name.

Definition at line 36 of file i_kernel.h.

Referenced by spawnDemoProcesses().

◆ nativePath

std::string contur::ProcessConfig::nativePath

Optional path to a native host executable.

When non-empty, the kernel marks the process as native: the dispatcher's execution engine (must be NativeEngine) spawns and supervises a real host child process at this path. When empty, the process is interpreter-backed and code is the source of truth.

Definition at line 56 of file i_kernel.h.

◆ priority

Priority contur::ProcessConfig::priority {}

Initial scheduling priority.

Definition at line 45 of file i_kernel.h.

Referenced by spawnDemoProcesses().


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