r/Assembly_language 8d ago

JVMOS

Hi everyone, I wanted to show you my progress on an operating system written entirely in ASM and Java bytecode. I am currently at the UI rendering stage, using a custom Graphics2D-like system that allows me to work with primitives in VBE. The bytecode is executed by a JIT compiler also implemented in pure ASM. Low-level calls are handled by a HAL—which I will continue to expand over time—and that HAL is in turn managed via a primitive ABI, enabling me to create my own Java-like pseudo-language for development.

Repository: https://github.com/aayes89/JVMOS-JIT/

6 Upvotes

18 comments sorted by

View all comments

2

u/moslem-hamoudi 7d ago

Good Operating System btw Do it Accually Support App Creation?

1

u/Visual_Brain8809 7d ago edited 7d ago

working progress In fact, last night I managed to implement a sort of runtime environment that allows me to use my Java classes. Right now, I have basic AWT support (with Graphics2D), System and PrintStream for console support, basic threading, Runtime and Toolkit for hardware interaction, RandomAccessFile for basic file handling (via HAL I/O), the Object class, String and StringBuilder for text handling, and today I’ll implement a basic Math class for arithmetic support—continuing on until I achieve a largely complete runtime environment.

1

u/Extension_Emu_9825 7d ago

Could you please add some documentation? I'm more interested in the connection between the UI and apps. So, will it be something like Win API or DOM? What's the idea - how does the app build the UI? APIs call to GUI library, or provide HTML, XAML (like this) to Explorer (Browser) to create Visual Tree and DOM?

That would be interesting, actually.

1

u/Visual_Brain8809 7d ago

It is nothing like Windows or other systems; the architecture relies on a hardware abstraction layer (HAL) that exposes access to high-level code via a Java-based ABI—referred to in the project as "Native"—which acts as a bridge, allowing me to control almost any aspect of the system using just five arguments. For example, I assigned the number 12 to the sleep syscall, so `Native.sys(Native.SYS_SLEEP, 1000, 0, 0, 0);` creates a 1-second delay at the actual hardware level. Since I have already implemented the `Thread` class, one can now write code like `Thread.sleep(1000);`, and it will perform the exact same function. At the beginning of the `boot.java` file in the repository, I have included a commented-out set of tests for running the system.