<clever>
the auto-update mechanism 404'd, and the updater was as dumb as bricks, it saved the 404 html to a .exe and ran it
<clever>
windows couldnt find a PE32 header, so obviously its a .com binary
<clever>
throw the html into the dos compatability engine and run it!
<zid>
The EVE online updater was better
<clever>
by pure chance, it printed characters to the LPT IO port
<clever>
windows then forwarded those to the printer
heat has quit [Ping timeout: 246 seconds]
<clever>
and the printer also lacked any validation, and physically damaged itself due to invalid commands!
<zid>
they had a file named boot.ini in their install, someone forgot a / and they deleted everybody's C:/boot.ini
<clever>
*facepalm*
<clever>
i once helped a noob get into safemode, by using VNC to help them edit boot.ini, and make it always wait 30 seconds before booting
<clever>
so he had time to F8 and select safe
<zid>
You could just hold ctrl, btw
<clever>
he did whatever he wanted and was happy, and i went to bed
<clever>
he then wanted the 30 second delay gone
<clever>
he deleted boot.ini
<clever>
he didnt have a recovery disk
<clever>
he bought a new copy of windows
<clever>
he didnt hit repair, he formatted the whole system, lol
<zid>
I used my w95 install disc sooo many times
<zid>
to boot into dos and fix shit
<clever>
he then ran all over irc, claiming VNC is a virus, and that i broke his computer, lol
<zid>
since w7 if windows breaks it's just fucking dead, cus now nobody knows how it works without a degree :p
ptrc has quit [Remote host closed the connection]
ptrc has joined #osdev
Gooberpatrol66 has joined #osdev
vdamewood has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
[itchyjunk] has quit [Read error: Connection reset by peer]
slidercrank has joined #osdev
Terlisimo has quit [Quit: Connection reset by beer]
Vercas has quit [Remote host closed the connection]
Vercas has joined #osdev
Terlisimo has joined #osdev
Yoofie has joined #osdev
zxrom__ has joined #osdev
zxrom_ has quit [Ping timeout: 245 seconds]
<kazinsal>
zid: good ol' CCP, even now they're constantly finding new and amazing ways to break things in EVE
<kazinsal>
recently my alliance bullied their art director into changing their draconian and nebulous alliance logo rules
<kazinsal>
because they considered a cartoony mission patch of a fat goose with pride flag starstreaks in the background to be too unrealistic
<kazinsal>
even when we sent them real mission patches that were cartoony as hell and pointed out a dozen different existing alliance logos that were cartoony
zxrom__ is now known as zxrom
<kazinsal>
after a month of blowing up GMs in game and honking at them in local chat they finally gave up and changed the rules and approved gootse
<zid>
hahaha
<zid>
gootse
<zid>
idk if vulture plays eve, but he should join your alliance
<kazinsal>
the main corp, Goosefleet, is a bunch of old goonfleet vets
<kazinsal>
our greater alliance is Gooseflock Featheration <GEESE>
<kazinsal>
we're on good terms with Goonswarm and its coalition so it's always fun to have old goons in GEESE and new goons in GEWNS honking back and forth at each other
<zid>
I haven't played eve in forever, and I was a total pve player
<zid>
I lived in null for a while but I barely did anything there, and was in safe space, etc
<zid>
got annoyed that every time I undocked anything worth killing, I'd get warped onto by a titan
<kazinsal>
yeah I'm uh, I'm someone who's been in many many wars
<kazinsal>
and many twelve hour tidi fights
<zid>
someone must do it :P
<zid>
It has lots of pilots, probably on average, most people do that stuff
<kazinsal>
it was a lot worse when tidi was new and fresh
<kazinsal>
because you'd often have the servers dropping some of your command packets
<kazinsal>
so you'd have to spam the reload command 30 times to make sure your guns actually reloaded
<zid>
I miss doing L4s in my sleipnir
<kazinsal>
because 29 of those packets would get dropped
<zid>
but I cbf to play enough to get enough ISK for the sub
<kazinsal>
I have two accounts subbed right now and three more in alpha status
<kazinsal>
the alphas are all out-of-alliance alts for spy shit and market fuckery
<kazinsal>
and one saxfleet char
<zid>
can't fly anything interesting without a sub, I logged in at least since they added that
<kazinsal>
we do some wormhole stuff as well
<zid>
yea I lived in a WH for a bit
<kazinsal>
wonder if it's possible to suck down enough wormhole gas casually to pay for a sub without spending like, 20 hours a month on it
<zid>
mainly because I was making T2 missiles in it
<zid>
scourge fury
GeDaMo has joined #osdev
tomith has joined #osdev
gareppa has joined #osdev
jjuran has quit [Ping timeout: 246 seconds]
jjuran has joined #osdev
vdamewood has joined #osdev
<bradd>
(uefi) should I be making my own page tables before loading my gdt? (i want to virtually map the gdt to a fixed virt address)
<zid>
would help you know where it is
Vercas has quit [Remote host closed the connection]
Vercas has joined #osdev
hmmmm has quit [Quit: Leaving]
hmmmm has joined #osdev
hmmmm has quit [Client Quit]
hmmmm has joined #osdev
wootehfoot has joined #osdev
<mjg>
nerds
<sham1>
We're all nerds here
foya has joined #osdev
foya has left #osdev [#osdev]
<kazinsal>
all drinking our tea as per ISO 3103
<sham1>
Ew no, it calls for milk in the tea
<kazinsal>
no no
<kazinsal>
it has milk as optional and has specific instructions for milked tea
<kazinsal>
though even without milk as per the instructions you get a pretty meh cup of tea
goliath has joined #osdev
Vercas has quit [Remote host closed the connection]
Vercas has joined #osdev
Left_Turn has joined #osdev
vdamewood has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
gog has joined #osdev
Vercas has quit [Remote host closed the connection]
Vercas has joined #osdev
<mjg>
ey heat
<mjg>
> • Acquiring and releasing uncontested mutexes should be as fast as possible.
<mjg>
from d&i of the system writing by distinguished scholars
<mjg>
except if you take a look at the code, it is not
<mjg>
they also neglected to mention how locks are 32 bytes in size(!!!) because geezer
slidercrank has quit [Ping timeout: 246 seconds]
dennis95 has joined #osdev
<moon-child>
glibc locks are even bigger than that iirc
foudfou_ has joined #osdev
foudfou has quit [Ping timeout: 240 seconds]
foudfou has joined #osdev
foudfou_ has quit [Ping timeout: 240 seconds]
MiningMarsh has joined #osdev
[itchyjunk] has joined #osdev
vdamewood has joined #osdev
Turn_Left has joined #osdev
Left_Turn has quit [Ping timeout: 245 seconds]
Left_Turn has joined #osdev
Turn_Left has quit [Ping timeout: 260 seconds]
Turn_Left has joined #osdev
<gog>
hi
Left_Turn has quit [Ping timeout: 240 seconds]
foudfou has quit [Remote host closed the connection]
gog has quit [Quit: byee]
vdamewood has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Left_Turn has joined #osdev
<sham1>
hi
heat has joined #osdev
<heat>
HELLO
<heat>
mjg have you noticed how 4BSD is kind of a decent didactic thing
Turn_Left has quit [Ping timeout: 240 seconds]
<heat>
it's still simple enough to be easily graspable, plus it has things like *comments*
<mjg>
lmao
<mjg>
biatch
<mjg>
i did not spend much time on 4bsd sources, apart from some vfs
<mjg>
all that code is stupid
<mjg>
and someone new may easily think it is not when it makes claims about reality
<sortie>
I feel I've moved well past the books at this osdev level :)
vai has joined #osdev
<mjg>
"modern" is such a bad choice
<sortie>
Well it made sense at the time lol
<mjg>
just like "ng" and "next"
<sortie>
WNT
<mjg>
i;m mostly curious what bullshit it spews
<mjg>
and if it is self-aggrandazing
<sortie>
Honestly it was fairly fine and neutral, explained a bunch of Unix and Windows stuff too
<mjg>
most of OS material i had seen so far is basically... PESSIMAL
<sortie>
Mostly suffered a bit from being old and spending some time on weird things like M:N threading
<mjg>
basically stupid ideas sold as fixes to a problem
<sortie>
Granted, it sure took everyone a long time, especially in the Unix world, to just do 1:1 threading
<mjg>
i blame solaris on that one
<sortie>
My favorite part of osdev is that when I need stuff, I just *invent it*
<sortie>
Like you know, go look at what existing systems do, is there anything I can adopt? Any RFCs? No? I'll just come up with something. For extra credit, add in some really good technical qualities and design
<mjg>
> The new PID must be unique among all processes. Early versions of BSD verified the uniqueness of a PID by performing a linear search of the process table. This search became infeasible on large systems with many processes.
<sortie>
Sortix is a fun mix of implementing existing designs very well, coming up with some really cool good novel designs, and a whole bunch of super pragmatic 'good enough' custom solutions that nobody else will want
<mjg>
fair, orig code stupid
<mjg>
so what's the fix
<sortie>
typedef int64_t pid_t;
<sortie>
pid = next_pid++;
<mjg>
FreeBSD maintains a range of unallocated PIDs between lastpid and pidchecked. It allocates a new PID by incrementing and then using the value of lastpid. When the newly selected PID reaches pidchecked, the system calculates a new range of nused PIDs by making a single scan of all existing processes
<bslsk05>
github.com: unix-history-repo/usr/src/sys/sys/vmpage.c at BSD-4-Snapshot-Development · dspinellis/unix-history-repo · GitHub
<sortie>
9223372036854775807 pids are enough for everyone
<heat>
4bsd is not great but not garbage
<mjg>
dude i literally linked you the namecache
<mjg>
did not it?
<heat>
and maybe that's the sweetspot
<mjg>
v_id or whatever the name?
<mjg>
:]
<heat>
i did, it may suck, what now
<heat>
i said didactic thing
<mjg>
ok mr didact
<mjg>
what do you think about the pid fix above
<heat>
you can't teach shit with a 5kloc slab.c file
<sortie>
These old systems are cute because they worked with crazy resource limitations, lots of inexperience, and they did cook up something that more or less worked with some reasonableish level of quality
<mjg>
here is an insider secret sortie
<sortie>
Today it's pretty obvious and easy how to do better designs and implementations
<mjg>
people have no idea what constitutes fast or slow execution
<heat>
mate, this is literally 1980
<heat>
nobody gives much of a shit about fast
<mjg>
as long as the system does not crash and the shell appears responsible, any time is seen as costo f doing business
<sortie>
heat, rather they cared a lot about 'not slow'
<mjg>
heat: except they claimed otherwise
<sortie>
Plus 'kinda working' is way better than 'no computer'
<heat>
you realize the paper i linked literally talks about GIGABYTE like we talk about PiB
<mjg>
i'm saying that code was blatantly slow on that hw
<mjg>
but profiling was mostly an alien concept and see above about perception
<heat>
literally 1980 mate
<sortie>
HahaI don't think any of us disagrees
<mjg>
so when they claim they fixed this or that problem with perf, like that pid stuff, it is probably stupid
<heat>
12 years before that black ppl in the US did not really have rights
<mjg>
so i don't htink any of this is particularly educational
<mjg>
well not any, but it can't be taken seriously be default
<mjg>
by
<heat>
ok, so why do you think literally 2 people here in #osdev care about perf?
<sortie>
Yeah I mean, you wanna learn how to do things right, don't look at 1980's sources.
<sortie>
If you wanna learn something historical, yeah do go look
<mjg>
's part of what i'm saying
<mjg>
right
<mjg>
but apparently heat disagrees
<heat>
doing things right is too expensive
<mjg>
how bout doing them in a sensible manner
<mjg>
not even OPTIMAL
<heat>
no fucking way you're taking bsc OS course students through fucking linux
<sortie>
Depends on who's paying
<mjg>
i would not take them through fucking linux
<sortie>
Honestly my attitude is that doing things right is overall cheaper
<mjg>
careful sorts
<mjg>
not very corporate of you
<mjg>
:]
<heat>
even onyx is bullshitly hard for ppl who are not "experts"
<sortie>
It all depends on how much investment you want to do before you get returns
<mjg>
here is a SHOCKER for you heat: most people should noteven be looking into os internals
<mjg>
it is a niche for fetishists
<heat>
i disagree
<sortie>
I often do things the quick way instead of the right way if it's needed now, but I am mindful of it
<mjg>
besides your typical college graduate can't even strace
<mjg>
so
SGautam has joined #osdev
<heat>
seeing internals is useful to get a grasp of what's going on
<heat>
versus handwavy statements in a handwavy OS course
<mjg>
but they don't have any
<heat>
they could, if they were given a simple implementation of the basic shit
jjuran has quit [Ping timeout: 246 seconds]
<mjg>
no because they don't want to learn either
<heat>
well, that's their problem
<sortie>
Honestly we need diversity in knowledge as a species. Lots of people don't need to know the underlying stuff. It helps. It's an investment tho. You can't know it all. Pick and choose. Let's all know different stuff.
<heat>
prof. heat will fail them
<mjg>
here is an example heat
<mjg>
people think if there is a zombie process on linux
<mjg>
you can get rid of it with kill -9
<mjg>
on itself
<heat>
well, they're wrong and didn't read on zombie processes
<mjg>
but they graduated
<heat>
ok
<heat>
what now?
<clever>
from what ive seen, a zombie process is already dead, you cant kill it
<clever>
the only way to get rid of it, is for the parent process to waitpid() it
<mjg>
what now is one can concede majority of people who go into "CS" don't care
<heat>
ok, fuck em
<mjg>
let alone about a basement dweller niche like OS internals
<heat>
<heat> well, that's their problem
jjuran has joined #osdev
<mjg>
so you can try to damage control by drilling down on total basics, like using strace
<mjg>
no mate, it is everyone else's problem
<heat>
so you lower your course's quality because some idiots don't care?
<mjg>
when joe "lmao" random writes absolute horseshit and kills production, it wont be him fixing it
<mjg>
the idiots are going to be produced anyway, but maybe they can be neutered
<heat>
but joe there will get fired because he sucks
<mjg>
's what i'm saying
<mjg>
no, that's not how corporations work
<mjg>
if it was true, vast majority of "programmers" would not have jobs
<sortie>
It's pretty obvious the way to build the system is to handle the many newcomers and teach them what they need as they need it, share knowledge
<sortie>
That's the job of a senior engineer, to help the juniors learn additional skills and grow them
<mjg>
my anecdata says "lol @ that" sortie
<mjg>
when i was a young lad attending college, there was 180 of us the first year
<sortie>
If you're a 'senior' just cleaning up after junior mistakes, you're fucking up, you need to be investing in people with org support
<mjg>
i started asking around, found 5 people who knew anything
<mjg>
even one of the lecturers on second semester said that there is maybe 3 people here who know anything :d
<mjg>
i htink you got spoiled at G sorts
zhiayang has joined #osdev
<mjg>
the juniors actively don't give a shit
<mjg>
and have a typical career plan to jump to management
<mjg>
between copy pasting from SO (now chatgpt) or putting in effort, they chose the former
<mjg>
whatever which keeps them afloat
<sortie>
Spoiled or, you know, actually a thriving profitable business that does good work
<mjg>
there is too much demand for programmers vs what is on the market
<sortie>
Actually that's been false lately, hence layoffs
<mjg>
it was definitley not false last 3 decades
gog has joined #osdev
<mjg>
i know a guy teaching programming at some lol community college
<sortie>
But yes, the sudden explosion in demand did bring a lot of too inexperienced people in without the community ability to train them, def happened during .com
<mjg>
to my 0 level of surprise people copy paste code from the rest
<mjg>
and it does not even work
<mjg>
:d
<sortie>
Anyway my point is that, totally lots of inexperienced people and newcomers and lazy people with different goals than idk perfection. It's our job as a community to share our skills and knowledge
<sortie>
It's why we contribute to the osdev wiki and so on
<sortie>
It's why we talk in here to share what we learn and build
<mjg>
i'm saying majority, smart or stupid, does not care
<mjg>
they want to do the bare minimum to appease management
<sortie>
And so what?
<mjg>
which is not teh same as doing quality work by any standard
ThinkT510 has quit [Quit: WeeChat 4.0.0]
<sortie>
Most apps or whatever can be shit
<mjg>
it means ideals of t eaching can be showed up one's butt
<mjg>
when it comes to general programming population
<mjg>
the best one can do imo is give them code samples to copy paste which don't blow up
<mjg>
so nothing quadratic etc.
<sortie>
I don't really wanna spend time feeling superior to people that haven't had training in what I know and are trying to do something else in their life with different goals
ThinkT510 has joined #osdev
<mjg>
mate
<mjg>
i take it you have not spend too much time trying to keep the ship afloat
<sortie>
Just don't put them in charge of anything important
<mjg>
in face of what feels like intentional sabotage
<sortie>
Sounds like an org that has severely underinvested
<mjg>
is G your first and only job?
<sortie>
Yes
<mjg>
figure
<mjg>
s
<sortie>
And I have learned a lot about what makes an org successful and what does not
bnchs is now known as Cindy
<mjg>
then you musth ave missed the part how majority is not
<mjg>
:]
zhiayang has quit [Quit: oof.]
<mjg>
despite staying alive
<sortie>
wtf? I keep acknowledging that things are different for the majority and that's fine enough
<bslsk05>
'Legendary Quake Record Finally Beaten After 22 Years' by Karl Jobst (00:15:41)
foudfou has joined #osdev
<heat>
were there any big names behind svr4?
<mjg>
no idea
<heat>
i know sunos had bill joy, bonwick, eventually cantrill
<heat>
but i can't remember of a single SVR4
<heat>
one
<heat>
maybe ken, etc were still involved
dennis95 has quit [Quit: Leaving]
benlyn has quit [Remote host closed the connection]
<mcrod>
hi
<heat>
i guess if you go through the bell labs people you get a lot of people that may have been involved in system V in general, even if maybe not SVR4
<heat>
mcrod are you ready to contribute to HSD?
wootehfoot has quit [Quit: Leaving]
<mcrod>
wtf is hsd
<heat>
the Heat Software Distribution Needs Your Help!
<heat>
Help The War Effort Against the Germ- err Californians!
<linkdd>
the kernel won't support it anymore, so why would the compiler still do?
<sortie>
gcc and bintuils are used many places
<mjg>
so much for compatibility!
<sortie>
bintuils has libbfd which abstracts all of this, so it's not a big fucking deal (pun intended)
<heat>
i dont give a shit about linux, im a dragonflybsd user
<linkdd>
sortie: yes, but where is a.out still relevant?
<sortie>
It's not
<heat>
in ~/hsd
<sortie>
Honestly it's fine that it's in libbfd since people use it for lots of special cases, you know, like making flat binaries and other special osdev purposes
<sortie>
But yeah get it out of the kernel
<mjg>
for real
<mjg>
even windows shed support for 16-bit binaries
<mjg>
which is liek a.out equivalent
<mjg>
in relevancy
<heat>
a.out supports 32-bit
<mjg>
i know
<mjg>
a.out is just before my time
<mjg>
or i think?
JerryXiao has quit [Quit: Bye]
JerryXiao has joined #osdev
<mjg>
i defo did not have to do any painful elf migration
<heat>
are you a COFFer
<mjg>
professional enterprise caugher
JerryXiao has quit [Client Quit]
JerryXiao has joined #osdev
goliath has quit [Quit: SIGSEGV]
<heat>
whats the general wisedom for printf()? generic-ass state machine?
<sortie>
Just iterate the format string and do what it says
<sortie>
Works fine until you get to positional parameters
<heat>
like state = NORMALCHAR; if (c == '%') {state = PERC; continue;} and then have states for the % shit
<zid>
impossible challenge: write printf without goto
<sortie>
Nah state machine goes crazy
<sortie>
I tried it in the paste, it literally isn't needed
<mjg>
hmmmm
<mjg>
heat: ey you lazy mofo, you reminded me of a small task
<bslsk05>
wiki.osdev.org: Meaty Skeleton - OSDev Wiki
<mjg>
heat: add a format specified for symbol resolution
<mjg>
zid: but goto considered harmful!
<mjg>
heat: first you would need to add lockless lookupz for the symbol table
<mjg>
heat: interested/
<heat>
probably not
<heat>
not at the moment at least
<heat>
kinda in the middle of something
<zid>
I like how that immediately has an overflow bug
<heat>
sortie, yeah but you skip all sorts of fun processing there
<zid>
oh wait maybe it doesn't, that's super hard to parse
<sortie>
heat, obviously :) But the structure grows the right way
<heat>
%016lx is much harder to parse there
<heat>
hence... goto?
<sortie>
No it's much easier
<sortie>
You just parse it
<dh`>
os161's printf doesn't have goto
<heat>
that's not helpful
<zid>
is it bad?
<zid>
mine always do, and the one reference printf I looked at to see if mine was insane looked nearly identical, and also did goto
<dh`>
I don't think it's bad
<heat>
the glibc printf is nuts and table based
<dh`>
don't think it does positionals but it could be added
<sortie>
heat: You use an index into the format string. Then if you see digits, you parse each digit and increase the counter appropriately. If you see special flags, you set the bool and increment the format string. Then finally you find a directive and you do it
<bslsk05>
github.com: bootstrap/boot/print.c at master · zid/bootstrap · GitHub
<dh`>
it was originally written in like 1997 and hasn't been changed much since so it may not meet current standards, but it was fairly clean at the time
<bslsk05>
docs.google.com: Computer Books - Google Docs
<geist>
it's out of date in the sense that i haven't been buying new books, but then not much has changed since
<mjg>
so to be cleark, the lkd book is OLD
<mjg>
but does provide a valuable overview in terms of general concepts
<geist>
yep
<geist>
exactly
<geist>
even old designs can give you good valuable overviews
<mjg>
but most don't
<mjg>
let's be clear :S
<geist>
i disagree. even old implementations can give you the historical basis to then build up modern stuff on top of
<mjg>
i already ranteda bout this earlier today
<mjg>
not doing it again
<geist>
not everything has to be the most modern highest end thing
<mjg>
:]
<geist>
okey dokey
<geist>
like i've learned a lot from things out of the late 70s, etc
<geist>
just have to know what is and isnt useful, and what algorithms/data structures have been replaced with newer things and why
<geist>
and when learning out simpler designs are easier to grok
<geist>
anyway you folks are hanging out on the osdev discord again?
<heat>
geist have you seen that bill joy paper thing i posted?
<geist>
i have not. didn't read the full scrollback
<heat>
talks about early ideas of UNIX IPC and mmap (segalloc, segfree)
<heat>
and why they needed this
<geist>
oh neat
<heat>
they wanted to support GIGABYTE address spaces
<heat>
how huge!
<geist>
yah that's the max size of a VAX aspace, i think
<heat>
no
<geist>
well, okay i think user spae could map 2GB, but it was in two segments
<heat>
they talk about 2GB
<heat>
ah
<geist>
but the second one grew down
<heat>
one idea they had was to split the address space in 64KiB chunks for Some Reason
<geist>
yah always interesting to see if there was some hardware reason at the time. depending on when he was writing it it may have been VAX or 68k or sparc based
<heat>
yeah this is a VAX
<geist>
but VAX was kinda the gold standard there for a period
<heat>
i find it interesting how they talk about the hardware in a slightly different way
<heat>
like I feel it's more centered on the hardware itself
<heat>
"Proposals for the enhancement of UNIX on the VAX"
<geist>
i dont see the link off hand can has repost?
<geist>
yeah i think back then porting was more of a copy of the code and make it work on the new hardware
<geist>
neat, will be a good reasd
<heat>
yeah i have a feel that they saw it more like an OS was an auxiliary thing to the hardware
<heat>
whereas these days you "use Windows", back then you had a VAX, and used whatever could make it useful
<geist>
also i think unix and vax and unix right about that time frame (1980) was when unix startde really growing MMU capability
<geist>
because of the VAX really, which was probably the first really fairly inexpensive paging capabile minicomputer
<geist>
of course x86/68k/etc would copy that a few years later
<geist>
3 or 4 years later bill joy would go over and start sun microsystems and the sun1/sun2/3 hardware was 68k based with a custom paging MMU, iirc
gareppa has quit [Quit: WeeChat 3.8]
<heat>
so odd question but how was the mips r3000 mmu situation?
<geist>
iirc i think it's a multi level page table, but i might be mistaken
<geist>
possibly it was a TLB miss exception based thing
<heat>
ppl here were saying the playstation had no MMU (and that the cpu had no mmu) but my SVR4 book depends on the MMU, and describes SVR4 on the r3000
<geist>
well, you could easily leave it off for somethinglike playstation
<geist>
could have also been an external chip
<geist>
as were early paging mmus
<heat>
hmm yeah i guess
<geist>
i'm sure i've talked about it before but the vax has an interesting page table based system. for user space iirc it's split into two segements, 0-1GB, 1GB - 2GB. eah has their own page table
<zid>
mips is one of those
<zid>
build your own chips
<zid>
R3400i R3400 are also different cpus
<geist>
the page table is one run, has a base + length register in hardware
<geist>
but it lives *virtually* in kernel space
<zid>
mips also has various co-processors you can add in to the mix
<heat>
how do the segments work?
<geist>
so you can great a sparse page table for your process if you want
<geist>
it's not a segment in the x86 sense, it's just a predefined range of virtual space that is covered by this page table vs that
<zid>
the cpu in the psx has segmentation
<heat>
yeah
<geist>
iirc the second segment for user space grows downwards
<zid>
but they're more like MTRRs
<heat>
they mention that VAX has no segmentation (like it's a weird thing!)
<geist>
yeah vs something like pdp11, etc. it was a flat memory model
<sham1>
It's also why C has a flat memory model
<geist>
the only real detail is the way the user aspace grows bottom to top and top to bottom in hardware
<heat>
i wonder if it'd be fucked to do a proper segmentation thing for x86 gcc
<sham1>
Which is why you needed weird things to fit C for MS-DOS environments for example
<geist>
basically a way to avoid having to always fully alloc a 2GB / 512 byte * 4 page table for every aspace
<sham1>
Freaking _far
<geist>
but it also means there's an incentive to pack your aspace on either end
<geist>
since the page tables arent multi level sparse like later designs
SGautam has quit [Quit: Connection closed for inactivity]
<heat>
yeah
<heat>
intel came up with that?
<geist>
i'd say they're the first, but i betcha there's some minicomputer or mainframe that already did it years before
<zid>
segmentation is just banking implemented the other way around imo
<geist>
when i say segment i almost always mean 'not in the x86 sense'
<geist>
as in 'some special property of this range of memory'
<sham1>
zid: yeah, it doesn't charge interest
<zid>
yea, psx cpu has the "they're like mtrrs" type of segment
<zid>
mttrs?
<geist>
if you look at earlier minicomputers like pdp11 it is much lke 286 segmentation without the segment registers, a common design
<geist>
ie, there's a code and multiple data segments, and theprogram just doesn't see it, it's just set up with registers in the kernel to translate shit
<zid>
memory-type-rabbit-range?
<geist>
the slight wonkiness that the PDP11 has is the 64k address space is iirc divided into 8 8k segments, and each has their own base + length + permission field
goliath has joined #osdev
<geist>
so if you want to fully populate the 64k aspace you have to fill in each 8 segments, but then you have slightly more flexibiliity than a single 64k physical run of pages
<geist>
also when you context switch you have to blat those 8 registers
<geist>
so i guessin that regard the vax paging unit is a logical outgrowth of that: extend out to 32bits and instead of putting the base + length fields in hardware, put that table in memory
<geist>
and remove the length part, just set the granularity to 512 bytes (vax page size)
<geist>
which i also suspect had some influence on why a lot of hardware sectors and whatnot are 512
<heat>
why do they mention second-level page tables if its a single table?
<geist>
because it lives virtually in kernel space
<heat>
page 27 of the pdf, 3.6
<geist>
kernel has it's own page table that lives in physical space, and user page tables live *virtually* on top of the kernel
<geist>
so there's a two level translation when looking up user address
<heat>
hm
<heat>
bizarre
<heat>
any other archs did it this way too?
<geist>
ah so the sharing he's talking about there may be because then you can use a page in the virtual age table and double map it in the kernel
<geist>
and thus literally share pieces of the user page table
<geist>
also, lemme see, 512 byte pages divided by 4 bytes per entry, 128 entries... * 512. tjat's 64k
<geist>
so yeah that's what's going on there
<geist>
arrange for differetn user space page tables in kernel space to use the same underlying run of page table
<geist>
a picture is worth a thousand words here
<heat>
aha
<geist>
make sense?
<sham1>
What would that make the architecture's programmer's manual or schematic?
<heat>
yeah
<geist>
heat: so the modern analogy would just be sharing a second level page table between processes
<geist>
well, on a 32bit system, or a Nth level page table for larger ones
<heat>
yeah, you essentially make the kernel page point to the same stuff, so both users can share the same 64k segment
<geist>
also keep in mind at the time a really really large VAX would have had like 4MB of ram
<zid>
sheer decadence
<geist>
i think that was the max for a while.in the 80s they got up to 128, 256MB I think
<heat>
they mention having as a goal to run a 1g addr space in like 4MiB
<zid>
think of how many peasants you'd need weaving ferrite beads for that
<geist>
okay, 4MB is actually more like a really large PDP11. 4MB would have probably been a reasonable sized VAX
<geist>
iirc on vax 11/780s or so (first gen) a 1MB board was just a really large 19 inch board, so you could have easily stuffed in a bunch
<geist>
it was a fairly large machine, size of a refrigerator or two, uses a lot of DCL logic iirc, so ran fairly hot
<heat>
this is fucking amazing
<heat>
page 45 they propose make install, make clean and make as a standard makefile convention
valshaped742 has quit [Quit: Gone]
<geist>
nice
GeDaMo has quit [Quit: That's it, you people have stood in my way long enough! I'm going to clown college!]
<heat>
the historical value of all this stuff is so great
<heat>
these oldie systems were so similar to 2023 unix
<heat>
which says something about UNIX. good things? maybe, maybe not
<heat>
but early 80s UNIX being so damn recognizable and feature-packed is impressive
<heat>
even if the internals were sometimes not sound or sometimes not OPTIMAL
<geist>
yeah exactly
valshaped742 has joined #osdev
<geist>
somethig that works but not optimal is infinitely more useful that nothing at all
<geist>
being super optimal is i think a more recent concern, to be honest
<geist>
along with being hyper secure
<heat>
yeah
<heat>
give it a bad pointer, watch it crash!
<heat>
the true computing experience
<heat>
EFAULT my ass
<geist>
well, thins like on these old unices, something like ps just grubs around in the kernel memory
<heat>
oh yeah
<heat>
make still has code for that too
<geist>
a cheesy but kinda elegant solution to the problem
<heat>
to get the loadavg
<geist>
intrinsically single cpu, non reentrant, just stop the world and walk the kernel data structures
<heat>
for some platforms it "looks" at the running kernel's avenrun symbol
<heat>
there was also really stupid examples for things not as old as this
<heat>
i think SVR4 had a couple of good ones
<geist>
but also at the time VMS heads were seriously poopooing on unix because of exactly this
<geist>
i think it took unix a good solid 10 years or so after that to get serious enough for mission critical bits
<geist>
(for a lot of people at least)
<geist>
since VMS neve had any of those sort of nonsense things, and was much more 'modern' in the sense that it was secure from first principles
<geist>
though i'm sure modern stuff can poke holes all in it
<geist>
presumably mainframes at the era were also intrinsically more stable since they were already very virtual machine based
<zid>
security mainly being an arms race of "how much people care" more than anything else
<geist>
yah and/or military/government regulations pushing things forward
<geist>
i remember in the early 90s stuff like C2 rating and whatnot was already a thing
<zid>
computers got to be jucier targets, so security improved in response to them being targetted, etc
<geist>
hmm, woder where C2 came from
<mjg>
old unix was a hackjob
<mjg>
lake you would not believe
<mjg>
:X
<mjg>
how did they get medals for it still escapes me
<geist>
i remember in college we had a Cray on display behind a glass room, but they later had to move it to some secure room
<geist>
since C2 rating among other things says you can't have line of sight to it
<geist>
early unix was like the FreeDOS of the era. you ran it if you didnt want to pay for thins and you wanted to hack it
<sham1>
mjg: it was a hackjob that worked
<sham1>
*
<mjg>
tr.dat
<sham1>
I suppose it was also innovative in some way
<sortie>
heat, what document are you reading?
<mjg>
interesting that you got systems without kernel/user split *later*
<geist>
mjg: what do you mean by kernel/user split?
<geist>
oh you mean not having separate address spaces, etc
<geist>
8086 didn't support it, IIRC there's not even user/supervisor
<mjg>
rings
<geist>
that was 286
<mjg>
so they could not do it even if they wanted to
<mjg>
it set everyone back big time innit
<geist>
286 was a silly attempt to start adding proper permissions and whatnot to the system
<geist>
well, 8086 was just some toy microcontroller, fairly powerful for the time in the world of microcontrollers
<geist>
er microprocessor
<mjg>
i guess by that time you had to not support it for the sake of compatibility
<sham1>
We all know that M68k is wonderful. But how was M6.8k
<geist>
they were doing really good to fit anything into the chip in the firstp place
<geist>
it was a race over the next 10 years to keep cramming more and more minicomputer style things into a microprocessor
<geist>
from about 75-85
wootehfoot has quit [Ping timeout: 240 seconds]
<geist>
leading up to 68k and 386 in about 84/85
<sortie>
mjg, thank you :)
<geist>
where you now have something approximately vax-like in a microprocessor
<mjg>
go vax
<geist>
(at the same time DEC was shrinking vax to microprocessors too)
<geist>
tha was a period of amazing technical development
<geist>
really up until about 2000 it was leaps and bounds every year
<mjg>
windows 98 was the last big leap forward was not it
<mjg>
:X
<sham1>
Windows ME
<mjg>
fucking POS
<geist>
well, in CPU space is what i mean
<mjg>
sham1: i dodged that one
<geist>
98? it was great. i used the shit out of it
<geist>
was a solid improvement to win95
<mjg>
i the moore's law kept working until about 2010-ish
<geist>
yeah but i always posit that in consumer space CPU development hasn't been that interesting since about 2003 (when amd released x86-64)
<geist>
it's been much faster, multicore, etc, but not fundamentally new
<mjg>
right
<mjg>
fair
<geist>
obbiously GPUS, etc have had bit jumps but at a different cadence
<zid>
last interesting thing was uop caches
<sham1>
Nah, clearly the last interesting thing has been RISC-V
<geist>
yeah obviousy computer architectures have had a lot of cool tech achiemvements in order to keep things going
<zid>
reliving the 70s is interesting to some I suppose
<mjg>
last interesting was ITANIUM MOTHERFUCKER^w
<geist>
righ, about 1999/2000
<geist>
but really the cpu world collapsed about then, since a lot of theese other risc architectures died off
<sham1>
mjg: oh yeah, forgot about my beloved
* mjg
slaps sham1
<geist>
and we were left with mostly a monoculture until fairly recently
<geist>
but even that isn't as interesting as we make it out to be: armv8 and riscv are functionally equivalent to x86 as far as most peoplea re concerned
<geist>
*we* care, because it's different and interesting, but after that it doesn't matter
* mjg
does not care :X
<geist>
all of the major differences are shaved off, all 3 major architectures now are basically identical: little endian, 64bit, similar alignment constraints, similar vector support, etc etc
<geist>
paging, etc
<mjg>
and all systems are either linux or windows
<sham1>
mjg: please no slap :C
<geist>
thats where we come along!
* mjg
pets onyx
<mjg>
... yet another unikkkz
<sham1>
Why did world converge on little-endian again
<geist>
x86
<mjg>
forgot about os x!
<geist>
both arm and riscv can run in big endian mode if you want them to, but there's really no reason to. even POWER is starting to run in little endian mode most of the time nowadays, IIRC
<geist>
iirc i think IBM switched to LE as their default nowadays?
<sham1>
I like big endian though. Makes more sense for my brane
<CompanionCube>
depends on the OS?
<mjg>
heh
<mjg>
who is even testing BE though
<mjg>
at this point it is legacy deployments and a historical curiosity
<geist>
only real reason nowadays is if you have some sort of network switch, etc
<sham1>
Big Endian is literally how you write numbers
<geist>
and even then if speed is that big of a deal offload it into hardware
<geist>
yah but we write numbers backwards for historical reasons
<mjg>
what is not done for hysterical raisins
<geist>
(at least in left to write writing systems)
<geist>
though i guess you can arge that if you're reading left to right, having the most significant digit first makes sense
<geist>
but you dont know how significant it is until you count the number of digits
<sham1>
Even the bloody roman numerals are big endian
<geist>
sure, historical reasons :)
<mjg>
romans clearly did not get the memo
<geist>
but in reality the rason everything is little endian now is x86. nothing else was little endian except arm and x86 in the 80s and 90s when there was a huge arms race of risc machinse
<geist>
but then they all died out for other reasons unrelated, and there you go, left with the only use
<dh`>
having the most significant digit first only makes sense because we speak numbers that way in english (and, granted, most langauges) but it isn't any more inherent than any of the rest
<geist>
dh`: iirc german reads then backwards to engish, iirc?
<dh`>
idk
<geist>
something like 'N and N tens'
<sham1>
Only the tens for some reason
<sham1>
It's inconsistent
<sham1>
Dates are also big endian
<geist>
ah, interesting. i only know that because 99 luftballoons
<mjg>
write data in mixed endian
<sham1>
I don't count whatever Americans are doing
<geist>
americans do dates in mixed endian because we're weird
<sham1>
Yeah, and Europe does little endian even though we really should do big endian as per iso
<geist>
yeah, i think that's a case where the european one is also kinda silly. YYYY-MM-DD is the only thing that makes sense
<geist>
since it sorts properly
<dh`>
that's only true in left-to-right text
<sham1>
Even on right-to-left text
<geist>
right you'd treat it as a single word it wouldn't matter
<heat>
the european one makes sense
<heat>
for normal people
<heat>
its in order of importance
<sham1>
Hebrew and Arabic readers already get these issues when a foreign word either in Latin, Cyrillic or for example a CJK script appears because all those are nowadays written left-to-right. It's "fine"
<heat>
nobody gives a shit about the year
<sham1>
I give a shit that it's the year of our Lord 2023
<heat>
day-month-year is correctly ordered by importance
<heat>
whereas year-month-day is usually <irrelevant>-<useful backwards>-<useful backwards>
<sham1>
Why not also include the day of the week then? It's usually the more important thing than even which day of the month it is
<heat>
hm i mean that's not in the standard date format
<heat>
but in that case day of the week, day, month, year also works
<sham1>
I mean, for me today it's 7th of June, 2023. But what I mostly care about is that it's a Sunday
<heat>
sure, so you'd put that first
<heat>
Sunday, 7th of June, 2023
<heat>
important first, mostly irrelevant second
<heat>
ISO 8601 makes no sense except for nerds that want to easily sort dates
<sham1>
Also parsing
Bonstra has quit [Ping timeout: 264 seconds]
Bonstra has joined #osdev
<heat>
geist: you forgot about the transmeta crusoe!
<heat>
now that's different!
<kof123>
it is june, anything is possible
<gog>
hi
<gog>
it is me the gog
<zid>
wait, the REAL gog!?
<zid>
This is amazing, it's an honour to meet you
<bl4ckb0ne>
hi gog
<sham1>
But who'd be the fake gog
heat is now known as grog
<grog>
it me
<grog>
seriously this is registered wtf
grog is now known as gog_
<gog_>
there we go
<Cindy>
hiii
<gog_>
hi
<gog_>
it is me the gog
* Cindy
petpet gog_
* gog_
prr
<Cindy>
hmmmm
<Cindy>
checks out
* Cindy
petpetpetpet gog_ more
* gog_
prr more
<Cindy>
meow for me
<gog_>
bark
<Cindy>
test failed >:(
<gog_>
your tests are wrong haha unit tests i would never
<zid>
fission mailed
* Cindy
mails some fission to zid
<Cindy>
fission is an actual word
<zid>
yes, so is mailed
<gog_>
you've got mailed
<gog_>
wait no
<gog_>
you've got fission
<gog_>
there it is
<zid>
I'm going to guess you'd get arrested if you really mailed fission
sinvet__ has joined #osdev
sinvet has quit [Ping timeout: 245 seconds]
<sham1>
> your tests are wrong
<sham1>
You're literally out-of-spec
<zid>
tests are always wrong
<gog_>
if a test fails, the test is obviously wrong
<zid>
if they exist, it's something someone thought of to test
<zid>
it's the behaviors nobody thought to check that are the buggy ones
<bslsk05>
'Nobody Can Program Correctly - Lessons From 20 Years of Debugging C++ Code - Sebastian Theophil' by CppCon (00:51:48)
<gog_>
>Quantifying dinosaur pee
<mcrod>
"nobody can program correctly"
<mcrod>
"C++"
<mcrod>
pick your poison
<zid>
Nobody can program C++ correctly, this is of course, a reflection on the programmers.
<gog_>
you know the saying "correlation does not imply causation"?
<gog_>
in this case, it is definitely false
<zid>
If only programmers were better :(
<mcrod>
C++ is a horrifically complicated language with 492823982938923 different things that can go wrong
<mcrod>
people who masturbate to complexity don't know anything
<gog_>
rangeeeeeeeeeeees
<mcrod>
I get peeved every time I see a C++ programmer saying others can't program
<mcrod>
they'd be *helpless* without std::vector
<mcrod>
helpless, I tell you
<zid>
I call it C++ stockholme syndrome mcrod
<innegatives>
we just need to add operator overloading to C then we'd not need C++
<mcrod>
there are sadly some features of C++ that are useful
<mcrod>
but I didn't say C++ as a whole was good.
<zid>
They spent 15 years fighting C++ compilers, of *course* it was worth it and the skills they learned were useful and valueable, they were hard to learn!
<mcrod>
you know what I had someone tell me
<mcrod>
therac 25 wouldn't have happened if Rust was being used
<zid>
dw, there's a perfect safe subset of C++ that's wonderful
<zid>
It just won't be the same perfect subset any one else swears by
<gog_>
that's not true zid, i share subsets with geist
<gog_>
2 people!
<gog_>
i also share subsets with mcrod
<mcrod>
basically a software error caused people to get completely irradiated when they were going for cancer treatment
<gog_>
3!
<zid>
therac woo
<mcrod>
read: the problem wasn't the language
<gog_>
we have tripled in size over the last 2 minutes, now this is growth
<mcrod>
the problem was the people working on it
<mcrod>
"Several error messages merely displayed the word "MALFUNCTION" followed by a number from 1 to 64. The user manual did not explain or even address the error codes, nor give any indication that these errors could pose a threat to patient safety." <- no language on this planet can solve this
<mcrod>
"The hardware provided no way for the software to verify that sensors were working correctly. The table-position system was the first implicated in Therac-25's failures; the manufacturer revised it with redundant switches to cross-check their operation." <- Rust can't solve this either
<zid>
If they thought writing a system that relied on not havign race conditions to not kill people was the correct approach, they clearly had their brain rotted out though
<mcrod>
right
<mcrod>
point being, there's no language on this earth that will be better than developing critical thinking skills
<sham1>
Nah, just irradiated
<sham1>
Their brains were irradiated from testing the apparatus
<mcrod>
also normally I don't just jump in and get on the bandwagon
<mcrod>
but
<gog_>
if rust existed back then jfk would still be alive
<mcrod>
I *despise* the attitude of someone saying "nobody can program correctly" at a C++ conference
<mcrod>
performance critical software doesn't use 98% of the features C++ offers
<mcrod>
and that's not because people are stupid
<mcrod>
that's because reality trumps fiction, for nature cannot be fooled
<mcrod>
i just get on my high horse when it's in particular a C++ programmer claiming no one else can program other than them
<sham1>
C++ has a wonderful and sane subset just hiding. It's basically just C with some **basic** templates
<sham1>
And **basic** RAII
<innegatives>
in this thread: c brogrammers who can't program in c++
<gog_>
in this thread: boohoo shut the fuck up
<sham1>
Oh I can program in C++. I just choose not to because it's an endless swamp.
<zid>
The software set a flag variable by incrementing it, rather than by setting it to a fixed non-zero value. Occasionally an arithmetic overflow occurred, causing the flag to return to zero and the software to bypass safety checks.
<zid>
That's amazing
<mcrod>
sham1 I think the problem is
<zid>
1/65k chance of your software doing the wrong thing is fun
<gog_>
sham1 are u interested in contributing to onyx
<mcrod>
every C++ programmer is stackoverflow personified
<gog_>
basically c with basic templates and basic raii
<mcrod>
i.e., no one can agree on even the most basic things
<sham1>
I've walked the walk, talked the talk and SFINAEd the SFINAE
<mcrod>
"AECL did not consider the design of the software during its assessment of how the machine might produce the desired results and what failure modes existed, focusing purely on hardware and asserting that the software was free of bugs."
<mcrod>
this is also why I have a crusade
<mcrod>
against Rust
<mcrod>
the mindset just drives me nuts
<mcrod>
it is indeed very possible to have bugs with Rust code
<gog_>
meow
<mcrod>
it's not a magical figure
<innegatives>
if it compiles then its correct (tm)
<gog_>
lets focus on important questions
<mcrod>
yes
<sham1>
I don't wish to do that anymore. I'll take my C99 and do things that don't make me want to pull my hair out deciphering weird ISO C++ arcana with terrible error messages and whatever templates + overload sets give me
<gog_>
why do people brush me off when i ask for contributions?
<mcrod>
first question: gog_ may I pet you
<gog_>
yes
* mcrod
pets gog_
* gog_
pr
<gog_>
now im writing a unix for you, send me a pr
<gog_>
its in C89
<gog_>
nice and safe
<gog_>
no mixed variables and code, none of that
<sham1>
ISO C also has weird standards arcana, but it's more understandable
<mcrod>
up until two years ago
<mcrod>
I was a C++ guy, like, using the STL like no one's business
<mcrod>
then it occurred to me
<mcrod>
a) no one can understand it, and that's not because the code is necessarily bad, but because the interfaces are complex
<mcrod>
b) simple tests result in poor code generation on a few compilers
<gog_>
this channel is slowly devolving into #grumpy-tech-people
<mcrod>
:(
<mcrod>
ok I'll stop dammit
<gog_>
ok now important questions
<gog_>
contribute code to me
<mcrod>
that's a demand not a question
<gog_>
you never had a say in it in the first place
<innegatives>
gog_: send repo
<gog_>
no
<gog_>
you have to prove thyself worthy
<gog_>
mcrod is equally as grumpy as me, thus, worthy
<innegatives>
i can fix the spellings
<innegatives>
lol
<sham1>
Before I stop my grumpy yelling at clouds, I want that people consider the principles of Bauhaus in writing code
<gog_>
do you know what makes an operating system good?
<innegatives>
yes, of course
<gog_>
it's when its name rhymes with mypenisissoft winblows
<innegatives>
indeed
<sham1>
Hollowed be the name NT
<gog_>
in windows i average 0 grumpies/irc session
<gog_>
in linux i instantly get sadder and average at least 10 grumpies per irc session
<sham1>
I get grumpy existing in a Windows session
<sham1>
It doesn't pass my vibe check. It's very much not Bauhaus
<gog_>
is macos bauhaus?
innegatives has quit [Quit: WeeChat 4.0.0]
* kof123
files "that's not a bug, that's a feature" report The small dog bark of the sand cat has been described as a rapidly repeated harsh cry which sounds like: “yea-yea-yea”
Left_Turn has quit [Read error: Connection reset by peer]
sortie has quit [Quit: Leaving]
sortie has joined #osdev
dutch has joined #osdev
MrBonkers has quit [Remote host closed the connection]
MrBonkers has joined #osdev
<mcrod>
gog_: quis custodiet ipsos custodes?
<mjg>
OH
<mcrod>
OH
<gog_>
OH
<mjg>
OOOH
<mjg>
so i watch another youtube video, dude talks about scammers
<mjg>
grifters 'n shit
<mjg>
how they lie their asses of
<mjg>
so far so good
<mjg>
and then he says nobody would lie about being able to code