klange changed the topic of #osdev to: Operating System Development || Don't ask to ask---just ask! || For 3+ LoC, use a pastebin (for example https://gist.github.com/) || Stats + Old logs: http://osdev-logs.qzx.com New Logs: https://libera.irclog.whitequark.org/osdev || Visit https://wiki.osdev.org and https://forum.osdev.org || Books: https://wiki.osdev.org/Books
eddof13 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
FreeFull has quit []
deflated8837 has joined #osdev
immibis has quit [Ping timeout: 260 seconds]
* mjg burps
* mjg looks around
<mjg> is g guy around?
<mjg> solaris is shite
* mjg hides
<mjg> "linux kernel development" by robert love is probably the least bad practical systems book
<mjg> so i'm looking at The Design and Implementation of the FreeBSD Operating System 2nd edition
<mjg> dated 2014
<mjg> reading vfs stuff
<mjg> it describes state which is 1. outdated 2. .. and bad
<[Reinhilde]> how is solaris not great?
<mjg> the only thing great in solaris is lock contention
<mjg> despite their incessant marketing back in the day claiming the opposite
<mcrod> hi
<heat> mjg you need to take anti-hating pills
<heat> anti-hating-old-systems
<mjg> anyhow
<mjg> > Unlike many vendor’s vnode implementations, which have a fixed number of vnodes allocated to each filesystem type, the
<mjg> FreeBSD kernel keeps a single systemwide collection of vnodes.
<mjg> what does this even mean
<mjg> even openbsd does not have "fixed number of vnodes allocated to each filesystem type"
lainon has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<mcrod> it is hot.
<heat> mjg the magic garden explained is good
eddof13 has joined #osdev
<mjg> that one i barely seen, it might be
<heat> even has detailed pseudo code for certain routines
<heat> like lookuppn
immibis has joined #osdev
<heat> (because UNIX people are alergic to good names)
<mjg> aah klassik unix internal vfs api
<mjg> i don't think you appreciate just how bad it is
eddof13 has quit [Client Quit]
<mjg> however, i can say something positive about a rather non-obvious nugget
<mjg> when going across mount points, the code makes sure to vfs_busy() the target filesystem, unlock the mounted-on vnode and only then proceed across
<mjg> as opposed to find + lock the next vnode while holding the previous one
<mjg> asssume they went the naive way
<mjg> say the root vnode is locked and the lock owner blocked. e.g., tthis is a nfs client mount and things are not going well
<mjg> maybe remote server is dead
<mjg> in this case the thread trying to cross the mount point will block as well, having the previous vnode already locked
<mjg> then someone else can block trying to get that vnode, while still having a lock on the vnode prior to that one
<mjg> and so on all the way up to the rootvnode, de facto suspending all lookups
<mjg> because of one pesky fs down the tree
<mjg> in contrast, with their approach they localize hangs only to lookups which try to cross over
\Test_User has quit [Quit: \Test_User]
<mjg> >This book was produced using James Clark’s implementations of pic, tbl, eqn, and groff. The index was generated by awk scripts derived from indexing programs written by Jon Bentley and Brian Kernighan
<mjg> right on
\Test_User has joined #osdev
<mjg> heat: The implementation of the stacking has been refined in FreeBSD, but the semantics remain largely unchanged from those found in 4.4BSD.
<mjg> filesystem stacking
<mjg> nullfs (a linux --bind equivalent) would keep crashing everyone
<mjg> openbsd spent quite some time trying to make it work in their fork, they gave up
<mjg> i don't know about net
<mjg> freebsd, after a metric fuckton of hacks, managed to get it to work well enough to not crash
<mjg> it is of course slow af and introduces dumbfuck problems all over
elastic_dog has quit [Ping timeout: 246 seconds]
<heat> what book is that?
<heat> i know the k&r book has the actual pic tbl eqn groff command pipeline :p
<mjg> still d&i
<heat> d&d but for even nerdier people
<mjg> i wonder if there is market for a book which shits on other books
<mjg> and papers
<heat> #osdev-shitter
<mjg> and by that i mean points out how they misrepresent what they describe
<mjg> design and implementation of the onyx kernel when
<heat> i can't write docs sorry
<heat> some bits are also not sound enough to describe
<heat> writeback for instance
<mjg> take a page from the above dudez
<mjg> you neglect to mention problems
<heat> i'll never ever be happy with the state of my os, so i can't release and i also can't really document a "stable" thing
<heat> the vm works fine but it's also deeply flawed and cuz of that i don't like it
<heat> the file stuff takes a spinlock for fd lookup and cuz of that just sucks
<mjg> this makes me wonder, are the above people genuinely happy with it
<heat> ask mckusick
<geist> i doubt it. i've never known a kernel person to be happy with it
<mjg> to the d&i book credit it does not sound self-aggrandazing
<mjg> on the other hand the solaris internals one...
<heat> if i were a freebsd kernel oldie i would probably not feel happy with the state but i would 100% be happy with the legacy
<heat> like, making a kernel good enough and stable enough to have wide (for some definitions of wide) usage is impressive enough that i would be happy
<heat> even if flawed
<mjg> dude it was definitely an achievement back in the day
<mjg> to make it oepratinal to begin with
<heat> it's more of an achievement now
<mjg> nobody new squat, all trial & error
<heat> back then if shit crashed so be it
<heat> fuzzing? what's that
<mjg> did you hear the story how they hardcoded swap in the kernel
<mjg> :]
elastic_dog has joined #osdev
<heat> n0
<mjg> so that's how it was "configured"
<mjg> then they replaced the disk with a bigger one
<heat> did they hardcode the swap device?
<mjg> and there was random data corruption
<mjg> because they did not recompile the kernel with new block range for swap
<heat> i can imagine the swapping being much more important back then as UNIX was reliant on swap in the early ages
<heat> also how can you shit on solaris so much but then say shit as "nobody new squat, all trial & error"
<mjg> because they were adamant their kernel *scales*
<heat> 1) the idea of "scales" changed over time
<mjg> no
<heat> 2) ignorance is bliss
<heat> yes
<mjg> their own paper shown that it does not
<mjg> when they claimed othewrise
<mjg> i refer to you to the venerable bonwick's piece
<heat> which one?
<heat> vmem?
<mjg> the one with per-cpu caching
<mjg> probably vmem
<heat> yeah vmem
gildasio has quit [Quit: WeeChat 3.8]
<mjg> there are people out there which fetishize the old systems
<heat> looks like it scales
<mjg> when i shit on these systems i mostly really shit on these people
<mjg> are you serious?
<heat> yes
<mjg> of course the allocator started scaling with this paper
<mjg> check the general bench of the system
<heat> paper does not talk about scaling of anything else
<heat> does show improvements for one of their benchmarks (KENBUS), but nothing crazy (presumably because of other bits)
<mjg> that is the graph i meant. you may notice they do about 8x of baseline
<mjg> on a 24-core machine
<mjg> meaning it does not scale
<heat> but it obviously does a lot more than memory allocation...
<mjg> im' not claiming the allocator does not scale, which it clearly mostly does
<mjg> i'm saying the kernel as a whole does not
<heat> well, that's not really the point of this paper
<heat> in fact, not mentioned there, i checked
<mjg> i did not claim the paper claims the kernel scales, he could not do it
<klange> fetishizing old systems is called nostalgia
<mjg> if you want a taste of gneeral sun engineering see Figure 6.2: malloc/free Performance
<mjg> mtmalloc, short from multithreaded malloc, did not scale
<mjg> and htey only found out while working on this paper
<mjg> :]
<mjg> klange: i found most fetishization coming from youngsters who don't know any better
<mjg> klassikkk line: 4.2bsd was an engineering marvel
<mjg> [it was not]
<mjg> it was tech debt on tech debt
<mjg> interestingly quite a bit of cpu waste as well
<mjg> before someone claims they optimized for THE VAX
<klange> Nostalgia for things one never experienced themselves is called anemoia, a relatively recent coining.
<[Reinhilde]> engineering marvels are sometimes bad
<mjg> > During our measurements we found several serious scalability problems with the Solaris mtmalloc library. mtmalloc creates per−CPU power−of−two freelists for sizes up to 64K, but its algorithm for selecting a freelist was simply round−robin thus its workload was merely fanned out, not made CPU−local
<mjg> fucking GENIUS
<heat> yeah and they fixed it and admitted it was wrong and now it's decent
<heat> what now
<mjg> how the fuck did this happen
<mjg> is what i'm asking, that's "what now"
<mjg> > Moreover, the round−robin index was itself a global variable, so frequent increments by all CPUs caused severe contention for its cache line.
<mjg> even if one is to mess up like this, even basic benching of the routine would find this
<mjg> so again how did this ship
<heat> their solution is also flawed
<[Reinhilde]> it's very possible this got on the truck because it at least worked correctly, and the only thing it failed is the performance
<mjg> i'm afraid this concedes to my opening statement of solaris being shite
<mjg> :]
<[Reinhilde]> stilefystem
<[Reinhilde]> all this computing was a mistak
<[Reinhilde]> e
<mjg> at least it got us windows 95
<mjg> so
<mjg> i take it
<[Reinhilde]> I just wanna jam, and read books
<[Reinhilde]> and talk to people on the other side of the continent
<mjg> continent?
<mjg> brah
<mjg> where are you anyway
<[Reinhilde]> west of canada
<mjg> then you have to talk to someone else
* mjg hails from europe
<mjg> so does heat coincidentally
<[Reinhilde]> anyway...
sjrct has joined #osdev
heat has quit [Quit: Client closed]
heat has joined #osdev
<kazinsal> [Reinhilde]: west coast best coast
<[Reinhilde]> hardly
<kazinsal> at least it only snows like, two weeks of the year here in vancouver
<[Reinhilde]> at the end of the day it's all stolen grandeur on a stolen land
<[Reinhilde]> you have never had to trudge through prince george snowstorms, and with this planet's luck, in my lifetime you never will even if you come up here
<kazinsal> I've been to whitehorse in the middle of winter for work before, it's definitely unpleasant
<[Reinhilde]> it's all the disadvantages of vancouver in the summer, plus aridity, and all the disadvantages of the horse
sjrct has quit [Ping timeout: 246 seconds]
<[Reinhilde]> it's Not Good
<[Reinhilde]> barely anything grows here, it gets brutally cold and brutally hot
<[Reinhilde]> it's also a model fucking American city, other than the terminal gun issues on the other side of the border
<[Reinhilde]> have to drive 3 kicks to get groceries, get killed if you're a cyclist, everyone hates you if you're not from these parts
<[Reinhilde]> or if you're too from these parts
terrorjack has quit [Quit: The Lounge - https://thelounge.chat]
MiningMarsh has quit [Ping timeout: 245 seconds]
<geist> kazinsal: how about that summer weather eh?
<geist> you have smoke up there right now?
terrorjack has joined #osdev
<kazinsal> just got the special weather statement this afternoon saying "smoke incoming prepare your lungs"
<geist> it's clearing up here, may be swinging that way
<kazinsal> I can see a bit of a haze toward the east this evening so it'll probably be here tomorrow
<geist> no where near as bad as in the past, just that first smoke of the season, lungs and eyes aren't prepared
<kazinsal> yeah, it's been pretty good compared to around this time the last few years
gog has quit [Ping timeout: 260 seconds]
duderonomy has quit [Ping timeout: 245 seconds]
duderonomy has joined #osdev
benlyn has joined #osdev
PapaFrog has quit [Read error: Connection reset by peer]
LostFrog has joined #osdev
kneskade has joined #osdev
benlyn has quit [Ping timeout: 246 seconds]
kneskade has quit [Ping timeout: 246 seconds]
_whitelogger has joined #osdev
dude12312414 has quit [Quit: THE RAM IS TOO DAMN HIGH]
innegatives has joined #osdev
innegatives has left #osdev [#osdev]
heat has quit [Quit: Client closed]
sprock has joined #osdev
zxrom_ has joined #osdev
zxrom has quit [Ping timeout: 252 seconds]
slidercrank has joined #osdev
zxrom_ is now known as zxrom
plarke has quit [Remote host closed the connection]
gareppa has joined #osdev
GeDaMo has joined #osdev
jjuran has quit [Quit: Killing Colloquy first, before it kills me…]
jjuran has joined #osdev
paulbarker has joined #osdev
paulbarker has left #osdev [#osdev]
[itchyjunk] has quit [Remote host closed the connection]
tomith has joined #osdev
mahk has quit [Ping timeout: 250 seconds]
mahk has joined #osdev
danilogondolfo has joined #osdev
ZipCPU_ has joined #osdev
bliminse has quit [Quit: leaving]
ZipCPU has quit [Ping timeout: 245 seconds]
ZipCPU_ is now known as ZipCPU
nyah has joined #osdev
ZipCPU has quit [Quit: ZNC 1.7.5+deb4 - https://znc.in]
ZipCPU has joined #osdev
awita has joined #osdev
Left_Turn has joined #osdev
gog has joined #osdev
nur has quit [Ping timeout: 240 seconds]
Terlisimo has quit [Quit: Connection reset by beer]
Terlisimo has joined #osdev
mahk has quit [Ping timeout: 252 seconds]
gildasio has joined #osdev
thinkpol has quit [Remote host closed the connection]
thinkpol has joined #osdev
mahk has joined #osdev
riverdc has quit [Quit: quitting]
riverdc has joined #osdev
asarandi has quit [Quit: WeeChat 3.8]
asarandi has joined #osdev
zxrom has quit [Ping timeout: 245 seconds]
MiningMarsh has joined #osdev
Left_Turn has quit [Remote host closed the connection]
Left_Turn has joined #osdev
smko has joined #osdev
zxrom has joined #osdev
Turn_Left has joined #osdev
tomith has quit [Ping timeout: 245 seconds]
Left_Turn has quit [Ping timeout: 245 seconds]
carbonfiber has joined #osdev
crankslider has joined #osdev
heat has joined #osdev
<heat> henlo
<heat> i have gym'd for today
crankslider has quit [Remote host closed the connection]
crankslider has joined #osdev
slidercrank has quit [Ping timeout: 245 seconds]
<bslsk05> ​'Walter White NPC' by The Civil Family (00:00:08)
<bl4ckb0ne> did you beat the gym leader and got the badge heat
<heat> no, cynthia wasn't there
<bl4ckb0ne> isnt cynthia the league champion
<heat> i dont fucking know im not a nerd
<linkdd> said the guy who hangs on #osdev and wrote an OS
<heat> boohoo
<heat> cry
<linkdd> :P
crankslider is now known as slidercrank
<heat> i think its hilarious u kids talking shit about heat. u wouldnt say this shit to him IRL, hes jacked. not only that but he wears the freshest clothes, eats at the chillest restaurants and hangs out with the hottest dudes. yall are pathetic lol
<bl4ckb0ne> but he lack basic pokemon knowledge smh
<mjg> people would hit on you
<mjg> talking shit on the interwebz is equivalent of teenage boys stealing stuff from girls to get their attention
<heat> people would hit on me?😳
<sortie> heat, cus I see sparks fly whenever you smile
<heat> oh my
<linkdd> there are jacked nerds
<linkdd> look at henry cavill
<heat> you get hit on by international mega popstars, now you hit on me
<heat> this means dua lipa hit on me indirectly, huge win
<heat> OPTIMAL wins
<sortie> heat, the latest craze is Tove Lo forever running into my arms https://sortie.sortix.org/for/offtopia/toveloroskildehug.mp4
<bslsk05> ​'Henry Cavill Being A Nerd for 6 Minutes Straight' by LaughPlanet (00:06:35)
<heat> sortie omg you're living the life
<heat> AHHHHHHHHHHHHH is indeed the appropriate reaction
<mjg> cavill is a chad
<sortie> Tove Lo running into my arms, again. Must be Thursday
<mjg> how old are you sorts
<sortie> The glamorous osdev life of kernels and popstars
<sortie> mjg, 31
<bslsk05> ​i.redd.it: Reddit - Dive into anything
<heat> i do not want to capture frekin flamegraphs
<heat> i want to capture womans
<mjg> fwiw you captured my heart
<mjg> you are like an adoptive nephew i did not ask for, but who i can live with
<sortie> heat, but what I really needed was for Rosaliá to take one look at me, throw water in my face, and ask what's up https://sortie.sortix.org/for/offtopia/rosaliawater.mp4
<linkdd> if you catch pokemons with pokeballs, do you catch women with woballs?
<heat> obviously you capture them with DEEZNUTS
<heat> ... is this why i dont capture womans
<sortie> For the record, capturing women is a crime
<linkdd> sortie: and capturing wild animals to make them fight for money is not?
<heat> is capturing men also a crime?
<heat> i dont think so but, you know, good to check
<sortie> linkdd, no, heat, yes. This is not hard
<heat> my plan A was to capture woman, my plan B was to get captured by woman
<heat> now both have gone to shit. i don't have a plan C
<linkdd> heat: plan C, capture yourself
<heat> plan C capture a flamegraph
<kof123> ^^^ quote: it thus appears that the rodent-salamander of the Chinese was, after all, a lizard like the salamander of the ancients. Ko Hung says the animal lives in hollow trees; it is the lizard who has acquired this habit.
<kof123> you need a hollow tree. was waiting for the right moment :D
[itchyjunk] has joined #osdev
smko has quit [Ping timeout: 250 seconds]
<heat> mjg: have non-linux systems attempted a SLUB-like thing or are they still stuck in slab?
smko has joined #osdev
ih8win8 has joined #osdev
duderonomy has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<gog> hi
lainon has joined #osdev
lainon has quit [Client Quit]
<mjg> no idea
smko has quit [Ping timeout: 245 seconds]
smko has joined #osdev
<heat> isn't that PESSIMAL
* gog pessimizies on the floor
<mjg> here is a pro tipp
<mjg> don't trust claims of greatnezz in any paper
<mjg> i feel i like give it out biweekly
xenos1984 has quit [Read error: Connection reset by peer]
<heat> im not trusting shit
<mjg> sure you do
<heat> but SLUB is known as better than SLAB, hence SLAB getting punted off in a few releases
<heat> benchmarks show it, memory usage is lower
<gog> i'm a slub
<heat> hi slub im gog
<gog> hi gog
<heat> meow
* mjg burps
<mjg> but is it OPTIMAL
<mjg> or is just an incremental improvement still below quality line
<heat> who sets the quality line?
<heat> quality line seems to be at SLUB at $(date)'s torvalds/linux.git
<heat> no one has anything better
vdamewood has quit [Read error: Connection reset by peer]
vdamewood has joined #osdev
* mjg burps again
<mjg> one could calculate what kind of memory usage would be close to optimal without compromising anything
<mjg> and check how far off slub is
<mjg> for starterz
<heat> but you always compromise though? :v
<heat> memory usage would be optimal if you did some sort of best-fit method
<heat> but that obviously sucks
<heat> or if you did away with slabs altogether
<bl4ckb0ne> you need a hyperball or better to capture a woman
<mjg> so how far off is slub and how far off is slab
<mjg> if someone does better than slub, are you going to claim it did suck after all?
<mjg> i don't know whether it sucks, i'm just not willing to praise squat
<heat> i would not claim it sucks, just as slab doesn't suck
<heat> if something better pops up, something better popped up
<heat> that's good, but it doesn't make the other thing UTTER SHIT
xenos1984 has joined #osdev
<mjg> no, but it does not make the better thing good either
<heat> good is relative
<mjg> see above
<heat> onyx is good compared to openbsd
<heat> but when compared to freebsd, it is still good
<gog> sophia is good compared to solaris
<mjg> dafaq's sophia
<heat> BUT when compared to windows, it sucks because winblowz is winfast
<gog> my kernel
<gog> based on SunOS 4.2
<mjg> the real sun operating system innit
<linkdd> my kernel is bad (and unfinished) but it's ok
<gog> the Kissing Girls And Having Good Performance branch
<mjg> heat: mofer, consider the following
<heat> I like the SunOS operating system
<mjg> say there is a workload where it is known that at least on paper it can scale linearly
<heat> more commonly known as the Sun Operating System Operating System
<mjg> now LolOS starts dragging after 8 cpus
<mjg> and GenxOS after 16
<mjg> is genxos better at this workload? yes
<mjg> isit good? NO
<gog> a kernel for every workload
<mjg> is it "good enough for the time being"? maybe
<heat> compared to lolos? it's poggers great
xvmt has quit [Remote host closed the connection]
<heat> if you do have prior art that shows there's a poggerer way to do things, that's something else
<mjg> now imagine genxos developer shows up and claims this is *the shit*
<mjg> SO GOOD
<heat> then your paper is good, genxos is slightly bad, lolos is garbage
xvmt has joined #osdev
<mjg> i would say it remains below quality line
<heat> the quality line is set gradually as you discover poggerer ways to do things
<mjg> it wins the competition for the tallest midget
<mjg> mofer
<heat> you realize there's literally nothing better than SLUB right?
<mjg> quality line is the best that can be done, even if nobody knows how to get there
<heat> not even a paper
<heat> no, that's not the quality line, that's the imaginary bullshit line
<mjg> i see you have great standards
<mjg> :d
<heat> you are literally asking for perfect things
<heat> gog ur literally perfect btw
<zid> I am more perfect
* mjg asks for gog
<mjg> rly?
<mjg> who is the perfecterest
<heat> zog
<heat> or gid
<heat> if i take a single letter from each of your names, i get mig
<heat> which is a really stupid fact
<heat> BUT it's also a russian aircraft manufacturer
<GeDaMo> perfection+1
<heat> mjg you can't work on anything physics related
<heat> "our car is good and can go 400km/h"
<heat> no, it's shit, why is it not going the speed of light you PESSIMAL idiots
JerryXiao has quit [Quit: Bye]
plarke has joined #osdev
thinkpol has quit [Remote host closed the connection]
JerryXiao has joined #osdev
thinkpol has joined #osdev
plarke has left #osdev [#osdev]
<gog> hi
<gog> i'm not perfect
<heat> OH you can also get zig, a really shit language
<heat> ppl who are perfect: gog, zid, zoe bee
<heat> this is the definitive list
<gog> zoe beee
<gog> she has a new video today i need to watch
<gog> she's wearing fish earrings :o
* gog eyeball fishy
dude12312414 has joined #osdev
<gog> heat heat
<gog> wil you get me the fishy earrings
<heat> no bcs u are already a captured womans and i only do nice getures to women for the off-chance of maybe maybe boning them
<gog> you're such a Nice Guy(tm)
<sham1> Stop capturing womans
<sham1> It's highly illegal
smko has quit [Ping timeout: 245 seconds]
<kof123> .................i agree with mjg but would just call it.......conway's law. this is like xyz people don't know good food, so they won't miss it perhaps
<kof123> and in reverse as well, never saw something truly bad
<sham1> Everything is some degree of mediocre
<kof123> sturgeon's law :D ^^^
<sham1> But that's that most things suck
<sham1> That's different
<heat> nicola sturgeon strikes again
<sham1> More like surgeon
<heat> nicola sturgeon? more like nikola tesla amiright lads
<gog> no
<sham1> Yee
<heat> nikola tesla? more like whosthatbumandwhydidhestealelonsname
<sham1> That's a pretty long name
<heat> i disagree, nikola tesla is a relatively terse name
<sham1> Nikola Tesla is also overrated and I'm tired of pretending that he's not
<gog> he was just a really weird dude
<sham1> In other news, we're in the second half of the year. Good times, winter is coming
<gog> we had a long lunch break at a local bar with a rooftop terrace
<gog> it's so fucken nice rn
<zid> no more eu4 for me heat, my new controller showed up early
<sham1> Just play eu4 with the controller. Ez
<gog> i'm thinking about fucking off and getting drunk for the rest of the work day
<sham1> Do kt
<sham1> Do it
<kof123> without making any economic/political/etc. statement i would also put Gresham's law (and wikipedia implies a reverse too IIRC)
<zid> what game did I wanna play I forget
<zid> oh right rocket league
<gog> hahaha
smko has joined #osdev
<gog> jejeje
<zid> ))))
<gog> :))))
<zid> man, rocket league is big now, 22GB
<zid> I swear it was like 6GB last time I installed it
gog has quit [Quit: Konversation terminated!]
<ih8win8> Darn, looks like qemu doesn't pause the USB frame incrementing while I'm stepping through gdb.
<ih8win8> So hard to debug when you can't pause everything.
<mjg> heat: is the SYSCTL CODE GOOD
<zid> debug qemu
<bslsk05> ​reviews.freebsd.org: ⚙ D40912 libthr: Patch to reduce latency to acquire+release a pthread mutex
<heat> no, the sysctl code sucks ass
<heat> kern_sysctl.c is the worst file in the history of files
<mjg> NOOO
<mjg> heat: it does the job
<mjg> so fuck off
<mjg> !!!
<heat> >while default/normal mutexes on that other OS
<heat> i did not know they were benchmarking against Onyx
<heat> good for them
<mjg> so i just checked sysctl on the widely used DARWIN kernel
<mjg> it is similar quality shite
<mjg> Lq
<mjg> but how can this be given how many ios phones are out there
<mjg> => not shite
<heat> have you considered that it's the same code
<mjg> it is not
<mjg> it is clearly based on it though
<heat> why is pthread_mutex_t a pointer?????
<heat> what the fuck?
<heat> for your beautiful FreeB$D system
<mjg> i have no idea
<heat> oh my god is it dynamically allocating locks?
<mjg> it is
<heat> oh fuck off
<mjg> why me
<heat> idk
<mjg> look mate, someone wrote this code
<heat> you are my local freebsd representative
<mjg> and enough time has passed that it is protected by IT WAS A GOOD IDEA AT THE TIME universal clause
<mjg> i mean if it was not, they would not do it
<mjg> therefore it was
<heat> anyway that is super pessimal, plus that patch looks kinda bogus honestly
<mjg> specifics of that implemlentation aside, everyone knows you can't use pthread locks if you want perofrmance
<heat> m_qidx makes your struct larger
<heat> for something that sounds trivial to figure out
<mjg> that code is the classic anti-performance bsd bloat
<mjg> i don't know how much of it is mandated by posix though
<heat> none of it
<heat> pthread_mutex_t on linux is literally just a struct
<heat> instead of addressing that, the patch adds a new field just to make pthread mutex larger, adds a new __always_inline, for a tiny microoptimization
<heat> stunning
<mjg> you can't address /that/ without fucking up ABI
<heat> doesn't fbsd allow ABI breaks?
<HeTo> between major versions yes unless they've changed it in the past few years
<HeTo> so, in -current, it should be allowed
<mjg> for the most part only on special occasion, and even then you need compat for the old state
<mjg> last break i remember is 64 bit ino numbers
<HeTo> well you can install compatibility versions of the C library AFAIK
<zid> heat come help me derustat rocket league
<zid> and see if my internet still sucks, actually
xenos1984 has quit [Ping timeout: 246 seconds]
<heat> whats ur rank?
<heat> or what was your rank
xenos1984 has joined #osdev
<sortie> heat: https://www.youtube.com/watch?v=r38y6JjeYCM&feature=sortie ← oh hey she just literally posted the entire video
<bslsk05> ​'Tove Lo - Talking Body (Live at Roskilde 2023)' by Tove Lo (00:06:27)
<GeDaMo> You're a Youtube feature? :|
<zid> heat: I was champ at my peak
slidercrank has quit [Quit: Why not ask me about Sevastopol's safety protocols?]
gog has joined #osdev
nur has joined #osdev
awita has quit [Ping timeout: 264 seconds]
zid has quit [Remote host closed the connection]
<dzwdz> could something like javascript's Promises work for asynchronous io in a kernel?
<dzwdz> or an os i guess
<dzwdz> i'm guessing something like that has been done before but idk how to research that
xenos1984 has quit [Ping timeout: 246 seconds]
smko has quit [Ping timeout: 264 seconds]
eddof13 has joined #osdev
xenos1984 has joined #osdev
<heat> yeah sure
<heat> why not?
<heat> you usually do something similar-ish manually anyway
<dzwdz> i've since been informed that javascript promises are more powerful than i thought
<dzwdz> the thing is i don't really have a clue what's the proper way to do things lol
<heat> a problem i see with plain promise shit is that it may not fit with many kernels
<dzwdz> i know select(2) but that's a pretty terrible api
<dzwdz> i'll clarify what i actually meant there
<dzwdz> i just meant that a syscall could return a Thing representing its future result
<heat> like if you have a promise on IO completion when is "IO" completed? what context? you can't really run a whole chain of promise shit in softirq or hardirq
<dzwdz> then you could get as many of those Things as you want and block until any one of them has its result ready
<dzwdz> without all the fancy promise chain stuff
<heat> if you want proper AIO stuff look at io_uring, it's *an* idea
<heat> returning arbitrary Things is a bad idea for a syscall barrier but i can see some interface where you pass a pointer to a result struct and then wait on that (with futexes or wahtever)
<dzwdz> said arbitary Thing would probably just be an int
<dzwdz> specifying the return value
<heat> you can't wait on an int
<dzwdz> i thought you meant what the thing would represent
<dzwdz> but i was also thinking that the Thing would just be some opaque unique identifier
<heat> why? make it an address the user registers
<dzwdz> that's a good idea
zid has joined #osdev
<dzwdz> but the thing being returned is also just an int
<dzwdz> so i don't really see the point in allocating a specific location for it
<dzwdz> then you run a syscall which accepts an array of Things and returns the Thing which returned and the returned value
<dzwdz> two ints
smko has joined #osdev
<bl4ckb0ne> what can cause filling up the cr3 register to stall/sigquit?
<zid> nothing
<zid> cpus don't have sigquit
<bl4ckb0ne> it sigquit on qemu
<zid> were you using qemu user not qemu system or something
<bl4ckb0ne> qemu-system-x86_64
<bl4ckb0ne> no triple fault, it just hangs there
FreeFull has joined #osdev
dude12312414 has quit [Quit: THE RAM IS TOO DAMN HIGH]
<ih8win8> Isn't a JavaScript promise just an async callback?
<heat> dzwdz you don't want to get into the kernel just to check what happened
<heat> best case you look at your memory location, worst case you use a futex wait on that location
<heat> vs allocating a new fd or some crap
heat has quit [Quit: Client closed]
heat has joined #osdev
<ih8win8> Is there really any advantage to having a dedicated async IO system call, when you can just spawn a new thread to call the IO function and have it call your callback when done?
<heat> yes
<heat> hardware is already naturally async, no need to spawn more threads
<heat> (which end up doing the hw async stuff anyway)
<ih8win8> So, threads just add more overhead?
* gog threads
<heat> i believe there's a use for them as sometimes(?) io_uring uses them
<gog> gog
<heat> gog
<gog> I Promise
<ih8win8> Ugh, I think qemu's dwc2 emulation might be incomplete. It never sends me an ACK packet for some reason.
<gog> ack
<gog> bl4ckb0ne: what do yu mean filling up the cr3
<gog> the only way to move to cr3 is register-to-register
<gog> unless you mean filling up the PML4 table
<gog> in which case there's a lot of things that could break that
<heat> i think they're loading cr3 and the pt is so fucked it's crashing
<gog> oopsie woopsie we made a fucky wucky
<bl4ckb0ne> probably yeah
<bl4ckb0ne> so i have ti fill a register to fill cr3? maybe thats why my movq fails
<heat> what
<heat> pls show code
<heat> mov $gog, %cr3 would never assemble
<bl4ckb0ne> https://git.sr.ht/~bl4ckb0ne/hboot/tree/master/item/src/mmu.c not up to date but L40 is the same
<bslsk05> ​git.sr.ht: ~bl4ckb0ne/hboot: src/mmu.c - sourcehut git
<zid> "r" is register
<zid> that will generate mov reg, pml4; mov cr3, reg
<zid> (didn't I write this?)
<gog> ok but we went over this before
<gog> &pml4 is going to be a virtual address
<zid> which may also be a linear address if he's identity mapped
<gog> #define IDENT_START0xFFFFFF8000000000
<zid> but if this page moves then he'll immediately hardcrash
<gog> yeah
<zid> bl4ckb0ne: what address does init_mmu have?
<bl4ckb0ne> gog: new code has pml4 from allocatepages, is it still going to be a virtual address?
<zid> bl4ckb0ne: what address does init_mmu have?
<heat> no
<heat> ur gonna have to say how its crashing
<bl4ckb0ne> dunno about that zid
<heat> doing a sigquit for that is very weird
<bl4ckb0ne> it doest, it just hangs there
<heat> what
<zid> I've seen sigquit if gdb isn't configured correctly
<bl4ckb0ne> i have a print pre and post cr3 fill and the post never shows
<heat> you said it fucking sigquit
<bl4ckb0ne> with gdb it sigquit
<zid> when it's trying to react to hw exceptions as signals
<heat> no shit
<zid> I don't remember how to get it to happen though
<heat> my man, use the qemu monitor
<heat> and the qemu log
<heat> -d int
<heat> -d mmu
<zid> I'd say he has clearly never looked at the objdump for any of his asm blocks, which is a bad sign
<zid> doesn't know the addresses involved, doesn't know that it generated a reg to cr3 mov, etc
<bl4ckb0ne> fuuug kid woke up
<bl4ckb0ne> never used any inline asm before, but i shouldve thought about objdump
tomaw has quit [Quit: Quitting]
eddof13 has quit [Ping timeout: 246 seconds]
slidercrank has joined #osdev
tomaw_ has joined #osdev
tomaw_ is now known as tomaw
wootehfoot has joined #osdev
wootehfoot has quit [Read error: Connection reset by peer]
lainon has joined #osdev
lainon has quit [Quit: Textual IRC Client: www.textualapp.com]
gareppa has quit [Quit: WeeChat 3.8]
<gog> hi
ih8win8_ has joined #osdev
<Ermine> hi gog, may I pet you
ih8win8 has quit [Ping timeout: 245 seconds]
<gog> yes
* Ermine pets gog
* gog prr
demindiro has joined #osdev
<Ermine> *Reading the news* China presented its own operating system, OpenKylin
<Ermine> > it is based on Linux
<Ermine> el_risitas.mp4
ih8win8_ has quit [Read error: Connection reset by peer]
ih8win8 has joined #osdev
<bl4ckb0ne> NK has the same with redstar os
ih8win8 has quit [Read error: Connection reset by peer]
ih8win8 has joined #osdev
GeDaMo has quit [Quit: That's it, you people have stood in my way long enough! I'm going to clown college!]
zxrom_ has joined #osdev
<zid> russia had the same with a famous fake a while back
<zid> that I forget the name of
ih8win8 has quit [Read error: Connection reset by peer]
zxrom has quit [Ping timeout: 245 seconds]
demindiro has quit [Quit: Client closed]
gildasio has quit [Ping timeout: 240 seconds]
<Ermine> You mean BolgenOS? That was a silly young boy
sinvet has joined #osdev
<Ermine> Anyway, if one wants to make a production-ready general-purpose OS, it will either be Linux or one has a couple of trillions of dollars and is ready to wait for several years
<heat> open killin is a sick name for an os
<heat> and considering it's china, makes sense too
<Ermine> And if this new OS is Linux, don't make a mountain out of a molehill
<Ermine> And they're assholes if they didn't upstream their changes
<heat> should've been openbsd
<heat> if that happened i would be 100% convinced that the CIA was involved in that decision
<heat> spying so strong they can make foreign governments vulnerable to all types of shit
<heat> multi-threaded weapons research projects would grind to a halt
* kof123 .oO( imagines a chatroom far away "this weapon is PESSIMAL" )
<sham1> PESSIMAL
<heat> linox kern
danilogondolfo has quit [Quit: Leaving]
smko has quit [Quit: Lost terminal]
<heat> geist: fuchsia can build itself now?
<geist> no
<heat> or is that thing in the discord bogus?
<heat> oh
<heat> ok
<heat> i... don't really know what that guy's doing then
<sortie> geist, don't worry, it takes a while for hobby operating systems to get self-hosting :)
<geist> yeah i dunno what he's up to either
<geist> i would so love for it to self host, but it's a non goal
<mjg> so you are on discord after all?
<heat> self-hosting is soooo 2015, osdev success is measured in tove-lo-hugs
<geist> which discord are you talking about?
<sortie> fuchsia is a fun toy for idk showing pictures of loved ones
<mjg> what's the problem with self hosting fuchsia? any missing kernel features?
<geist> no will of the organization to do it
<mjg> or just nobody massaged the buidl system
<sortie> Knowing the big G, the build system is Linux dependent as hell
<sham1> If it builds with bazel then that'd explain it
<geist> exactly
<mjg> i assumed discord osdev, but i guess it is fuchsia? :]
<sortie> I imagine lots and lots and lots of prebuilt binaries
<geist> sortie: 100%
<heat> isn't the problem that some people want a component server thing that is a completely different paradigm from traditional building?
<geist> initially it was a goal, but over time the amount of prebuilts has grown so that it's hard enough to maintain a linux and mac build
<geist> that as well
<geist> then it not being posixy at all, adds another layer of hard
<heat> mjg: yeah fuchsia discord
<sortie> The big G really has a prebuilt problem
<zid> w10 makes cheating at EU4 much more difficult
<geist> sortie: yep. drives me nuts, but what can i do
<geist> like to build fuchsia it literally downloads like 5 or 10GB of prebuilts
<sham1> zid: stop cheating
<geist> and if you wait a week it'll download a whole new set
<sortie> geist, if only there was some sort of place where one can do real osdev off hours
<geist> because everything is constantly rebuilt, because it is The Way
<sortie> Only slightly better in Dart land
<sortie> We got lots of prebuilts too, especially the toolchain
<mjg> :]]
<geist> tha being said we're generally moving away from go and dart in the build (which was one of the major prebuilts thats a huge problem)
<sortie> But one can kinda bypass it with a bunch of hail mary's
<geist> so now it's almost entirely C++ and rust
<mjg> oooofff
<mjg> RUST MOTHERF^w^w
<sham1> Wait, you're building with C++ and Rust?
<geist> well, rust toolchain is at least easy to build
<sortie> At least I'm doing a little bit of work to make Dart better and more portable and less infected with the weird G isms
<sortie> You know, like a real open source project
<heat> mjg you'd do great in the fuchsia discord speedrunning scene
<mjg> what
<heat> you'd get the fuchsia ban% WR
<heat> ez
<mjg> do they like solaris?
<geist> sham1: in a fashion, since a lot of the tools that are built as part of the build are also part of the source
<mjg> otherwise i have hard time
<heat> they love rust
<sortie> The biggest reason why this stuff isn't packaged by distros is probably just how absolutely poorly it integrates and does its own dependency providing
<mjg> :]
<geist> but mostly what i means i most of the source is C++ and rust now
<geist> generally phasing out go and dart
<sortie> Plus the darn dart bootstrap
<mjg> heat: they are banned by me then
<sortie> They went and wrote Dart in Dart, the maniacs
<sham1> That's usually what happens with there more system-ey languages
<sortie> And made it a helluvalot faster too
<heat> sortie: hey at least the chromium //build stuff best-effort supports the host compiler!
<sortie> Don't get me started on chrome stuff
<mjg> have you tried chrome on a bsd
<mjg> :d
<geist> the prebuilt tools are for the right reason. the fuchsia build is totally hermetic and reproducible
<heat> you are using its build files right?
<mjg> diffs are glorious
<sortie> At least I have gotten to the point where I bend Chrome's tools to my will
<sham1> You'd want to make sure that there is another implementation of the language in another language, but... eh, it's more fun to hack on the target language and you can get forked evolution between the implementations
<mjg> this makes me wonder
<mjg> is there a worry that G will get to a point where it in fact *can't* build
<heat> can't build what
<sham1> Anything
<geist> oh no not at all
<heat> what
<geist> you wouldn't believe the machinery in place to ensure all of that
<geist> that's part of the 'if you cant do it 1000000 percent dont do it' that you get at google
<geist> ie, building a thing is easy, building a thing in a constantly reproducible thing that can scale to 1000 builders simultaneously and run a constant barrage is unit tests is the minimum bar
<sham1> I would imagine that the build servers are cared for religiously. Y'know, the ones that can somehow build Chromium in like 20 minutes as opposed to times measured in *days*
<geist> for better or worse
<heat> chromium is not that bad
<heat> my shitty laptop did like 2 hours
<sham1> My shitty desktop probably did it while being older than your laptop back then
<heat> ofc if you enable LTO you're in hell
<sham1> But that's what I get for using Gentoo with an old i7
<sham1> Years ago
<heat> you know, the cloudflare project i worked on last summer (that depended on v8) actually used v8's toolchain directly
slidercrank has quit [Ping timeout: 245 seconds]
<heat> bcuz if you tried using other compilers they would sometimes crash
<heat> who wants cold mcdonalds?
<heat> it has been sitting here in my desk for the last 2-3 hours
<sham1> You eat it. It's yours
<mjg> mcdonalds?
<heat> i can't tell if this shit is worse cold or microwaved
<mjg> mcdonalds is shit as is mate
<mjg> seriously, it's not even tasty
<heat> well, it is what it is
<zid> yea mcdonalds does not seem like the kind of food you want either
<mjg> liek if you gonna eat poor quality food, at least get something tasy?
<heat> if i don't eat, i die
<zid> I wish I could not eat
<heat> it wasn't my first choice either mate
<mjg> is mcdonalds the only option?
<zid> I'd have basically no expenses
<mjg> mom's basement is free innit
<heat> my mom actually went out so she bought me some cheapo 1 euro burger and fries for dinner, i then had a nice nap, woke up some 30 minutes ago, this shit is cold af
<heat> life's good
<mjg> you took a nap close to actual bed time? :X
<mjg> you pulling off an allnighter?
<heat> since when is 19:00/20:00 close to actual bed time
<heat> is this a BOOMER moment
<mjg> brah
xenos1984 has quit [Read error: Connection reset by peer]
<mjg> when do you go to sleep
<heat> idk 1am earliest probably, but heavily depends
<sham1> If you go to sleep at like 1 in the morning, that's still too cllse
<sham1> Close
<sham1> I would know, that's also when I go to sleep
<mjg> i recommend fixing your klock
<sham1> In fact, it's almost 1 AM right now over here
<mjg> going to sleep when you feel like going to sleep is great when you are in your 20s
<mjg> i mean feels great, but it is in fact terrible
<mjg> says a guy who could never get to work before 11 am
<mjg> :S
<sham1> I dunno, going to sleep at a predetermined time sounds pessimal
<heat> mjg https://jackli.gg/chessle/ chess me u bastard
<bslsk05> ​jackli.gg: Chessle
<mjg> lol @ chess
<heat> chess is OPTIMAL, checkers is PESSIMAL
<mjg> chess shite game
<sham1> You did not just say that
<heat> he's correct though
<mjg> i bet they have chess on solaris
duderonomy has joined #osdev
<mjg> checkers is the php of games
<mjg> or is it tic tac toe
<mjg> all that mcdonald debacle made me want to eat a burger
<sham1> Noughts and crosses is a solved game. PHP isn't solved
<sham1> I don't even know what it truly is
<mjg> php being shite is a solved problem
<heat> someone: *coughs* gm: oh yes i remember a game in 1945 between petrosian and rommel where petrosian shidded and farded himself, rommel coughed and played the brilliant Ke3!! which gave petrosian forced mate
<heat> i imagine you look at code in a similar way. new pessimal code reminds you of old pessimal code
<mjg> says the guy with sysctl flashbacks
<heat> kern_sysctl.c is the worst file ever
<mjg> no no heat
<mjg> this is tried and tested code
<heat> GTA V Free Cracked 2023 WORKING.exe is somehow better than kern_sysctl.c
<mjg> autoexec.bat
<mjg> winfile source code is way worse than kern_sysctl mate
<mjg> written by people who loathe anything c-related it seems
<bslsk05> ​'DUPLEX Cracktro - GTAV PS3' by Tércio de Paula (00:01:32)
<mjg> gnight
<bnchs> goodnight mjg
<heat> mjg first thing i saw in the source code is the register keyword
<heat> seems like proper C code alright
<mjg> i would paste some sample
<mjg> sb
<mjg> but i have to go
<mjg> nice bait tho
<sham1> Don't insult my boy register
<heat> do you want to look at lookuppn?
<heat> it's a good routine
<mjg> aha
<mjg> &
xenos1984 has joined #osdev
<bslsk05> ​github.com: unix-history-repo/usr/src/sys/sys/nami.c at BSD-4-Snapshot-Development · dspinellis/unix-history-repo · GitHub
<heat> nami mate
<heat> namei was too descriptive
<sham1> umount
<zid> heeat I wanna attack lithuania..
<heat> yeah ok that seems reasonable
<heat> are they too stronk
<zid> I think I will win.. maybe..
<heat> i was lucky PLC didn't form in my game, but poland was both my ally and their ally
<sham1> Who are you playing as zid
<heat> he's playing muscovy
<sham1> Ew
<heat> cuz he can't have original ideas
<zid> I wanted to show heat what a guy who hasn't played for 2 years is capable of
<heat> you tried that in rocket league and i witnessed the least mobile rocket league player i've ever seen
<zid> I got it fixed and you switched to csgo anyway lol
<zid> I cannot kill lithuania, he allied hungary :(
<heat> get austria
<zid> ruskie's diplomacy situation is shit, nobody is close enough or the same religion enough to be friends
<zid> except for like.. livonian order who does nothing ever
<heat> polan and austria worked well for me
<heat> then eventually you can ally stronger peeps
<zid> There is no poland anymore, just GIANTHUNGARY
<heat> what?
<heat> is that new?
<zid> pardon
<zid> giant hungary is kinda new in that hungary almost always just fucks it all up
<heat> is that a new event or something?
<zid> but it was always technically possible
heat has quit [Quit: Client closed]
heat has joined #osdev
nyah has quit [Quit: leaving]
carbonfiber has quit [Quit: Connection closed for inactivity]
vdamewood has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<mcrod> hi
<heat> hi mcrod
<mcrod> hi heat
<mcrod> how are you today heat
<heat> im fine
<heat> still kinda sick but fine
<mcrod> i must ask
<heat> have you read proposals for enhancement of UNIX on the VAX?
<mcrod> are you able to do time travel
<mcrod> nope
<heat> do it
<mcrod> the question is will my brain be fried once I do
<heat> no
<heat> you can read about their original older ideas on UNIX IPC and sockets
<mcrod> ok that's pretty neat actually
<mcrod> ok i wil read
<mcrod> *will
<mcrod> but first, my roast duck
arminweigl has quit [Quit: ZNC - https://znc.in]
arminweigl has joined #osdev
<heat> lots of what they talk about in that pdf went on to become actually part of UNIX
<heat> like mmap!
<heat> but in this case they call it segalloc
<heat> also damn ioctls but everything is plain text that's tough man
<zid> dang, 360ce is way better now
<zid> it can just create a virtual xinput device
<zid> no need to fuck around copying fake copies of xinput1_3 / 1_4 / 32bit / 64bit around anymore
heat has quit [Quit: Client closed]
heat has joined #osdev
<heat> i kind of want to write a 4BSD clone now
<heat> this is small enough to be feasible
<heat> like literally a clone, shit naming and everything
lanodan has quit [Ping timeout: 260 seconds]
lanodan has joined #osdev
Turn_Left has quit [Read error: Connection reset by peer]
<mcrod> hm
<mcrod> i want to buy an rpi and do OS development on it
<heat> do it
<zid> eww
<heat> wanna do a UNIX-off?
<mcrod> i'd lose
<heat> you'd be surprised
<mcrod> the reality is I'm not smart enough to do full fledged OS development
<heat> what
<mcrod> the fuck you mean what
<heat> bad take
<heat> cold take
<mcrod> explain
<zid> me too
<heat> why are you not smart enough?
<zid> I mean, me neither
<mcrod> listen
<heat> you've shown the brainz for stuffz
<mcrod> I can barely write a shell script without questioning every single thing I do about it
<heat> is that you being bad or you being inquisitive?
<mcrod> I am a very particular person
<mcrod> eh I suppose the latter
<heat> how would that signify dumbness too? at most it would mean you lack knowledge, not intelligence
<heat> and we all lack knowledge before doing things
<zid> heat should coach me through making a unix
gog has quit [Quit: byee]