<kazinsal>
classic bpf is neat because it's straightforward, does exactly what you'd need a virtual machine for packet filtering to do, and real easy to JIT
<kazinsal>
ebpf is neat because it's the complete opposite, in a fascinating yet terrifying way
<heat>
ebpf is even easier to JIT
<heat>
it's very much like a 1-to-1 of x86 assembly or so
<heat>
which is like the scary bit
<mjg>
hue, libreoffice calc crapped out on intel pcm output
<mjg>
gnumeric took it like a champ
<mjg>
also i just learned gnumeric exists
<heat>
is gnumeric the gnu plot of excel
<mjg>
:]
<mjg>
you are an asshole and that bodes well
wereii has joined #osdev
<heat>
ouch
<heat>
i love you too man
<mjg>
i'm trying to decide whether total ipc of about 1.5 from *both* threads is o
<mjg>
k
<mjg>
0.75 each
<mjg>
i'm gonna go with crap
Left_Turn has quit [Read error: Connection reset by peer]
[itchyjunk] has quit [Ping timeout: 250 seconds]
[itchyjunk] has joined #osdev
<AmyMalik>
if a kernel doesn't expect the idle instruction to blow up the TLBs, will anything bad happen if it will? (context: I'm trying to fix a power virus that's good for most of 1 watt on a Kabylake quad core in FreeBSD)
<AmyMalik>
I'm probably just kinda chatgpt brain at the moment (no I haven't actually used chatgpt) - so if the question makes sqrt(-1) multiplied by sense, feel free to tell me so
<moon-child>
what do you mean by 'idle instruction'?
<mjg>
is it pause?
<mjg>
you mean the idle loop in general?
<AmyMalik>
"the idleinstruction" could be hlt or mwait, since I'm on x86
<AmyMalik>
(it's mwait, as configured)
<AmyMalik>
ok I'm just going to blindly change how it does it and let you know how it goes
<moon-child>
oh like the address you wait on is stale wrt tlb?
<mrvn>
if it throws an exception then the kernel would panic since you can't kill the idle thread.
<AmyMalik>
eph
<AmyMalik>
idk
<mrvn>
Do you mean it simply doesn't sleep, always just wakes up again?
<AmyMalik>
uh, pass
<mrvn>
Have you asked on the freebsd channel?
<AmyMalik>
I have asked in their dev chat if anything bad will happen if the idle thread blows away the TLBs (which it is claimed that deeper C-states will do so)
<heat>
answer: no
<heat>
the tlb is mostly transparent to the x86 execution state unless you dun fucked up
<AmyMalik>
no what? no nothing bad will happen? or no you won't be able to do this without your dog getting shot?
<heat>
nothing bad should happen
<AmyMalik>
alright
<heat>
like, relying on the TLB being stable is a shit idea because that's not really realistically going to happen
<AmyMalik>
I'll add a tunable to directly adjust which hint to pass to mwait and I'll let you know how it goes. I'll let you know if my (imaginary) dog gets shot.
<heat>
but ofc this assumes whatever tlb thrashing logic that mwait does properly marks the "tlb entries" as "unused" instead of a random dontcare
<heat>
because that will obviously shoot your dog
<heat>
mjg, what happened to the ebpf on freebsd movement
<heat>
is it ded
<mjg>
no idea
<mjg>
resurrecting the effort would be most welcome tho
<heat>
but is it tho?
<heat>
what place would ebpf ever take in freebsd?
<heat>
is anyone ready to ditch dtrace or something?
<mjg>
ditch? no, but it is a more powrful thingy
<heat>
it might encourage psychotic uses of in-kernel bytecode if that's what you're looking for
<mjg>
:]
<mjg>
i'm interested in not having to reinvent a bunch of scripts
<mjg>
some of which may not even be possible to do in dtrace due to lack of loops
<bslsk05>
git.kernel.org: open.c « fs - kernel/git/torvalds/linux.git - Linux kernel source tree
<mjg>
linux in all its glory
<mjg>
hsit on freebsd all you want, it had transparent huge pages years before linux, including for regular files
<mjg>
and it defo does not have the problem with writes either
<mjg>
[it does have other problems thoguh :>]
<mjg>
that smb_mb in there is cherry on top
<AmyMalik>
if you want to put ebpf into your own private branch of freebsd I won't stop you
<mjg>
thank you for that reassurance
<AmyMalik>
I will warn you that the netlink invasion isn't warmly welcomed
<heat>
AmyMalik, what netlink
* AmyMalik
sighs
<heat>
SIGHS
<heat>
but seriously what are you on about with netlink
<AmyMalik>
it is apparently being added to freebsd
* sakasama
sighs in triple agreement.
<heat>
oh
<heat>
cool?
<AmyMalik>
oh dealr
<AmyMalik>
anyway
<AmyMalik>
yeah I'm gonna figure out this mwait thing
<heat>
"Netlink has been committed to HEAD. The code implements a subset of the NETLINK_ROUTE subsystem and NETLINK_GENERIC framework."
<heat>
this is a poggers moment
<mjg>
netlink as a general idea was implemented
<heat>
the important bit to understand here is that sockets that control networking stuff etc is nothing new and basically AFAIK originated from 4.XBSD
<mjg>
no code was ported afaics
<heat>
with AF_ROUTE
<mjg>
i have no opinion on netlink itself, but i do note the networking stuff likes to use it
<mjg>
bird et al
<mjg>
in fact *not* using it is some legacy code in various demons which quite frankly threatens its removal
<mjg>
in all the not-written-for-freebsd-stuff
<heat>
i have the opinion that it's horrifically complex but it's probably For Good Reason
<mjg>
so i think that smp_mb can be whacked
<mjg>
on assumption that write count is bumped with an atomic, which it is
<mjg>
the real fix tho would be to not have this wtf problem
<mjg>
i wonder if they do this only to avoid having to write entire 2MB chunks on mmap
<heat>
there have been great strides in IO with page orders > 0
<mjg>
ignoring bigger sizes :p
<heat>
no
<heat>
i'm /fairly/ sure that dirtying is per-page and not per-folio
<heat>
folio being the newish thing they use to represent collections of pages
<mjg>
instead of talking shit you better tell me where is the O_DIRECTORY bug rport
<heat>
covid's a piece of cake compared to linux namei logic
<geist>
heat: oh wow, did it get accepted?
<geist>
or did they jump down your throat yet?
<heat>
no i've just sent it
<geist>
THEYRE SLACKING
<geist>
you should have rewrite namei in RUUUUST
<heat>
you know I found the real issue like immediately and then spent an hour or so tracking down an issue that turned out to be "I get -EROFS because I forgot to mount root rw"
<heat>
geist, is "and %eax, %eax" the best method to zero the upper 32 bits of something on x86_64?
<geist>
hmm, good question
<geist>
movsx maybe? i honestly dunno
<heat>
well movsx won't zero
<heat>
and $0xffffffff, %eax is an option, but it's a 3 byte opcode (imm8)
<heat>
and %eax, %eax is 2 bytes
<heat>
mov %eax, %eax is also 2 bytes
<heat>
even something silly like add $0, %eax works
<heat>
wait, is there no way to do a partial 32-bit register store?
<geist>
hmm, mov eax eax may e it
<geist>
also could just run it through godbolt and see what it does
<moon-child>
I don't think self-move will eliminate
<moon-child>
but I would do that rather than anything else
<heat>
i guess or eax, eax also works, for the weirdos
<geist>
might be worth checking the optimization manual to see if there's a special case for it
<geist>
though obviously there is for xor reg, reg
<heat>
ooooh, or imul $1, %eax
<geist>
or at least the cpu sees that as a zero cost zeroing op
<heat>
i stan the imul way
<geist>
shl 32; rhl 32
<geist>
shr
<heat>
using div would be funny but i'm not unreasonable
<moon-child>
vmovd xmm0, eax; vmovd eax, xmm0
<moon-child>
it's advanced vector xtensions, so you know it must have advanced performance
<geist>
push/pop
<heat>
wrmsr; rdmsr
<heat>
i won
<heat>
oh yeah have you guys seen the soon to be new intel instructions to read and write lists of msrs?
<heat>
you will also be able to do non-serialized writes to MSRs
<heat>
(found out from the llvm release notes)
bgs has quit [Remote host closed the connection]
staceee has joined #osdev
staceee has quit [Remote host closed the connection]
staceee has joined #osdev
staceee has quit [Remote host closed the connection]
staceee has joined #osdev
staceee has quit [Remote host closed the connection]
staceee has joined #osdev
staceee has quit [Remote host closed the connection]
staceee has joined #osdev
<geist>
oh huh no
<AmyMalik>
progress
Clockface has joined #osdev
<AmyMalik>
I manually diddled the mwait settings, and didn't achieve anything the OS itself had not already achieved with ACPI
<Clockface>
how long do I have before they start not bothring with legacy bios mode
<Clockface>
*bothering
<AmyMalik>
Clockface, about minus two years
<Clockface>
if i go to walmart and pick up a laptop, do the brand new ones still have CSM mode?
<AmyMalik>
probably? but a lot of things likely won't work
<Clockface>
will they get rid of x86's legacy mode someday?
<Mutabah>
Unlikely
<Clockface>
seems kind of pointless since UEFI dumps you into long mode
<Mutabah>
but possible
<Clockface>
i dont see why it would stay, they dont seem to care about people running windows XP or DOS crap anymore since CSM is dying
<Clockface>
real mode seems a bit pointless without bios
<AmyMalik>
the legacy modes are still important to the x86 processor strapping itself into long mode
<AmyMalik>
until that changes, it's here to stay
<Mutabah>
That, and the legacy modes have a lot of fingers into places
<Mutabah>
e.g. segmentation - that's part of long mode (slightly, but still there)
<Mutabah>
And iirc SMM is effectively unreal mode
<Mutabah>
Removing the other modes likely won't simplify the architecture enough to be worth the engineering time
<kazinsal>
they tried selling an embedded systems version of the 386SX back in the day that booted directly into protected mode and it was a commercial failure
<Clockface>
i thought intel quark did something like that, am i remembering wrong?
<Clockface>
some guy told me it dident boot into real mode, and i never touched it so i have belived him ever since
gog has joined #osdev
bauen1 has quit [Ping timeout: 250 seconds]
GeDaMo has joined #osdev
bnchs has quit [Remote host closed the connection]
tomaw- has joined #osdev
tomaw has quit [Killed (lithium.libera.chat (Nickname regained by services))]
tomaw- is now known as tomaw
bauen1 has joined #osdev
bauen1 has quit [Ping timeout: 256 seconds]
bauen1 has joined #osdev
bnchs has joined #osdev
bradd has quit [Ping timeout: 246 seconds]
Left_Turn has joined #osdev
CalculusCats is now known as CalculusCat
gildasio1 has quit [Remote host closed the connection]
gildasio1 has joined #osdev
CalculusCat is now known as CalculusCats
<zid>
fucking RAF woke me up, did ww3 start yet
<GeDaMo>
Wouldn't that be more likely if you'd been woken by another country's airforce? :|
<zid>
depends where the war is
<Ermine>
zid: RAF?
<zid>
royal airforc
<GeDaMo>
Yes, air fork :P
<Ermine>
Ah ok
<zid>
someone was doing laps over my house with the afterburners on
<Ermine>
GeDaMo: air exec when
<Ermine>
zid: jerks
<GeDaMo>
I have helicopters going over my house multiple times a day
<GeDaMo>
Back and forth from the rigs
<zid>
helicopters are the least cool transport somehow
<zid>
trains? Lots of people like to watch trains. Fighter jets? obviously very cool.
<zid>
Helicopters? Just noisy.
<zid>
no respect for something that just awkwardly claws its way through the air with brute force in a stupid way, I guess
<nortti>
I get the healthcare circuit's helicopter passing overhead every few days where I live, as I live pretty close to the hospital
<nortti>
but weirdly enough it's not the only helicopter you get here, every once in a while the border guard flies over the river doing something, and I've also seen a light-framed blue helicopter do laps several different occasions
<GeDaMo>
When the helicopters fly over the river here it's usually because someone fell in :|
<zid>
and they want to rescue the shortbread and heroin before it gets damp
<gog>
we have an airport right in the middle of town and basically everywhere downtown is under the main runway's heading
<Ermine>
helicopters above the water look cool
<nortti>
< GeDaMo> When the helicopters fly over the river here it's usually because someone fell in :| ← for that I'd expect them to use the healthcare circuit's helicopter. dunno about the one here, but the one in oulu is literally named the acronym of 'extinguishes [fire], searches, rescues, and provides first-line medical care'
<nortti>
(SEPE; sammuttaa, etsii, pelastaa ja ensihoitaa)
<Ermine>
gog: my granny's house is under glide path, so there is a plane descending every few minutes
<mrvn>
GeDaMo: Helicopter - beating the air into submission until it agrees to lift you up
<mrvn>
zid: Helicopter are noisy? Did you ever watch Airwolf?
<Ermine>
Well airplanes are prohibited to go supersonic under certain altitude for a reason
<mrvn>
Anyone looked at the ThunderBerry5 board? RPi form factor but with a Qualcom Snapdragon QCS610 (+ RP2040 for GPIO). The SoC is nearly the width of the board, the GPIO and HDMI connectors barely fit next to it. :)
<mrvn>
Ermine: broken windows come to mind
<zid>
I've heard a sonic boom
<zid>
I assume the guy who did it got a bollocking
<mrvn>
It's fun to model what happens when you fly at mach 10 or 20 through New York above street level.
nyah has joined #osdev
bgs has joined #osdev
<mrvn>
Wow, this was an odd breakdown. When /tmp is full then suddenly slurm drops all accounts and all slurm users have "" as default account.
<mrvn>
No errors in the logs or anything. Clean up /tmp, restart slurmctrld, problem fixed.
<heat>
late stage web dev is frightening
<heat>
just did an angularjs tutorial for a uni course
<mrvn>
remote code execution 101?
<heat>
several hundred megs of garbage node modules just for a stupid hello world webpage
<mrvn>
I made an android app the other day. 2+ hours of installing androidstudio and fiddling with bits to get a hello world displayed on my phone.
<mrvn>
GB of garbage and I haven't even gone the x86 emulator on ARM way.
[itchyjunk] has joined #osdev
<zid>
sounds correct
<Ermine>
heat: same thing goes for React
<gog>
saægljaæ
<gog>
i'm currently fighting with a React component
Left_Turn has quit [Remote host closed the connection]
slidercrank has quit [Quit: Why not ask me about Sevastopol's safety protocols?]
Left_Turn has joined #osdev
sbz has left #osdev [#osdev]
<gog>
lmao
<gog>
yeah that's about right
<heat>
i don't even like enterprise nor java
<heat>
i'm in it for the degradation of capitalism
vdamewood has quit [Quit: Life beckons]
roan has joined #osdev
IRChatter has quit [Quit: ]
alturmann1729 has joined #osdev
<immibis>
mrvn: last time I tried it (back when eclipse was used) the IDE insisted on adding this library I didn't need every time I opened the project, that was 20x bigger than the rest of the project (<20kB)
terminalpusher has joined #osdev
heat has quit [Remote host closed the connection]
heat has joined #osdev
pounce has quit [Remote host closed the connection]
<mrvn>
immibis: Android Apps are java or kotlin with the GUI designed in xml and it takes 2 minutes every time to compile all that crap (1 hour the first time on the ageing laptop I used). And then when you selected "C++ App" the java has defines for an external function(s) and your C++ code gets compiled into a lib linked to the GUI to provide the functions. And you have to take and return java/kotlin types as
<mrvn>
arguments / return types. So lots of fun there too.
<gog>
yay my react component mostly works now
* gog
smashes keyboard
<mrvn>
don't react that way, it's supposed to be a moment of joy and happyness
<gog>
declarative stuff mystifies me
<gog>
idk how any of this works but it does
<mrvn>
isn't it more event based?
<gog>
i guess? idk
<mrvn>
attempts to be functional too
<gog>
it's declartive
<gog>
but also event based
<gog>
and the javascript it compiles to is atrocious
<gog>
(that's all javascript tho kekeke)
<mrvn>
Looks also like you just mix in html and java code any which way you like. How is it keeping that straight?
<gog>
the markup is mostly contained to the render() method
<gog>
and any objects that have events that a component cares about are passed as properties
<mrvn>
return (<button onClick={handleClick}> Click me </button>);
<gog>
you can do that
<gog>
but you can also keep it a little more orderly
<mrvn>
Looks like any time you want to switch back to code you have {...}
<gog>
yeah
<mrvn>
Is html output always in (...)?
acidx has quit [Ping timeout: 248 seconds]
<mrvn>
Or is that just to make it multi-line?
<gog>
it's always in ()
<gog>
afaicty
<gog>
idk i am not a react understander
<mrvn>
Anway, my point was the "onClick" That's an event handler. What's declarative about it?
inegatives has joined #osdev
<gog>
you can do taht for any property of a component or html element
<gog>
i have one that's like value={this.state.level}
<mrvn>
gog: that's straight out imperative.
<zid>
javascript understanders are called hostages
<gog>
and if i call this.setState({this.state.level = whtaever });
<gog>
all components or elements that refer to that state variable will be updated
<gog>
i don't have to bind anything else to make that work
<mrvn>
And there goes firefox. Suddenly my desktop feels empty and my CPU spins down.
<zid>
istm the main problem with js is that it's impossible to structure anything
<zid>
everything has near infinite scope and loads in a random order etc etc
acidx has joined #osdev
<gog>
all of our in-house JS code is an absolute disaster
<gog>
especially our analytics
<zid>
I don't think JS can't be a disaster
<zid>
that's my point
<gog>
yeah
<zid>
It's not like .c where I can make TUs, then turn TUs into libraries
<gog>
i've tried to come up with ways to make it cleaner but it'd be a massive undertaking
<zid>
and then main a simple main that includes a couple libraries
<zid>
and does go()
<gog>
and every page has custom JS bits stuffed into the View
<zid>
THE VIEW
<zid>
which in itself, is an organizational system pressed upon the lack of one
<gog>
yep
<gog>
all web applications are a disaster
<gog>
it was a mistake
<gog>
but i make money from it so
<gog>
and i'm an OK programmer i guess
<mrvn>
event driven programming isn't that nice for computing something
<zid>
Js either needs replacing with something proper, or deleting entirely, and tbh I'm leaning towards the latter, given what the web is like
<gog>
bring back java
<zid>
even if the pages used 1/10th the memory, space and time to run, that'd just make them do 10000x as much dogshit
<gog>
bring back applets
<zid>
applets were cool, I wanna play sodaplay
<mrvn>
zid: good old hypertext days where the best :)
<bslsk05>
panoramx.ift.uni.wroc.pl: We loved Soda Constructor
<mrvn>
What is that modeling? Now I want to build one for real.
<zid>
it's not as good :(
selve has quit [Remote host closed the connection]
<zid>
Now, as we have 2018 and I am after more than 15 years of my studies in physics doing stuff like simulations I realized that it would be funny to show this app to my kids. And what? Nothing. There is nothing left in the internet - the app dissapeared same as the Java applet technology
<gog>
rip
selve has joined #osdev
<mrvn>
Hah, I managed to turn it on it's back and now it can't right itself.
<mrvn>
zid: Does anything from the web 2.0 days still work?
heat has quit [Remote host closed the connection]
heat has joined #osdev
<pitust>
mrvn: it's not in () unless you want to do `return (LN<p>paragraph</p>LN)` where LN is a newline
<pitust>
you need it after return because of the definitely totally sane idea some js people had called "automatic semicolon insertion"
gog has quit [Quit: Konversation terminated!]
slidercrank has joined #osdev
<mrvn>
pitust: so "return \n <p>..." would turn into "return; \n <p> ..." and fail?
<mrvn>
i.e. to make it multi-line, just like you would in python
linear_cannon has joined #osdev
linearcannon has quit [Ping timeout: 255 seconds]
<pitust>
mrvn: yes
ilovethinking has joined #osdev
<ilovethinking>
hey, how's everyone doing
<pitust>
hello are you still refusing to use limine for literally no reason?
<ilovethinking>
maybe
<ilovethinking>
not refusing i just don;t want to use it
inegatives has quit [Quit: Client closed]
heat has quit [Read error: Connection reset by peer]
heat has joined #osdev
terminalpusher has quit [Remote host closed the connection]
linearcannon has joined #osdev
linear_cannon has quit [Ping timeout: 246 seconds]
<ilovethinking>
jmp GDT.Code:kentry
<ilovethinking>
is this translatable to GAS
<ilovethinking>
cuz i couldn't find anything online
<mjg>
heat: hue
<mjg>
i have difficulty parsing the response tho
<heat>
hue
<heat>
which response?
<mjg>
both
<heat>
why? I understood both replies
<mjg>
what exactly are they trying to do and how it differs from your patch
<mjg>
maybe i'm missing context
<heat>
they want to fix the stupid semantics here
<heat>
because O_DIRECTORY | O_CREAT only opening existing directories but doing regular file creation is STUPID
<mjg>
that is nto under question
<heat>
yes, that's what they want to fix, cuz I restored the old behavior
<mjg>
so they plan to make what happen spexifically
<heat>
that... i'm not too sure of
<mjg>
i refer you to my initial reaction
<mjg>
19:46 < mjg> i have difficulty parsing the response tho
<heat>
that's what I was going to ask, plus explain the situation on the other relevant unices at hand
<mjg>
totes check ILLUMOZ
<mjg>
you can probably join #illumos and ask someoen to run the prog for you
<mjg>
this network
<mjg>
alternatively just get a vm
<mjg>
good greif i wish i knew how to use a spreadsheet
<heat>
gnuplot effectively inhibits your office suite skills
<mjg>
rly tho, how does one only show rows which match an expression
<mjg>
say column S has values < 1
<mjg>
i'm this close to doing it in awk instead
Left_Turn has quit [Ping timeout: 264 seconds]
bauen1 has quit [Ping timeout: 265 seconds]
bauen1 has joined #osdev
<geist>
ilovethinking: yes. look at examples of kernels hta thave had to do it
inegatives has joined #osdev
bauen1 has quit [Ping timeout: 276 seconds]
bauen1 has joined #osdev
Left_Turn has joined #osdev
<heat>
mjg, ok replied to the BDFL
<ilovethinking>
geist: any example lol?
<ilovethinking>
what kernels are the best for reference
<ilovethinking>
mjg has a wikipedia page on him in my homecountry language which is pretty fucking crazy
<heat>
geist, linus has grown SOFT
<heat>
YOU HAVE GROWN WEAK, OLD MAN
<geist>
you must use this opportunity to strike true and hard
<mjg>
i don't think the l guy responding in a non-hostile manner is a rare thing
<mjg>
right, tell him to rebase on onyx
<heat>
linux kernel in ruuuuuuust haha
<heat>
o wait?
<mjg>
ilovethinking: btw i'm *not* matthew garrett, contrary to what heat claims, just in case
<ilovethinking>
wait did rust appear in the linux kernel
<ilovethinking>
lol
<mjg>
it did
<ilovethinking>
mjg: oh damn i got excited to finally meet someone popular
<ilovethinking>
god damn
<mjg>
sorry mate
<mjg>
i am popular with heat tho, if that is any consolation
<heat>
right, was just a joke
<ilovethinking>
i won;t look at you the same way from now, heat
<heat>
in reality we're looking at matthew garrett, famed freebsd PESSIMAList
<ilovethinking>
you betrayed me in every way possible
<ilovethinking>
it truly hurt me
<heat>
booohoo our marriage sucked anyway
<mjg>
ilovethinking: there is Brad Pitt lurkingon this channel tho
<mjg>
i wont reveal who it is
<ilovethinking>
sounds legit
<mjg>
true story!
<Ermine>
Ah, directories are to be created my mkdir/mknod, so open(O_DIRECTORY | O_CREAT) is a weirdo
<ilovethinking>
i knew brad pitt was an osdev
<mjg>
Ermine: ther eal weirdo is thatl inux creates a *regular file* and then proceeds to fail with ENOTDIR
inegatives has quit [Quit: inegatives]
<mjg>
Ermine: wtf even for linux
Ali_A has joined #osdev
<geist>
yah i guess there's not a security issue there, since there's no such capability in posix to create just files or just dirs in a directory
<geist>
but it's still really weird
<gog>
geist: geist
<geist>
if it allowed you to create a file where you couldn't otherwise, then it'd be a security issue
<geist>
gog: gog
<ilovethinking>
gog: gog
<heat>
fwiw I think this is allowed in POSIX so open(O_DIRECTORY | O_CREAT) could possibly do an atomic "open-dir-or-mkdir"
<heat>
which is a funny idea but probably far removed from reality
<ilovethinking>
wait geist hold on
<ilovethinking>
ljmp 0x8:address
<ilovethinking>
0x08?
<ilovethinking>
what's that
<geist>
if you dont know then you should be consulting the manual
<geist>
honestly, if that's no intrinsically obvious then yuo do not have the necessary background knowledge or desire to look it up to be working on this code
<geist>
not trying to rain on your parade but seriously the first instinct should be 'let me see what the intel m anual says about long jmps and how they work'
<heat>
or the GDT
<gog>
intel semantics that'd be "jmp far"
<ilovethinking>
fair
<ilovethinking>
thanks
* gog
jumps far
<geist>
a far long jmp
<heat>
bring segmentation back
<gog>
far: a long long way to jump
<geist>
and yeah i think the 'long' came from 68k or vax in at&t syntax. iirc they use that nomenclature
<gog>
NO
<gog>
segmentation bad
<geist>
though neither of those architectures have segmentation per se
<gog>
i want to osdev but i'm coded out for the day i think :(
<Ameisen>
question - I'm wondering if there would be a more performant data structure to use than a bitwise trie (like a page table/directory) for doing client address to host address lookups in vemips
<Ameisen>
presently, the architecture is very, very similar to a normal page table/directory
<zid>
Generically, no
<zid>
specifically, possibly
<ilovethinking>
i'll get the paperback of the intel manual
<ilovethinking>
so tht whenever i have a question i just remember to rtfm
<geist>
but if you want to grokk what's going on there you're about to get seriously into the deep end, so i start to wonder, what is it again you're trying to do?
<bslsk05>
github.com: vemips/directory_table.hpp at master · ameisen/vemips · GitHub
<gog>
the iGPU isn't so bad actually
<Ameisen>
so far I haven't really been able to outperform it
<mrvn>
gog: then you help him get the i915 to work :)
<gog>
it doesn't work in xorg
<gog>
for autorotating screen
<gog>
it only works in wayland
<Ermine>
I use wayland
<gog>
i have one of those converting tablets thoo
<gog>
oh
<Ermine>
and it works in xorg
<gog>
it never worked right for me
<Ermine>
on autorotating screen
<gog>
i don't use it anymore
<Ermine>
at least with kde and gnome
<mrvn>
Ameisen: with that work with large pages?
<gog>
it's entirely possible i had it misconfigured because i never reinstalled
<Ermine>
The only caveat is that lenovo fucked up orientation
<mrvn>
Ameisen: I mean mixed small and large.
<gog>
i just popped in my old hard drive
<Ameisen>
mrvn: I mean, vemips doesn't really have a concept of pages.
<Ameisen>
The MIPS32r6 doesn't require it :D
<Ameisen>
spec*
<Ameisen>
I just happen to use pages effectively for the lookup since it's convenient
<mrvn>
Ameisen: that header has too many things starting with an underscore.
<mrvn>
Shouldn't _forceinline be [[gnu::forceinline]] or something?
<heat>
Ermine, have you tried submitting a bug report
<Ermine>
no
<heat>
the i915 people are pretty good and should be able to look at whatever issues you may be having
<Ermine>
My ego requires doing it myself
<Ameisen>
mrvn: it builds under MSVC and Clang.
<Ameisen>
I don't actually target gcc at all right now (maybe eventually)
bauen1 has joined #osdev
<heat>
you've got an ego?
<heat>
welcome to the club, you should try writing an operating system
<Ameisen>
targetting gcc would be... complicated. not impossible, I just have to change a bunch of things
<Ameisen>
Part of the dynamic codegen presently assumes the win64 abi which clang can handle fine
<Ameisen>
It's harder to specifically use for specific calls in GCC.
<heat>
Ameisen, fyi gcc can also do the win64 abi
<heat>
__attribute__((ms_abi))
<Ameisen>
ah, it can now?
<mrvn>
Ameisen: I believe all the [[gnu:...]] work in clang too
<gog>
yeah i was targeting gcc for UEFI before
<gog>
without uefi_call_wrapper
<gog>
you can just use #define EFIAPI __atttribute__((ms_abi))
<Ermine>
heat: I'm extremely slowly going to that moment
<zid>
does regular pc-linux-x86_64 do that just fine then goog?
<gog>
yeah i think so
rnicholl1 has joined #osdev
<Ameisen>
then I can probably target GCC, though it isn't a priority yet
<Ameisen>
Ideally I'd just have the dynamic codegen be able to target Win64 _or_ SysV, but that's a pain
<Ameisen>
since SysV under MSVC would be... hard.
<rnicholl1>
Hi, when targeting raspberry pi 4 or raspberry pi 3, I think I need to read the device tree binary. are there any mit licensed DTB readers I can use to load information from the bootloader?
<Ameisen>
I do wish that Clang wasn't so strict about modifier consistency with __restrict
<heat>
rnicholl1, hi, generally people use libfdt
<heat>
not MIT licensed but dual GPLv2-BSD
<heat>
(dual = choose what you prefer)
<rnicholl1>
oh, I looked at that, but didn't use it because of the GPLv2 license. So I can just use it under the BSD license only?
<heat>
yes
inegatives has joined #osdev
gbowne1 has joined #osdev
<zid>
Or just it under the "you'll never catch me alive!" licence
<heat>
the cartoon villain license
<zid>
The democratic people's party of zid do not recognise your copyright.
ilovethinking has joined #osdev
rnicholl1 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
gdd has quit [Ping timeout: 264 seconds]
air has quit [Excess Flood]
air has joined #osdev
gdd has joined #osdev
ilovethinking has quit [Ping timeout: 248 seconds]
<zid>
bookworm time
* gog
fumigates the library
mahk has quit [Ping timeout: 268 seconds]
brunothedev has joined #osdev
<brunothedev>
anyone here have a good chatroom to ask about a good, cheap, ebook reader(pinenote is expensive)
<brunothedev>
i dont want to buy from amazon for obvious reasons
<bnchs>
brunothedev: bro
<bnchs>
just like... just use your laptop
<brunothedev>
bnchs: do you care about your eyes... also i have a desktop
<bnchs>
i don't
<brunothedev>
with a tv
<bnchs>
i got floaters for a year at this time
<bnchs>
at this point*
bauen1 has quit [Ping timeout: 265 seconds]
<brunothedev>
bnchs: what is floaters?
<brunothedev>
also looking at a white screen with black text for long period of time is painful
<bslsk05>
'Cruel To Be Kind' by Letters to Cleo - Topic (00:03:02)
<gog>
this movie sucked and i watched it a lot
<ilovethinking>
im tryingn to copy the code from the osdev wiki to set up long mode but the code is nasm and i don't know gas and it puts me into a deep hole of depression
<mrvn>
gog: people always say that about movies I liked
<heat>
have you tried not copying the code
Ali_A has quit [Ping timeout: 260 seconds]
<heat>
it might help out if you know what you're doing, just saying
<gog>
should i write a bootloader
<heat>
didn't you write an efi bootloader already
<gog>
oh yeah
<ilovethinking>
i don;t understnad the gdt part because my assembly knowledge is very bad, i just keep putting learning it properly away
<heat>
ok then fucking do it
<gog>
do you want long mode or do you want to learn to get there?
<ilovethinking>
i guess both
<gog>
you have to pick one for the moment
<ilovethinking>
is asmtutor a good source of learning asm? just by looking at it it seems like they skip a lot
<ilovethinking>
gog: well then learn, but specifically the gdt because idk how it's implemented
<brunothedev>
you can just learn about things by doing it, ex: i tried to sing using my breathing, list me a thing i wot do anymore
<ilovethinking>
i more or less understand how switching to long mode works in general
<ilovethinking>
brunothedev: ???
<brunothedev>
ilovethinking: i learned something by doin it
<gog>
the gdt stuff is really easiser than it looks
<ilovethinking>
nono i understand it
<ilovethinking>
but stupidly enough
<ilovethinking>
im stuck on the assembly part of it
<ilovethinking>
i suck at assembly
<gog>
the part where you're defining the structure or loading and jumping into protected mode?
<ilovethinking>
defining
<heat>
ok learn assembly
<ilovethinking>
the syntax itself
<ilovethinking>
eyah
<ilovethinking>
yeah i will
<heat>
come back after you know assembly
<ilovethinking>
for sure
<ilovethinking>
alright bro bet
<ilovethinking>
i rpomise personally to u heat
<heat>
until then any requests for help with return -1, errno = EAGAIN
<ilovethinking>
i won't come back till i know it]
<brunothedev>
the worst part about assembly is that i could make a assembler using the greenlandic language it would still be called "assembly", it is too lose of a definition
<heat>
s/with/will
ilovethinking has quit [Quit: WeeChat 3.8]
<gog>
kalaallisut
<gog>
pls
<brunothedev>
greenlandic is cool, just outside of my assembler
<gog>
samsetning
<heat>
does anyone know any fun literature on static verification of bytecode?
<brunothedev>
[any nordic, inuit and languages that uses accents(trust me)] is cool, just outside of my assembler
inegatives has quit [Quit: Ping timeout (120 seconds)]
<FireFly>
accents as in like, diacritics?
<bnchs>
hi FireFly
<FireFly>
hiya bnchs
<brunothedev>
yes, but i forgo the word and this is the most similar in portuguese
<gog>
what about cool and good letters like æ, ð and þ
<brunothedev>
gotta love old norse
<brunothedev>
the moment when you are a old island with no resources in the middle of the atlantic
<gog>
we have resources
<gog>
we have fish
<gog>
and uhhh
* moon-child
chomp
<lav>
you have gog
* gog
patpatpatpat lav
<gog>
heat: what do you use for freestanding c++ headers
<heat>
the cumpiler
<gog>
i do an inadvisable thing and -I/usr/include/c++
<heat>
the "freestanding" libc++ headers are more or less includeable
<heat>
although I really try not to
<heat>
most of my usage of that has been what, type_traits? something like that
<heat>
usually if I really want something STL-y I reimplement it
<gog>
oh
<heat>
like I reimplemented, atomics, vector, string, string_view, etc
<gog>
i don't remember this working before
<gog>
clang ships it
<heat>
ships what?
<gog>
when i do -ffreestanding and include <cstdint> it does the right thing
<heat>
yeah
<gog>
why do i think this didn't work before
<gog>
maybe it was another c++ experiment
<heat>
all of this is supposedly based on where the compiler is installed I believe, so --sysroot doesn't affect it
<gog>
yeah it was /usr/lib/clang/whatever
<gog>
this has to be when i was trying to do the same thing with gcc