General Theory of the Reganta Operating System

1. Purpose of the Operating System

The Reganta operating system is designed to coordinate computation between modules and computational devices.

It does not provide application abstractions such as files, processes, directories, or databases. Those capabilities are implemented by separate modules.

The subject matter of the operating system is:

  • streams;
  • modules;
  • memory.

The Kernel schedules their joint use and ensures execution of the operating system contracts.

This makes Reganta suitable for AI-oriented systems as well, because intelligent behavior can be expressed as a module that obeys the same contracts as any other function provider.

2. Module

A module is a unit of function.

Each module implements a specific contract and can accept a stream, process data, and produce a result.

Modules can execute on different Function Devices:

  • CPU;
  • DSP;
  • GPU;
  • FPGA;
  • specialized devices.

The differences between application, system, and firmware are determined not by the nature of the module itself, but by its mode of execution and control.

Firmware is also a module. It is permanently or for a long time attached to a specific device, can directly control it, and does not have to be unloaded or preempted.

The Kernel itself should contain only what cannot be moved into a separate module without violating the basic contracts of the operating system.

In an AI-driven system, this means reasoning, routing, and specialized inference logic can live in modules, while the Kernel remains focused on coordination.

3. Function Device

A Function Device is a computational or specialized device capable of implementing functions through operating system contracts.

The device can:

  • accept streams;
  • create streams;
  • accept messages;
  • perform operations on transferred pages;
  • provide its own contracts.

The internal method of function execution does not belong to operating system theory.

For the Kernel, only the supported contracts of the device and the firmware that ensures their execution are relevant.

4. Stream

A stream is a means of transferring computation from a source to a receiving module.

At the current level of theory, the stream determines the receiving module.

A stream is not an executable object by itself. It connects a data source with the function that must process those data.

The basic computation scheme is:

source → stream → receiving module

After processing, the module may produce a new stream for the next module.

Thus, a computational system is formed as a sequence of functions linked by streams:

module A → stream → module B → stream → module C

Routing between multiple receivers, load balancing, priorities, and other additional stream properties are not yet part of the general theory.

This leaves room for future AI orchestration layers without changing the base model.

5. Memory

Reganta uses a page-based memory model.

The operating system operates on an address space of (2^{32}) page indices.

The page index is a 32-bit identifier:

page_index: 0 … 2^32 − 1

The index is not a physical address and does not by itself determine where the data are located.

The Kernel knows precisely:

  • whether the page exists;
  • where it is physically located;
  • what type of memory it is in;
  • which module or device can access it;
  • where it must be moved for an operation to execute.

6. Types of Memory

The Kernel manages page placement across the available memory types:

  • RAW;
  • DRAM;
  • SRAM.

RAW represents memory in its original form, accessible through the corresponding device or firmware.

DRAM is used as the main working memory.

SRAM is used as fast local memory of a processor or another Function Device.

The page index does not change when the page is physically relocated.

The same page can sequentially exist in RAW, DRAM, or SRAM while keeping the same index.

7. Page as a Contract Unit

A page is the agreed unit of exchange between components of the operating system.

The page index is used in interactions between:

  • the Kernel;
  • firmware of the kernel;
  • firmware of computational devices;
  • other firmware that support Reganta contracts.

The components pass each other the page index, not the physical address of the data.

For example:

Kernel → page_index → DSP firmware

The firmware receives the page index within the operating system contract.

The Kernel determines the actual placement of the page and ensures its availability to the appropriate device.

Therefore, a page is simultaneously:

  • a unit of memory organization;
  • a unit of data transfer;
  • an object of contractual interaction between the Kernel and firmware.

8. Scheduling

The Kernel schedules three interrelated objects.

Stream Scheduling

For a stream, the Kernel determines the receiving module.

Module Scheduling

The Kernel determines:

  • which module should process the stream;
  • which device can execute that module;
  • which firmware supports the required contract;
  • whether the module should be loaded, pinned, or preempted.

Memory Scheduling

The Kernel determines:

  • where each page is located;
  • where it must be located to execute a function;
  • when it must be moved between RAW, DRAM, and SRAM;
  • which module or device should be given access.

9. Formation of Computation

Computation arises from the coordination of three objects:

stream + module + pages = executable function

The stream determines the receiving module.

The module determines the processing function.

The pages contain the data and state required to execute the function.

The Kernel binds them to a Function Device that supports the corresponding contract.

Generalized scheme:

stream
receiving module
required pages
Function Device and its firmware
function execution
new stream

10. Boundary of the Operating System

The operating system must not know the application meaning of the data.

For the Kernel, a page remains a page regardless of whether it contains:

  • module code;
  • computational state;
  • a database record;
  • an image;
  • a message;
  • arbitrary data.

The Kernel also does not implement a file system, a database, or application storage.

It provides control over streams, modules, and pages. Higher-level abstractions are created on top of these mechanisms by separate modules.

This boundary is especially important for AI systems: the Kernel should schedule and protect the computation, while the semantics of the task belong to modules.

11. Final Principle

The Reganta operating system is a system for coordinating streams, modules, and memory.

The stream determines the receiving module.

The module determines the function to be executed.

The page is the agreed unit of exchange and is identified by a 32-bit index.

The Kernel knows the exact physical state of each page, manages its placement between RAW, DRAM, and SRAM, and binds modules to Function Devices that support the required contracts.

All functions that can be implemented by a replaceable module without changing these principles do not belong to the core theory of the operating system.

In that sense, Reganta is a contract-first operating system model for general computing, specialized devices, and AI-ready modular execution.