#Kvass (vibecoden't)

1 messages · Page 8 of 1

ocean ore
#

oh

#

CRPA I DONT UNDERSTAND ANYTHING

raw prairie
#

The user apps that MMAP it get the file in memory

ocean ore
#

driver do that im not responsible trl

pliant glen
#

kvass

ocean ore
#

if the driver gets a write or copy file operation it can do whatever it wants with the request but i suggest it writes instantly

raw prairie
#

You could also just trl have a generic block level cache for the block device

#

And then copy things when needed

#

But that’s slower technically trl

#

So when the user MMAPs and then hits a fault

#

The FS will copy it from the page cache to you

#

Or some shit

ocean ore
#

i think the biggest problem with my idea is multitasking, because the part that some other process wants will be nuked and now it has to wait for it to get unnuked

raw prairie
#

And then to reclaim memory it can just OOM kill you trol or just unmap pages marked like that and they can be grabbed later

ocean ore
raw prairie
#

You un nuke on page fault

#

You do it lazily racially

#

Basically

#

Fuck autocorrect

ocean ore
#

racist VFS

raw prairie
#

You should name your VFS that

#

But as like race cars

ocean ore
#

no im just gonna put it as a quote or something

#
// "racist VFS"
//       - either joe biden, or some other idiot
raw prairie
#

😭

#

Let me dm you somthing you could do

ocean ore
#

k

#

CONFIDENTIAL: IF ANY INFO FROM THAT DIRECT MESSAGE IS SENT TO THE PUBLIC YOU ARE LIABLE FOR THE LOSSES OF THE COMPANY! THE MESSAGES EXCHANGED ARE TRADE SECRETS AND THEY MUST NOT BE DISTRIBUTED AT ALL!!! EVER!!!

raw prairie
#

Btw @ocean ore that’s more so block layer part

#

For the VFS

#

You uhh use vnodes

ocean ore
#

yes

raw prairie
#

That then link to the file system

#

Etc etc

ocean ore
raw prairie
#

And then a mount table

raw prairie
ocean ore
#

idk

#

im probably gonna abstract the actual vfs away with fancy handles and such for userspace

#

because in reality the nodes are connected by physical addresses pain

#

i have to map these in pain

raw prairie
#

That’s what you do anyways trl

#

But you have to like map in the file blocks themselves

#

Just the file

#

Like the pages that make up the file

raw prairie
#

And you only read them from disk on a fault and if it’s not in cache

#

Otherwise map it properly

ocean ore
#

fair

#

ok honestly i need to first even get to that point without ragequitting

raw prairie
ocean ore
#

i think what ive thought of is good enough imo

raw prairie
#

Maybe I should just put the fry’s in the bag and skip MMAP files for now

ocean ore
#

thats the only evil thing

raw prairie
#

Does anything majorly require that tbh?

ocean ore
#

but its a driver what else is it supposed to do

ocean ore
#

im thinking if a task can only get one event a time or what

#

if its processing that event then probably stall every other task waiting for it

#

if that task doesnt process the event then commit 9/11 on it

#

ok honestly this multitasking crap is both difficult and not really difficult

#

ngl i dont want to add smp for powerpc

#

most macs dont use it

#

the ones that do and actually need the performance should use linux nooo

#

i only know of two high end power mac models that have more than 1 cpu or cpu core

#

the dual core G4 tower and a bunch of power mac G5s

#

and like

#

no other thing

#

maybe some power macintosh tower from the late 90s

raw prairie
ocean ore
raw prairie
#

If a task has too many events

#

It stops getting them

#

That’s it

ocean ore
#

true

raw prairie
#

Unless it’s a KILL

#

In which it kills it

ocean ore
#

if a task gets more than like 5 events then other tasks should either spinlock or skip the call

#

honestly i should add a userspace with SOME systemcalls first before bothering that much with this crap

ocean ore
#

understandable

tough socket
#

shouldnt be ur preferred way to uhm. to uh. uh. uhm..... uh. to uh. uhm

#

synchronize

raw prairie
#

Have your scheduler support proper mutexes

#

So when they lock

#

And it’s not free

#

It blocks your task

#

And goes to another

ocean ore
#

can i first print a HELLO WORLD OR SOMETHING AASHDJKASDHJKASDKHJASKJHDAKJHSD nooo

#

i havent even entered the kernel yet

#

i mean i was the first one who did the "oh guys lets plan a vfs"

#

anyways whatever

#

im gonna figure it out later probably

#

whenever i get to it

#

ok anyways gtg shower

tough socket
#

also do not use vnodes to represent the vfs hierarchy

raw prairie
#

vnodes are just ref counted objects right

#

And using open() gets you one

