the FYSOS registry system

is a new registry system that...

  • is easy to understand and implement
  • allows generations of entries
  • provides Unicode names
  • supports many attributes
  • is multi-task aware
  • requires little memory and CPU power

The FYSOS registry is a free, simple, portable, registry system created to provide an alternative, easy to implement registry system for OS development hobbyists. It is primarily intended to easily save and restore volatile and non-volatile information within the kernel system, and to expand the functionality of the FYSOS operating system.

The system is designed to load at boot time, remain in memory throughout the life of the session, and finally written back to a media device for use at the next boot. It is simple, is multi-task aware, and allows a tree style hierarchy of hives and cells. Each hive contains a name, allowing for multiple limbs of hives and cells.

News

2023 Jan 26 - Version 1.0.0-rc1 of the reference implementation is available.

Overview

Structure of the registry system

The registry system contains a single base hive, called the System hive, this hive allowing up to 256 generations of hives and cells to reside within. Each hive is only limited to the amount of memory your system allocates to it, therefore allowing a nearly limitless size to the registry. Each of these hives may contain child hives as well as cells, cells being the item used to store the information.

The layout shown to the right, uses the example of storing the left part of the top-left pixel of a GUI window as to be able to restore the window position the next time it is open. The path for this entry is /System/Kernel/ApplicationName/Window/Left. The next time the window is displayed, the underlining system can simply pass this path string to the registry application to retrieve the value.

There is no limit on the number of hives or cells used. Each cell can hold an array of types of data from a single Boolean value to 64k of raw data.

This system is designed to be simple to implement. It does not use any complex algorithms such as b-trees or other hash-table style listings. It simply is a binary string of objects, listed one right after another. With this simplicity, and without the complex algorithms, it does take a little more CPU time to transverse through the hives to get to the desired cell, but the simplicity really out-weighs this small amount of extra time, especially for smaller registries. The extra time is not even noticeable on a registry of 5 Megs in size, a size well large enough for hobby operating systems like yours and mine.

Technical résumé

Allocation unit32 bytes of UTF-8 char space per name
Types of storageStandard data types plus up to 64k of raw data
Generational depth256 branches
Number of hives/cellsarbitrary, limited to available memory
Endiannesslittle endian

Where to go from here

To go into the depth of structure formats and algorithms of the registry system, you may read the FYSOS registry system specification.

A reference implementation, written in C, is available in the Downloads section.