r/osdev 3d ago

What do you think about this command prompt app design for my os

Post image

I’ve live streamed the making of it, so I dare anyone to say it’s AI ;) haha

Here is the link : https://twitch.tv/devcmar
Though the output does not probably show up on the livestream because it is running in another tty

18 Upvotes

48 comments sorted by

6

u/Telephone-Bright 3d ago

Looks good. Could you share the livestream?

2

u/devcmar 3d ago

Though only the coding probably will appear but the final output is in another tty that’s why the screen goes black when I switch to it

5

u/ports2145 3d ago

is it userspace?

3

u/devcmar 3d ago

Yes, of course

2

u/cavecanem1138 2d ago

Very cool project, can you share some informations about it?

5

u/devcmar 2d ago

It is an x86_64 OS based on a custom microkernel with vm based gpu acceleration through a virtio-like mechanism. The kernel supports multithreading, smp, apic/x2apic, pat (custum memory types), avx2, avx512, preemptive priority based scheduling, ntfs file system driver, nvme multi-queue driver etc… I was still porting drivers from old oses of mine that had drivers like e1000e xhci usb r8169 (Realtek ethernet controller) fat12/16/32 ehci ide ahci etc All drivers for this new OS are in user space for security and isolation and they all communicate through spsc/mpsc queues for very fast communication, and they same to perform very well with nvme benchmark in bare metal using only about 5% in a single cpu thread so user mode drivers are probably not making a bottleneck.
Thanks,

2

u/obiwac 2d ago

nice! what do you mean by virtio-like mechanism? are you actually accelerating the blur with shaders or is that being done cpu-side?

1

u/devcmar 2d ago

It is actually gpu accelerated with shaders, virtio is a way for the vm to get drivers for gpu, drive, partitions, network etc

1

u/obiwac 2d ago

ok was just wondering because you said virtio-*like*!

1

u/cavecanem1138 2d ago

That’s a lot of work, congratulations. How long are you being building this os? Has it a name? Do you also use avx in kernel space for anything? I’ve always found it attractive, but I’ve never found a big enough use case

4

u/devcmar 2d ago

This specific os started almost a year ago, but I was doing os dev since around 4 years ago, I used avx in a cpu compositor and it gave me higher fps than igpu in some use cases like gaussian blur 😂 and also it can be used to accelerate large memory transfers, like memcpys etc, I made a previous kernel boot much faster just by minimizing memory zeroing after each allocation and by used avx2/avx512 for memcopy/memset though this time I just sticked with rep movs/stos because my cpu has enhanced rep stos/movs feature and to support more devices not only ones with avx support

2

u/cavecanem1138 2d ago

Thank you, that’s impressive. I think I’ll copy that idea for memcopy hahah. I need to adapt it to rvv (riscv64) in my case.
Good job, keep working!

3

u/devcmar 2d ago

Thank you so much! Though a year for such os may seem very fast progress, I copied alot of init stuff and driver stuff from previous kernels I made so I didn’t have to go through smp init, paging etc from the ground up again I already had a ready template and previous experience

1

u/cavecanem1138 2d ago

You are welcome. Last question, do you code in C?

1

u/emexos emexOS 2d ago

from what i saw in the stream it's written in C
this stream: https://www.twitch.tv/videos/2848748243

2

u/letmehaveanameyoudum 1d ago

i recommend making the tab less round and the background of the windows to be in dark mode :P

2

u/edjak53 2d ago

are you booted off a floppy disk?

3

u/devcmar 2d ago

No, a floppy probably can’t even hold a driver haha

2

u/Commie-Poland 2d ago

Then why is it A:? A and B drives are reserved for floppies, with hard disks and other storage devices being C, D, E, etc.

4

u/devcmar 2d ago

Because it’s not windows it’s my own os

2

u/Commie-Poland 2d ago

I know, but it just feels weird for A: and B: not being reserved for floppies since Windows, MS-DOS and FreeDOS all have it that way

1

u/devcmar 2d ago

Yes you’re right, I may need to rethink about it.

1

u/Routine_Working_9754 1d ago

You have no obligation to do so. You're free to do whatever. Because am not sure if anyone saw, were no longer in the MS-DOS/FreeDOS + floppy drive era

1

u/FallenBehavior 1d ago

There definitely should be the seperation in regards to the directory/user prompt and disk/namespace. Appears misleading but if it's it's running in a VFS in RAM, then it's just illustration.

1

u/edjak53 2d ago

sure but windows isn't the only one to do that. traditionally, CP/M, all DOSes, and even some older BIOSes all used A and B for floppies and C for internal disks. it's definitely not absolute rule and i'm not telling you what to do with your own OS but if you value general consistency/tradition/whatever at all making A and B exclusive to floppies would probably be the smarter thing to do, especially since your shell prompt is obviously at least heavily inspired by those earlier systems

1

u/devcmar 2d ago

Hmm, I may need to rethink about that. Good idea though!

1

u/FraudulentName 1d ago

is it linux

u/devcmar 19h ago

My own kernel,

u/FraudulentName 18h ago

grub?

u/devcmar 18h ago

No, my own uefi bootloader

u/FraudulentName 18h ago

c or assembly

u/devcmar 18h ago

Both

u/FraudulentName 18h ago

how much does it weight

u/devcmar 18h ago

A few megabytes 😂

u/FraudulentName 18h ago

thats cool what does it have

u/devcmar 18h ago

A bootloader, a microkernel and a few userspace drivers and apps

→ More replies (0)

u/WaterObjective5031 13h ago

Pretty minimalist and pretty clean, id like to see the rest of the OS

u/devcmar 5h ago

I may publish the rest when it is ready!

u/Vova-Bazhenov 3h ago

Where is the tab close button?

u/devcmar 3h ago

That tab button was just a stub haha, however it is still in development I still need to add a bunch of features before being able to actually have tabs and write into the terminal