tough socket
#

theyre whatever you want them to be but sure

ocean ore
raw prairie
#

I forget is it a new vnode every new open()?

ocean ore
#

i need a vfs now actually

raw prairie
#

Or do they get reused for the same file

ocean ore
#

but like just the structure for now

tough socket
#

the vnode is the unique in-memory representation for an on-disk file

ocean ore
#

nothing fancy

raw prairie
ocean ore
#

ok afk im gonna come back and read whatever text wall pops up

raw prairie
#

Hashmap trl

raw prairie
tough socket
#

no

raw prairie
tough socket
#

dont look at dragonflybsd's implementation they duplicate it per-core and keep changes in sync with a log or something

#

its scary

ocean ore
#

a

#

my current system is that i just have a node somewhere in physical memory and its addresses link to other physical memory thingamabobs

#

im gonna probably rework it to use some fancy handles instead of straight up physical memory addresses

#

ok so im gonna go make a horribly basic vfs system tomorrow

ocean ore
#

i think i figured out how i want it to work

ocean ore
#

when i come home i also need to finish setting up gentoo

raw prairie
ocean ore
#

there is none i need to make it trl

raw prairie
#

I also wonder if it would be fun to design my own m68k based computer

#

Than build it

#

And have my own OS run on it

ocean ore
#

m68ks arent produced anymore i think

raw prairie
ocean ore
raw prairie
#

Or an FPGA

ocean ore
#

honestly idk if the mac boot protocol is documented for the 68k

#

ik theres a crap ton of other pcs with tge 68k

#

but this is mainly for macs

#

amiga kvass trl

ocean ore
#

KVASS BITCOIN RIG

#

WERE GONNA GET SOME MONEY AY

#

ok so openfirmware is still scary

#

just thought of how im supposed to obtain pci devices

#

on x86 not on ppc

ocean ore
#

its either acpi or enumerate manually

raw prairie
#

I’m pretty sure it’s fixed tables for PCI?

#

But you have to probe them

ocean ore
#

i think

#

idk i have to either write an aml interpreter myself or steal uacpi

raw prairie
#

Fixed tables aren’t AML

ocean ore
#

NO CRAP SHERLOCK nooo nooo

#

im prolly just stealing uacpi

#

aml is stupid anyway

raw prairie
#

Yeah you don’t need AML I don’t think

#

You just use the standard tables

#

To find the start of the config space

#

Probe the first bus

#

Check for bridges

#

Then find the bus they represent then probe those

#

And it’s some basic math to calculate the buses to the MMIO from the base

ocean ore
#

aeeesddfgf d saw a

#

thats why x86 sucks nooo

#

pci is probably the least bad part of this crap

#

im honestly just gonna integrate uacpi or smth into the kernel due to me not wanting to spend a crap ton of time on adding a programming language

raw prairie
#

No

#

This dosnt use AML

#

It uses tables

#

Which are basic data structures

#

And easy to parse

#

EG

#

You don’t need uacpi

ocean ore
raw prairie
#

You could always do aml parsing in userspace

#

And just do tables in kernel

#

And you don’t need aml for pci/e

#

Which means you can delay it to even mounting the root disk

ocean ore
raw prairie
#

I will

ocean ore
#

anyone but you

raw prairie
#

And @minor prairie Is gonna too

ocean ore
#

is there anyone who actually did it

raw prairie
#

I bet managarm does something like that

#

Because having an AML parser

#

Probably isn’t too micro

ocean ore
#

no betting isnt enough nooo

#

idk man im gonna bother with this acpi crap later

#

or pci

#

mainly pci

#

i need to check pci crap and construct device tree

ocean ore
#

on powerpc open fartware did it for me

ocean ore
#

acpi is probably even scarier because there might be a security thing if i let a process do too much

raw prairie
#

Mamagarm has uACPI

#

BUT

#

@ocean ore

#

Gotcha

#

Do it

raw prairie
#

Bye bye now go have fun

ocean ore
#

in a million years

#

theres no x86 yet

raw prairie
#

@ocean ore you just made my power shut off

#

As soon as you sent that

#

My power fucking turned off

#

And back on

#

😭

ocean ore
#

Time. . .

raw prairie
#

😭

#

Your a time god

ocean ore
#

im not a god

raw prairie
minor prairie
#

ah why

raw prairie
minor prairie
#

oh yeah

#

I will

#

if I get the motivation to work on it :(

ocean ore
#

GENTLEMEN AND UNGENTLEMEN ITS TIME FOR ME TO FINISH SETTING UP GENTOO

ocean ore
#

i just set up arch instead

#

lololol

#

im gonna now copy my powerpc gcc

#

i copied my powerpc gcc

#

wait no not yet

#

waiting

#

now i did

#

i got powerpc gcc now

#

i can kvass again

ocean ore
#

mutually assured destruction is scary

ocean ore
#

funny thing, my virtual memory addresses have to be 64 K aligned

#

because screw you thats why trl

#

one page is gonna be 128 K due to funny tech reasons

#

so memory addresses have to be 128K aligned pain

raw prairie
#

whyyyy

ocean ore
ocean ore
#

ok so im gonna go on a quick side project

#

i figured out how to do polygon rendering on scratch so im gonna make a 3d engine rq trl

#

i got bored at geography class trl

ocean ore
#

REAL polygons

#

untextured trl

#

it adds to the aesthetic trl

ocean ore
#

ok so i forgot the actual audience on scratch

#

yall better know what circus that is

#

the most the kids know is raycasting, and thats because griffpatch told them nooo

raw prairie
#

but i used it

ocean ore
#

its geometry dash and platformers with the same player sprite copied everywhere nooo

raw prairie
#

🥀

ocean ore
#

i thought this was bad with the sheer amount of amd64 operating systems

#

my rotate over x variable makes the triangle smaller nooo

#

braindead 3d algorithm

ocean ore
#

behold magnificent 3d plane

#

software rendering is interesting

#

how much crap can you put before your computer explodes

#

wait

#

was the super fx chip a gpu or a second slightly more powerful cpu

#

it is a cpu

#

but its used for graphics processing

#

techically its a gpu

ocean ore
#

lol someones trying to scam me probably

#

its time for a big troll trl

#

anyways my side project is fine, probably

ocean ore
#

funky z layering

#

i think i need some other place to store my stupid 3d side project in

raw prairie
#

Or some thing

ocean ore
raw prairie
#

Or something like #1008410029990367284

ocean ore
#

honestly i should make a gpu like the vmware svga

#

somehow

#

except itd be cool if it was like an actual physical thing

#

ok so im gonna go generate myself a hmmmm hashmap trl

#

use it for that stupid 3d renderer and make z layering work

#

or not

#

ok honestly should i do it on real hardware for the funny

#

the stupid 3d engine

ocean ore
#

im probably gonna work on kvass later

ocean ore
#

i give up i dont want to 3d anymore

#

it died

ocean ore
#

never let me do 3d graphics again i am NOT built for that

#

literally im so bad at 3d anything

#

so heres the plan

#

give kvass an absolutely insane 2d pipeline for literally no reason trl

#

i mean youll get amiga type graphics

#

thats a good thing except the amiga cant run doom trl

#

anyways so im gonna work on kvass

#

3d is scary my brain hurts more than openfirmware

#

compromise: make kvass mode 7 trl

#

idk why im obsessed with graphics crap

#

BECAUSE I WANT TO BE OBSESSED WITH GRAPHICS CRAP

#

MAS*UIDJKASDASJDASDJASDASKJDHASKJ

muted talon
#

when cyberpunk on kvass

ocean ore
raw prairie
ocean ore
#

3d engine made on scratch vs llvm pipe

silent jay
# raw prairie

"CIRCUS HOP" Damn, it's really saying what it is in itself.

ocean ore
#

they are literally "depressed" (they made up some mental illnesses for themselves for some reason)

ocean ore
#

scratch can barely process 400 something polygons

#

i revived my stupid engine project

#

time to optimize yeehaw trl

#

i cant optimize

#

how

ocean ore
#

the app store page for microsoft word is so funny because they have to explicitly state what they collect and it straight up says word collects "location, contact info, contacts, user content, diagnostic info and user usage patterns"

#

lol spies trl

#

anyways so i got demotivated so ima work on kvass later depresse

ocean ore
#

FOOLS

#

I AM MOVING TO A CORE 2 DUO

#

IT HAS A GOOD KEYBOARD

#

THE GPU SUCKS BUT I DONT THINK I CARE

#

NVIDIA IS STUPID

#

AAAAAAHSAHJDBNASDBANSDBNASD

#

anyways so like i need to finish my vfs but this entire thing is kinda on hold

#

ragequit on booting the system 😔

ocean ore
#

obligatory fastfetch

#

time to check if qemu runs at a reasonable performance

#

this fart has a mechanical hard drive

#

maybe i should replace it with an ssd

#

but i installed arch already and idk how expensive an ssd is

#

lemme check

#

1TB for 149 dollars

#

89 for 500 gigs

#

im looking at smasnug drives

#

crucial drives definitely work but we don't talk about crucial trl

#

ok thats more of a depresse moment but i hate micron now

#

hate is way too strong for my feelings towards them

#

im sad for them i dont want to buy their stuff anymore

#

whenever they come back

ocean ore
#

looks reasonable honestly

#

but man i just installed linux on an old fart and now im considering nuking it just because its being bottlenecked by a hard drive nooo

#

ehhhhhhhhh if i have to i will nuke it anyway i dont store anything on main hard drives these days anyway trl

#

i actually dont store anything at all trl

#

except kvass source code

ocean ore
#

(i still havent run it on my thinkpad yet)

ocean ore
#

ill never be able to use any other laptop keyboard again vro

#

this one is so cool

#

anyways so i fixed openfirmware virtual mapping

#

unmapping crap broke

#

i can peacefully load my kernel now

ocean ore
#

people i am basically almost ready to try actually booting the kernel

#

i set up enough crap to load it into memory without going insane

#

ok i actually loaded it

#

i loaded my fart into memory

#

so much time and yet this is simply a bootloader 😔

#

whatever

#

ok so should i load the kernel at ⁨0xC0000000⁩ or somewhere else

muted talon
#

bootloader is the hardest part

ocean ore
raw prairie
#

Yours sure is good

ocean ore
ocean ore
raw prairie
#

Can it load files off the disk?

ocean ore
#

with like a fancy boot protocol

raw prairie
#

Don’t need to be fancy

ocean ore
#

maybe ill add in ramdisk support

#

its really kvass specific

#

literally searches for a file named ⁨kvass-kernel⁩ or whatever, its signature must be ⁨KVASS OPENFIRMWARE POWERMAC⁩ i think, and the bootloader itself is just called ⁨kvass-loader

#

(the signature originally was ⁨OPENFIRMWARE SUCKS!!!⁩ btw)

#

the kernel must be a flat binary etc

raw prairie
#

Just have a config file to tell you what kernel elf to load and execute

#

(Elf loading is easy DW)

ocean ore
#

i fr dont know if i should somehow spin this out into its own bootloader with a protocol and such

#

honestly thatd be cool id consider it

#

the kernel must still be a flat binary tho trl

raw prairie
#

And kernel binaries are static anyways

ocean ore
#

fine im gonna add elf support later

raw prairie
#

So you just need to parse the most basic aaa headers

ocean ore
#

the problem is that i cant really enumerate the file size @raw prairie

#

so the file size has to be put somewhere

#

in the file itself

raw prairie
#

The elf file tells you that

ocean ore
raw prairie
#

Like it says the size of every section etc

#

And where in the file to go

ocean ore
#

fair

#

im gonna add it later trust

#

i just want something that boots friggin kvass

raw prairie
#

My elf loader does not care about size 🙏

#

How about

#

I make an elf loader

#

For kvass-loader

#

And il submit patches

#

Because talk cheap

ocean ore
#

"send patches" -- ffmpeg

#

crap i have to rework my entire thing now

#

the stupid build system i made

#

for kvass AND for this stupid thing

ocean ore
#

he's like phoenix

#

rises right after he gets murdered

raw prairie
#

Your getting elf loading

ocean ore
#

aaaaaaaaa nooo

raw prairie
ocean ore
#

anyways lemme just start copying crap now

#

im crashing out if this idiot doesnt boot

#

@raw prairie yo do you use a build system at all

#

idk if i should use one

raw prairie
#

Make files

ocean ore
#

ok fair

#

i mean i just have a configure script, and then that script is included in the makefile

#

its better than going into the makefile itself imo

ocean ore
raw prairie
#

What you can do for your boot protocol

#

Is have section names you can check with the elf

#

And then have magic numbers and stuff

#

If you wanted a protocol for like something

#

Or even load the data to be fixed in memory starting at virtual 0

#

And then you move it yourself later

muted talon
ocean ore
muted talon
ocean ore
#

im too lazy to commit

muted talon
#

i wanna do an elf loader

#

im bored asf

#

pwease cuddle

#

wait wrong emoji nooo

ocean ore
#

sir

muted talon
#

what sir

raw prairie
#

Btw @ocean ore is Greg loader little or big endian

ocean ore
#

(big endian on powerpc)

raw prairie
#

Idk how to make a big endian elf loader

#

As it’s a little endian format

ocean ore
#

idk i can consider making a little endian mode switch

#

later

#

i dont want to do it rn

raw prairie
#

It would just be conversion on the header fields

#

So it should be fine enough for me to do

#

And il learn doing it

#

Or some crap

muted talon
#

depresse please get me the repo i want to do kvass depresse

#

oh wait i forgot i have the kvass kernel downloaded already

gloomy mist
raw prairie
#

I implemented a driver for FRED

#

I did it first

#

I got the role

gloomy mist
#

what's FRED?

raw prairie
#

Better IDT for rich people

gloomy mist
#

eh, I don't understand, is it an os or what

raw prairie
#

Interupt descriptor table?

#

An IDT

gloomy mist
#

yes? but idt has nothing to do with that name

raw prairie
#

The FRED is the new version of the IDT on very new hardware

gloomy mist
#

very new hardware of what arch

raw prairie
#

X86-64

#

I’m talking about the IDT

#

Lmfao

gloomy mist
#

why do we need a new version of the idt, what does it give

raw prairie
#

It makes it faster and you don’t need a table

#

It even combines system calls into the same system

#

It pushes a bunch of things onto the stack and called a function you set

#

And then you choose from there

gloomy mist
#

can it even be emulated rn?

raw prairie
#

It can be

#

With Intel SIMICS

#

That’s how I got a driver working

#

Here read the spec

#

But this is getting off topic from @ocean ore s channel

gloomy mist
#

hmmmm it's going to be decades before everyone's using it in practice

#

I mean most systems still have support for PIC

#

Even though everyone moved to APIC years ago

#

we will just end up with three different ways to deliver interrupts instead of two

#

and still needing apic for ipis

raw prairie
gloomy mist
#

ah I get it

#

but kernels are going to need to versions

#

iret/idt, eret/Fred yes?

raw prairie
#

yes but it’s not that hard

#

And again this is off topic for here

#

So may be better to move lol

gloomy mist
#

nah

#

if you want to only appeal to people with a brand new CPU sure

#

ah wait only read the last half

#

lol

ocean ore
ocean ore
#

me no idea

#

also im now pissed at my choice (not regretting) at making the stupid kvass loader into a full separate bootloader

#

i have to rework practically everything in it

ocean ore
#

you can use both bats and pages btw

#

wait

#

holy crap

#

vsids can have a format you made

#

theres no predefined algorithm

#

i obtained a revelation on powerpc paging

#

this is severely mind boggling

#

how do i generate these addresses though

#

im not a cryptographer

#

or whatever

#

oh

ocean ore
#

they put it somewhere

#

free to use crap

#

the kernel is still loaded in a bat though trl

#

ALSO THE PAGES ARE 64K ARE YOU KIDDING ME

#

or not

#

schrodinger's paging

#

its a 19 bit number instead of a 15 bit one in the bats

#

ibm is there any particular reason to align bats by 64K and regular paging by whatever this is thinkong

#

i mean the bats are 64k aligned but they have to be at least 128k in size

#

i just align them by 128

ocean ore
ocean ore
#

regular 4k pages

#

ibm why

#

just so yall know how stupid this is the size for a page entry is the same size for one bat

#

theres several reserved bits after the 15 bit address

#

theres literally no way they couldve not used the reserve bits to make the address 4k aligned

#

psychotic idiots nooo

#

also segment registers

#

it is picked depending on what letter your address starts

#

0 = sr0
1 = sr1

E = sr14
F = sr15

#

0xDEADBEEF would use sr13

#

it starts with a D

#

unless i cant count NOR do i know the alphabet and its actually sr12

#

segment register contain vsids or something

#

also you should always memset your newly allocated pt's with 0s

#

obviously

#

on all cpus

#

if some stupid crap happens with addr translation that will result in a bunch of unwanted flashy visual effects

#

(triple fault)

#

(possibly)

ocean ore
#

XOR??????!?!!?!?111?!??1

#

@raw prairie the paging might be better than what i told you it was

ocean ore
# ocean ore

HTABORG is origin and HTABMASK is some stupid size thing btw

ocean ore
# ocean ore

ok so this looks like addresses get a vsid appended to them depending on sr, then the vsid and page idx are xor'd and that makes a pteg

ocean ore
#

ok so im gonna do a hopefully reasonable explanation of powerpc paging

#

there is the page table

#

it has entries (duh)

#

a PTEG is simply 8 entries

#

it is nothing but 8 entries

#

there are no pointers to it like on other cpus its just 8 entries in the page table

#

every page table entry (PTE) has a vsid and the real address it points to

#

that vsid is (id say) revelantn't

#

the vsid is a 24 bit value

#

it can be randomly generated

#

it can even be all 0's

#

now heres complex crap

#

an effective address consists of the following

  • 4 bit segment regiser (sr) value
  • page index
  • byte offset
#

there are 16 sr's

#

ok anyways yeah

#

sr's contain vsids

#

(essentially)

ocean ore
#

the 19 top bits of the vsid and the page index are FRICKING XOR'D

#

now you get the address of the pteg

#

i think

#

you CAN get it i meant

#

this is how you get the address

#

and now how is that final page table entry found?

#

no idea lol pain

#

you get a pteg address though

#

progress

#

oh also to make page tables you have to calculate all that crap i assume

#

thats how the cpu do it so you better do it how the cpu do it

ocean ore
#

probably

#

not sure

#

nvm theres simply no way for more trash to fit

ocean ore
#

ok im gonna be unironic here you actually can use the doom rng table

#

100% serious

#

i should do that trl

#

oh wait

ocean ore
#

wait tho

#

makes sense honestly

#

lemme read more

#

ok so yeah it makes sense

#

i understand now galaxybrain

#

anyways gregloader is gonna load crap into bats

#

bats are faster

#

im gonna use them for executables

#

or not

#

whatever

ocean ore
#

essentially its a whole mess im too lazy to explain nooo

#

simple explanation is "its actually 4 per pteg"

ocean ore
#

greg is being summoned into existence

ocean ore
#

certified macintosh

#

its not even a gui its just graphical

#

maybe

#

idk im adding the boot picker for greg

ocean ore
#

im making a library to parse ini format files

#

im not gonna add write support

#

we have text editors nooo

#

its for the greg config files

#

anyways im gonna open source it when im done with it

raw prairie
#

Can it load elf’s

ocean ore
muted talon
#

pentagon bomb codes parser better

ocean ore
#

also im making the parsers portable so i can reimplement them in either the kernel or some other thing

#

especially the config file one

#

idk what i would need the psf and elf parsers for tho

muted talon
#

gdt on powerpc is crazy

ocean ore
ocean ore
ocean ore
ocean ore
#

ILL BE printf

muted talon
ocean ore
muted talon
ocean ore
muted talon
#

fuckingterm

ocean ore
#

crapterm and greg vs flanterm and limine monopoly trl

muted talon
#

fuckingterm ™

ocean ore
muted talon
#

you got it its a fucking terminal

muted talon
ocean ore
#

ok so i got tired of kvass being a total circus

#

im not sure if the almighty "crapterm" will even exist

#

it probably would because its funny

#

the boot protocol might be close to the open firmware one

#

BUT without the devtree

#

im thinking making the bootloader do pci enumeration

#

ok honestly the devtree might be useful for that

#

it might be complex to travel though

ocean ore
#

or not

#

idk some cpus dont have pci io port crap

#

(powerpc)

ocean ore
#

i think you have to get it somewhere

#

idk ofw

ocean ore
#

the ini and elf parser libraries are no longer portable

#

because screw you make your own implementations this is osdev MUAHAHAHAHAHA /hj

ocean ore
#

the ini im using is a dialect of it probably

#

my comments are written with # and not ;

#

ini is honestly the best thing to come out of windows

#

straight up i think its the best thing they made ever

#

it would be cool if there was ini but with subsections but thats basically XML atp

#

and XML sucks

#

probably

#

it looks painful to implement

#

outright pain

#

actually wait no thats not xml xml has tags

#

im talking about smth like

[section]
    [subsection]
    key = value
#

this can have several uses like in a bootloader theres a style section and a boot entries section

#

anyways i have hands and a programming language im gonna implement that crap

ocean ore
#
[section]
      key=value
      [subsection]
           keyn't = valuen't
[section 2]

ajdbahsbajwbajjaoqoa

#

call that kvass configuration file idek 👍

ocean ore
#

maybe treat each section as its own config file trl

ocean ore
#

i need to make it so subsections are ignored if you want to access key

#

also if it finds a subsection it should probably seek a line that doesnt start with a tabulator to ignore it (in this case at least)

#

if it starts with 2 tabulators or spaces your kneecaps wont see the light of day again trl

#

if its spaces its just not a section anymore but if its two tabs then lol syntax error

ocean ore
#

ok so i did my config format

#

looks fine time to implement

ocean ore
#

apparently linus torvalds was a fan of powerpc

#

but the paging depresse

ocean ore
#

time to attempt and parse this

tough socket
#

Didn't he notoriously hate the memory management

#

Which was mostly his fault because his kernel wasn't written generically enough

ocean ore
#

yeah he hated paging on power/ppc REALLY bad

ocean ore
#

theres a big endian and small endian version for each

#

some friggin #define toggles between what implementation to use

#

dont quote me on it but im pretty sure theres central out/in b/w/l's and then they just reroute to BE or LE

tough socket
ocean ore
tough socket
#

More about Linux's mm depending on the existence of a multi level page table

ocean ore
#

oh

#

i feel like my mm might have a problem with that

#

i might depend on inverse page tables too much

#

i can implement something like that on x86 but like idk

#

im planning to make whats essentially an architecture specific back end for stuff like a vmm, it just maps addr's in and out

#

the "is that virtual address range used already or nah" is the job of the portable vmm thing

#

and other crap like "can kernel/user execute/see/write (to) this"

#

physical allocator might just be portable, its really the job of the bootloader to provide memory map crap

#

i forgot to specify what crap oops nooo

ocean ore
#

gonna work on configs when i get home

#

my goal is to make some crappy hello world program for gregloader

ocean ore
#

idea: LINK the boot script and other crap into the binary thats gonna be loaded itself

#

this is so stupid but hear me out trl

#

actually no this is stupid dont hear me out 💔

#

but what i wanted to do is basically use this crap for like embedding boot info

#

such as at what address should the binary be loaded

ocean ore
#

ehhh trl

#

my idea is to probably wipe the space of the text file and replace the contents with bootloader info

#

my idea is to have a relocatable (i think) callback function that can be used instead of the stupid tag system other bootloaders have

#

maybe not relocatable

#

map it at 0 or bust trl

#

my excuse was that it takes less space but this crap takes a BUNCH of space nooo

#

especially the "lol lets link a text file into an elf binary" part

#

no putting structs in there would be too normal

ocean ore
#

no idea

#

@raw prairie wanted me to do it trl

ocean ore
#

FOOLS I HAVE DECIDED CALLBACK FUNCTIONS AREN'T EVEN PRACTICAL

#

I THINK

#

idek you have to unmap them once done the system would suck on x86

#

everyone does their own cr3 anyway

#

OK MAYBE A CALLBACK FUNCTION MIGHT BE PRACTICAL HONESTLY

ocean ore
#

ok so im bored im making a linux distro

muted talon
ocean ore
#

make a package manager port that to kvass later

#

custom init system trl

#

literally kvass if i made it linux based instead

ocean ore
#

but like

#

lunix

#

im gonna be one of the one powerpc distros

#

ok not but whatever

#

i compiled the kernel already i need

  • glibc
  • coreutils (evil crap)
  • bash
  • init system (probably make my own)
  • package manager (also probably make my own)
  • fastfetch trl
  • bootloader (i want to add linux support to greg)
#

the 7 deadly doohickeys

#

technically 8 including the kernel

ocean ore
muted talon
ocean ore
#

maybe

#

i need to make a non os progress thread about the thing

ocean ore
muted talon
ocean ore
#

cd better exist pain

muted talon
#

it has "variables", builtins

#

cd, cwd

#

and required 8 os-specific functions

#

5 of them can be stubbed

#

read it

ocean ore
#

fair

#

ima try porting it to kvass later if the lunix port doesnt make me go insane

ocean ore
#

no environment variables??? trl

muted talon
#

shitty but works

ocean ore
muted talon
#

char S1[100];
char S2[256];
char S3[512];
muted talon
#
err: file '/bin/set' doesn't exist.
[makst] / % store S1 /home/makst/mash
[makst] / % ls $S1
Makefile  execut.c  inc  inch  main.c  mash  mash_linux.c  readme.md
[makst] / %
ocean ore
#

but variables like $CC??

muted talon
ocean ore
#

oh

muted talon
#

make runs perfectly

ocean ore
#

do these also function like registers??

muted talon
#
[makst] / % cd $S1
[makst] /home/makst/mash % make all
gcc ./inc/lg.c ./inc/string.c ./main.c ./execut.c ./mash_linux.c -o mash
sudo cp mash /usr/bin/mash
[sudo] password for makst: 
cp: cannot create regular file '/usr/bin/mash': Text file busy
make: *** [Makefile:8: cp] Error 1
[makst] /home/makst/mash %
#

nah envp is char**

ocean ore
#

oh

#

malloc

muted talon
ocean ore
#

NOOAOAOAOAOA

muted talon
#

thats +1 os-specific function

ocean ore
#

ae

muted talon
#

thats -3 points of portability

ocean ore
#

i might port it to the lunix and then make it an optional package ngl

ocean ore
#

im bored so i decided to make an actual build system trl

ocean ore
#

least insane kvass related bug

ocean ore
#

dont call it that

#

im offended

#

(something broke again)

#

what the FRICK is stack smashing

#

oh

#

ok thats horrible what 😭

#

what broke

ocean ore
# ocean ore

now a function i made outright refuses to work

raw prairie
#

@ocean ore it uhhh

#

Means your stack got broken

#

Your doing undefined behavior

ocean ore
ocean ore
raw prairie
#

Your program is

#

Did you overflow any buffers

ocean ore
#

then relaunch the program trl

ocean ore
#

i fixed it

raw prairie
#

That’s what SSP prevents

ocean ore
#

anti smash stacker 👍

vale vale
#

stack smashing protector

ocean ore
#

everything as a file in linux is peak

#

peak keyboard code

#

ngl i wanna make a text editor

#

nano ripoff trl

#

i need to pull out more eastern european foods and drinks now 😔

raw prairie
ocean ore
ocean ore
#

insanity

raw prairie
#

its actualy a really solid eidtor tho

ocean ore
raw prairie
raw prairie
#

vodka is what gets ya going in the morning

ocean ore
ocean ore
#

its like juice except its evil

#

allegedly

#

maybe i should call the text editor that

#

no idea

ocean ore
#

ULTRAtext trl

ocean ore
#

holy crap i figured out how to do live resizing if the window size is changed

#

peak

#

posix is actually kinda fire

#

im implementing that on top of my os tho, enjoy non standard system calls MUAHAHAHAHAHAH trl

#

also i think i mightve went the gnu route

#

make all the utilities first, then make the kernel (if thats ever even made) nooo

#

happens sometimes

#

kvass aint dead i just have brain damage

#

LETS GOOOOO

#

i need to steal this crap for gregloader ngl

#

wait its just gonna look like limine then

ocean ore
#

i mean idk

#

does mlibc have posix functions?

#

my plan is to have a literal non unix but unix apps can be built and compiled

#

posix apps are portable enough anyways trl

#

so i can still have my cursed drive structure trl

#

port mac fdisk idk

ocean ore
#

100% ascii compliant terminal sounds fire ngl

raw prairie
#

And VT100

raw prairie
ocean ore
#

vt100 especially

#

hide cursor and crap

ocean ore
#

i need to name my terminal emulator somehow

#

time to pull out the "ukrainian drink" card trl

uzvar

arctic plank
ocean ore
#

im gonna go work on an mlibc port for powerpc linux for some reason

#

@vale vale ok so your script decided to not work, but i basically figured out what it did

musl doesnt wanna configure tho :/

#

gcc and binutils compiled fine

#

im thinking of retrying with glibc

#

no idea if that would work but whatever

#

long double 64 seems to be the most important one

#

since its complaining about floats

#

no way it only supports little endian powerpc

raw prairie
ocean ore
#

i want a working lunix first

ocean ore
#

i just realized i have like 3 projects now atm

#

the stupid mlibc port, my build system, and gregloader

#

i swear bro greg has had more of an actual existence than kvass itself 😭

ocean ore
#

ok so im gonna make an automatic horribly tiny linux from scratch builder tool later probably

ocean ore
ocean ore
#

i didnt want to ruin the original source

#

the 1 and 2 files

#

anyways i built glibc fine tho

#

now bash is actively trying to kill itself (even after ive made a patch to fix this specific error)

#

i dont think i should patch gnu utilities at all and just put the blame on myself but whatever

#

whatever its getting a (void*) instead trl

#

where's the "abandon hope all ye who enter here" in bash like in xterm

#

gnu is gonna get so much patches they're gonna block me for spam

#

so wait

ocean ore
#

GNU

#

GNUUUUUUUUU

#

ok so it returns an int

#

gnu

#

let me tell you how much ive come to HATE you since i began to live

#

ok honestly gnu are fire but like what is this

#

LITERALLY WHAT IS THIS

#

an entire screen worth of errors on 8px font

#

i tried to compile it with gnu99

#

what 😭

#

fine idiot im going busybox

#

nevermind

#

Z SHELL 👍

#

i need to make a separate thread about the linux distro

#

this aint even kvass anymore nooo

#

i hate autoconf

#

or whatever its called

#

GNU AUTOTOOLS

#

WHAT

#

THERES GNU AUTOTOOLS AND AUTOCONF

#

😭

#

autofarts

#

they suck

#

gnu get your game up

#

you need literally the whole universe in your favor to build anything using autoconf

vale vale
vale vale
#

If a release fails, check a snapshot (or alpha.gnu.org) or a recent git commit. If it still fails, but with a different error, then keep going back in history until it fails with the same error

#

Basically bisecting it

ocean ore
#

true

ocean ore
#

ok so im making my own shell because none of them want to compile trl

#

how practical

#

n't

vale vale
#

Gentoo supports ppc32(be?)

ocean ore
ocean ore
#

ok so im gonna download a version from their website instead of the latest git commit

#

(zsh)

#

i think the blame is on me here

#

both of them 100% exist

#

yehs

vale vale
#

You can get self hosting easier that way

ocean ore
#

lemme just solve the stupid header problem

vale vale
#

What's the issue you're having with bash?

ocean ore
#

lemme pull out bash again ima show you whatever error i get fist

vale vale
#

Logs or it didn't happen

ocean ore
#

first*