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
<kazinsal> no, it's kuroko
<klange> It's *a* Python.
<theWeaver> it looks like a Python
<FireFly> oh you emsccripten'd kuroko
<klange> I emscripten'd kuroko a long time ago, it's been on the main page providing a tutorial since the first release.
<FireFly> heh
<bslsk05> ​kuroko-lang.github.io: Kuroko
<gog> kuroko is a better python
<gog> a faster and stronger python
<klange> I think 3.12 is beating me pretty handily now on runtime speed.
<gog> o
<gog> well
<kazinsal> it's a cooler python
<gog> yes
<FireFly> a python for cirno
<gog> cirno's favorite python
<bslsk05> ​'Was Doom an RTS or FPS?' by Necroware (00:21:14)
<gog> title card relevant to earlier discussion
ZombieChicken has joined #osdev
<ZombieChicken> Merry Christmas Eve
<gog> it's chrimbus here now
<gog> gleðileg jól!
<theWeaver> glaedelig jul!
<theWeaver> frohe Wienachten!
dutch has joined #osdev
ZipCPU has quit [Read error: Connection reset by peer]
ZipCPU has joined #osdev
<klange> gog: i tried to get through the shareware chapter while that video was playing but I only just made it to Computer Station after it ended
invalidopcode has quit [Remote host closed the connection]
invalidopcode has joined #osdev
<gog> nice
<gog> i'm eating mushroom paté
<kaichiuchi> i hate mushrooms.
<mats2> happy shwanza
<kaichiuchi> i seriously don't believe it
<kaichiuchi> I have no idea how people compile LLVM
<kaichiuchi> ninja ended up getting killed
<theWeaver> kaichiuchi: i think you have to use clang
<theWeaver> or rustc
<kaichiuchi> no I need a fucking EPYC system to do it apparently
<theWeaver> _OOF_
<kaichiuchi> (not literally)
<kaichiuchi> but it ends up slowing the system to a crawl before something gets killed
<kaichiuchi> and then it'll be fine, slow to a crawl
<kaichiuchi> and then it'll kill something else
<kaichiuchi> this time it just decided to commit suicide
<kaichiuchi> I hate C++
<heat> kaichiuchi, sup
<heat> you should use clang and lld to compile
<heat> it's a good chunk faster
<theWeaver> heat: hey don't tell them what they should
<heat> also don't forget to disable LTO
<heat> and limit threads
<moon-child> clang is fastest when compiled by clang, and gcc is fastest when compiled by gcc
<geist> the main issue i've seen when compiling llvm is LTO... oh yeah heat just said that too
<geist> the LTO link phases are *huge* and chew up tens of GB of ram
<heat> ThinLTO is bearable
<heat> LTO is bonkers
<heat> if you're doing something else while compiling llvm, 1) limits threads or 2) don't
<heat> s/limits/limit/
<\Test_User> or 3) add 1TB swap
<geist> yeah even that though means it might take like 15 hours. it can end up in a swap thrash
<heat> also if you want any sort of LTO, limit concurrent link jobs (the specific cmake var is documented somewhere)
<geist> one of the problems is their build system doesn't put links in a separate bucket, so if you compile with say -j8 or -j16 or whatnot it will happily try to link that many at a time
<heat> yeah and that makes sense when you're not using LTO
<geist> ninja does have a feature to create separate buckets, but it's i guess not wired up (last i checked)
<heat> they *do* have a feature like that
<heat> (they = LLVM)
<geist> ah but it's something you have to know how to set in cmake?
<bslsk05> ​github.com: toolchains/build_toolchain.sh at master · heatd/toolchains · GitHub
<heat> yes
<geist> ah good to know
<heat> if you don't limit them in any capacity in LTO runs you'll probably bring any google server down to its knees :)
<kaichiuchi> ok yes using clang definitely helped
<kaichiuchi> (in truth, I thought clang was passed)
epony has joined #osdev
<heat> llvm is a hard build but passing the right options certainly helps
<heat> - someone that has built llvm too many times
<heat> the really fucked up bits are build system changes, particularly when using the RUNTIMES features and all that
<heat> ninja stops working properly so you need to rm -rf build/ and remake everything again
<heat> it's NUTS
<kaichiuchi> I do need to make a `make_toolchain.sh` thing like you have
<kaichiuchi> well, I "want" to
<heat> feel free to steal
<heat> unless I relicense it GPLv3 and anti-tivoize your ass
<kaichiuchi> shrug
<heat> thou shalt make it possible to replace thine script
<heat> some days ago I learned that apple never updated bash because that old ass version was the last GPLv2 version
Burgundy has quit [Ping timeout: 260 seconds]
<kaichiuchi> I just want to be able to have something that I can either ship as a .zip like I do at work, or run a shell script
<heat> my script doesnt zip or tar anything but it's trivial to tack that on at the end
<kaichiuchi> indeed
<kaichiuchi> for funsies I tried to compile LLVM with full LTO
<kaichiuchi> as expected, a true disaster
PapaFrog has quit [Ping timeout: 265 seconds]
nanovad_ has joined #osdev
nanovad has quit [Ping timeout: 246 seconds]
nanovad_ is now known as nanovad
<zid> USE="lto" emerge -DuNv @world you say?
<kaichiuchi> i would never do that
<kaichiuchi> not unless I actually had an EPYC or something
<kaichiuchi> and by that I mean "a system that is well beyond anything I could want, or afford right now"
<zid> more cpu doesn't really help, it's just a binary "do you have enough ram free?"
<zid> if anything more cores makes it take longer becaue it's more likely to swap :P
<kaichiuchi> i'm not even sure how much RAM it would take for full LTO to actually work on LLVM
<zid> 32GB should be about right
gog has quit [Quit: byee]
<kaichiuchi> honestly, a part of me is tempted to splurge on a new PC even though I really don't need one
<zid> I just upgraded mine
<kaichiuchi> this will likely last another 6 years or so
<zid> new cpu and expanded the rams
<zid> Not bad for £50
<zid> 24GB of 800MHz -> 32GB of 933MHz, 4 cores -> 6 cores
<zid> and more more nasty numa domains
<moon-child> uma never got a song written about it
<zid> horses have loads of songs
PapaFrog has joined #osdev
<kaichiuchi> heat: by the way
<kaichiuchi> for christmas I set up a friend of mine with a minecraft server running freebsd
<kaichiuchi> what do you say to this
dutch has quit [Quit: WeeChat 3.7]
<zid> at last we found something that runs on freebsd
<heat> why is it not openbsd
<heat> also yeah zid has a good point
<kaichiuchi> it wasn't necessary
<heat> you're sharing mjg's test system now?
<kaichiuchi> it's a dumb minecraft server that will go away in 3 months because I'm not paying for it beyond that
<kaichiuchi> hey i used freebsd for a long time
spikeheron has joined #osdev
invalidopcode has quit [Remote host closed the connection]
invalidopcode has joined #osdev
<epony> and then you lost some hair and decided to implement your own linux
nanovad has quit [Quit: ZNC 1.7.5+deb4 - https://znc.in]
nanovad has joined #osdev
[itchychristmas] has quit [Ping timeout: 272 seconds]
elastic_dog has quit [Ping timeout: 265 seconds]
dude12312414 has joined #osdev
elastic_dog has joined #osdev
heat has quit [Ping timeout: 256 seconds]
invalidopcode has quit [Remote host closed the connection]
invalidopcode has joined #osdev
ZipCPU has quit [Ping timeout: 264 seconds]
jafarlihi has joined #osdev
<jafarlihi> When mounting a filesystem, a `struct mount` is passed to vfsops vfs_mount_t function. │ ASHER
<jafarlihi> │ | This struct contains `mnt_data` which is the private part of the filesystem. Each │ asmodai
<jafarlihi> │ | filesystem has a different structure for `mnt_data`. Now my question is, how does this │ azenla
<jafarlihi> │ | get populated? It is directly casted to specific FS structure as soon as it is in │ b3owulf
<jafarlihi> │ | vfs_mount_t, which is the first function that runs when FS is │ bahamat
<jafarlihi> │08:32:04 jafarlihi | mounted, so I'm not sure where this `mnt_data` is populated. Does mount utility do it
<jafarlihi> oops, sorry, wrong paste
ZipCPU has joined #osdev
<jafarlihi> Can someone please help me with FreeBSD? I'm trying to write a filesystem. When mounting a filesystem, a `struct mount` is passed to vfsops vfs_mount_t function. This struct contains `mnt_data` which is the private part of the filesystem. Each filesystem has a different structure for `mnt_data`. Now my question is, how does this get populated? It is directly casted to specific FS structure as soon
<jafarlihi> as it is in vfs_mount_t, which is the first function that runs when FS is mounted, so I'm not sure where this `mnt_data` is populated. Does mount utility do it?
<jafarlihi> correct paste
dude12312414 has quit [Quit: THE RAM IS TOO DAMN HIGH]
<kazinsal> in ext2_vfsops.c it gets assigned at line 943 in `static int ext2_mountfs(struct vnode *devvp, struct mount *mp)`
poisone has joined #osdev
<zid> kaichiuchi: my llvm failed to build
<zid> 1800 files in, didn't even give a useful error, just that column tracking had been supressed because the line was too long
<zid> time for a swapon
GeDaMo has joined #osdev
jimbzy has quit [Ping timeout: 260 seconds]
Turn_Left has joined #osdev
Left_Turn has quit [Ping timeout: 264 seconds]
<jafarlihi> kazinsal: That's exactly the issue, cast happens before the call the ext2_mountfs
<jafarlihi> s/the/to/
<jafarlihi> Isn't the vfs_mount_t the first function that runs?
<jafarlihi> How does it cast mnt_data and operate on it before it is assigned?
<jafarlihi> Oh, just noticed that happens only on MNT_UPDATE
<kazinsal> "...thus, the student was enlightened"
<kazinsal> I am not familiar with the freebsd source but when any unfamiliar source is involved or even a familiar one, I take the same approach to attempting to figure out how something works
<kazinsal> search for something I know is relevant, then mentally backtrace how it connects from there
<kazinsal> in the case of a large project like freebsd or linux there is a crossreference platform or six on the net that assists with that
<kazinsal> lxr/fxr are godsends
<jafarlihi> By the way, how useful do you find is ChatGPT for osdev?
<jafarlihi> It just returns really old vfs_mount_t signature
<kazinsal> never bothered. partially because AI + copyright = shitshow, but also because if I'm writing kernel code I want to actually be involved in whatever I'm writing
<kazinsal> GPT is a markov chain powered by GPUs and cognitive bias
<kazinsal> do not rely on it for anything of substance.
xenos1984 has quit [Ping timeout: 256 seconds]
xenos1984 has joined #osdev
<bslsk05> ​www.theregister.com: AI assistants help developers produce code that's insecure • The Register
<zid> well duh?
<kazinsal> as someone whose main programming outlet is in kernel space I would not ever trust an "AI" to do it right because 2022 AI is just 4chan posts funneled into a hackernews feed
<zid> by AI they mean NN ML, and that's just tweaking polynomials until they tween a sparse dataset nicely
<kazinsal> it is too stupid to be able to solve a problem in a fashion suitable for kernel space
<zid> it's lossy compression where you fuzz the unpacker alg and pack it with the data
<kazinsal> if an AI GPT jerkoff thing comes up with a solution to a problem that works 9999 times out of 10000 in user space it's fine
<kazinsal> because in that 1 time out of 10000 the orchestration platform will just kill the offending process and restart it
<zid> so like how an mpeg has fuck all visual data, and just re-creates it out of thin air by using carefully selected "this looks about right" info
<zid> it's not going to go all CSI "zoom in!" and invent detail that was never there, at best, it recreates the input data correctly
<kazinsal> AI programming is perfectly suited for docker kubernetes chef puppet bullshit
<zid> It's great for automating repetitive tasks with slight but predictable variation
<jafarlihi> It'll eat all the webdev jobs then 20% of those people will try to get into system programming and that's huge
<zid> "What comes next, 1 , 2, ???" me: "4" AI NN: "THREE, TWEEN COMPLETE, GOT THAT POLYNOMIAL DOWN PAT"
xenos1984 has quit [Ping timeout: 260 seconds]
<GeDaMo> "Why didn't you start at 0?" :P
<kazinsal> people who are wee osdev babbies assume that webdev is some kind of thing you can do one handed on e621 and three quarters into the best pint of a bottle of jackie d
<kazinsal> genuine webdev is actually kind of a nightmare because of the various modern web 2.1 frameworks that back everything and the half dozen languages that variously implement things
<kazinsal> osdev and webdev are different skillsets with different mental frameworks and different requirements of how you approach things
<kazinsal> they're both difficult but in different ways
<jafarlihi> idk i do modern webdev and it is pretty easy compared to this shite
<zid> I can't handle webdev
<zid> It's dynamic and broken and nothing works and everything changes every day and it's all fashion
<kazinsal> I have been at this long enough and I consider both of these two fields to be complex in their own ways
<jafarlihi> Not really, but pretty stable going with React
<jafarlihi> s/but/been
<zid> Imagine if you had to rewrite your kernel using a nightly version of Go 0.0.1 then rust 2 weeks later, then swift
<zid> and deal with all the "Well yea this just doesn't work yet/today" issues
<zid> that's webdev
<kazinsal> it's kind of like the differences between playing electric guitar and bass guitar
<zid> plus you know, it's all massively compounded by webdev stuff being "products"
<kazinsal> I use this allegory because I've been playing electric guitar for 20+ years and am now learning bass
<kazinsal> and also because I've been in the osdev space for 15 years and am passingly familiar with webdev
<jafarlihi> idk webdev is pretty chill in 2022
<zid> The actual coding is irrelevent, it's all business stuff, random features and workarounds, design changes, etc
<kazinsal> a lot of the fundamentals are similar but the way they integrate into all their surroundings and how you need to apply your work to meet those requirements are quite different
<GeDaMo> Job security! :P
<zid> Realities of webdev as per my webdev friends' constant rants: "WHy is this an XML message where every field in the xml is a json document, and each json document ultimately just encodes a URI where you fetch the actual data from?"
<zid> "Also \ is quadruple escaped"
<zid> "and it takes my tool 14 minutes to parse it"
<jafarlihi> Sounds like big corpo issues, we don't have that in a startup
<kazinsal> startups exist to be purchased by big corpos
<kazinsal> if you start a new company you are either doing it with the expectation that you are going to be bought out for 100x what you invested by someone else or because you are founding this with lottery winnings or the end result of your last successful startup
<jafarlihi> Do you know if struct mount *mp is supposed to be zero-filled when passed to vfs_mount_t? Cuz iso9660 module directly casts it to mnt_data without first populating it then ANDs and checks the MNT_UPDATE flag
<kazinsal> arguably a startup has a more precarious position because it needs to be able to make money out of nothing
<zid> startups often have this issue worse than anyone, because none of their tech even exists
<zid> hard to be mature when you're not even a thing
<jafarlihi> I have seen such XML bs in big corpo, in startups it is all about clean engineering from what I've seen
<kazinsal> I could classify my intent to be a cisco/juniper/extreme competitor as a startup but I do not have any of the prerequisites to do this, apart from the far distant fact where I know how data switching works at dozens of different levels
<jafarlihi> I've got CCNP, hire me part time?
<kazinsal> no, you've already failed the most important part of the interview
<jafarlihi> which part that is?
<kazinsal> arrogance
<jafarlihi> its just IRDC
<jafarlihi> IRC
<jafarlihi> I'll work for free till we make it
<kazinsal> another important part of tech spaces: assume someone who matters is watching
<kazinsal> and a more proletariat importance: your time is valuable
xenos1984 has joined #osdev
<jafarlihi> Here's my GitHub if anyone wants to hire me as an intern: https://github.com/jafarlihi
<bslsk05> ​github.com: jafarlihi (Hikmat Jafarli) · GitHub
<jafarlihi> I want to break into sys programming
* kof123 .oO( yes...yes, maxwell's demon is always watching...i'm afraid i can't let you do that )
ZombieChicken has quit [Remote host closed the connection]
poisone has quit [Ping timeout: 268 seconds]
wootehfoot has joined #osdev
Imk0tter has joined #osdev
terminalpusher has joined #osdev
poisone has joined #osdev
Imk0tter has quit [Remote host closed the connection]
ZipCPU_ has joined #osdev
ZipCPU has quit [Ping timeout: 248 seconds]
ZipCPU_ is now known as ZipCPU
jafarlihi has quit [Quit: WeeChat 3.6]
Burgundy has joined #osdev
ZipCPU has quit [Ping timeout: 272 seconds]
ZipCPU has joined #osdev
ZipCPU has quit [Ping timeout: 246 seconds]
ZipCPU has joined #osdev
ZipCPU has quit [Ping timeout: 252 seconds]
ZipCPU has joined #osdev
freemint has quit [Ping timeout: 265 seconds]
<Ermine> Merry Christmas!
* merry christmas
<Ermine> :D
ZipCPU has quit [Ping timeout: 246 seconds]
jafarlihi has joined #osdev
<jafarlihi> Hey. FreeBSD reads superblock of ext2 like this: bread(devvp, SBLOCK, SBSIZE, NOCRED, &bp). Now SBLOCK is defined as 2 and SBSIZE is defined as 1024. osdev wiki says ext2 superblock is always at byte offset 1024. Now I don't understand why SBLOCK is defined as 2, does this mean 2 * 512 (default block size?) = 1024?
ZipCPU has joined #osdev
epony has quit [Quit: QUIT]
ZipCPU has quit [Ping timeout: 265 seconds]
ZipCPU has joined #osdev
terminalpusher has quit [Remote host closed the connection]
terminalpusher has joined #osdev
<poisone> erry kristmass
ZipCPU has quit [Ping timeout: 248 seconds]
ckie has quit [Quit: *poof*]
ZipCPU has joined #osdev
gog has joined #osdev
Turn_Left has quit [Ping timeout: 264 seconds]
ZipCPU has quit [Ping timeout: 260 seconds]
ZipCPU has joined #osdev
jafarlihi has quit [Quit: WeeChat 3.6]
epony has joined #osdev
epony has quit [Ping timeout: 268 seconds]
pie_ has quit []
vancz has quit []
<gog> mewo
<Ermine> gog: may I pet you?
<gog> yes
* Ermine pets gog
* gog prrrr
<gog> god Jul
vancz has joined #osdev
pie_ has joined #osdev
poisone has quit [Ping timeout: 268 seconds]
ALowther has joined #osdev
<ALowther> Merry Christmas!!
<ALowther> Does anybody have any recommended article(s)/video(s) for implementing a file system?
bauen1 has quit [Ping timeout: 268 seconds]
sham1 has quit [Quit: WeeChat 3.5]
Left_Turn has joined #osdev
epony has joined #osdev
sham1 has joined #osdev
sham1 has quit [Client Quit]
<kaichiuchi> zid: mine failed to build for a different reason
<kaichiuchi> "The dependency target "cxx" of target "check-runtimes" does not exist."
<kaichiuchi> no idea what that means
ALowther has quit [Remote host closed the connection]
jimbzy has joined #osdev
sham1 has joined #osdev
<jimbzy> Happy Sunday!
<epony> infidel
<epony> don't detonate yourself
<kaichiuchi> huh
inegatives has joined #osdev
Matt|home has joined #osdev
<jimbzy> I prefer to be called a heretic, but it's alright.
<inegatives> The book says that there's a `block_run` structure with a `len` field, and `inode_addr` is basically a `block_run` structure with `len` field equal to 1. How do I represent/define this inode_addr type in C?
<Matt|home> happy holidays <3
<jimbzy> Cheers, Matt|home! XD
poisone has joined #osdev
<mats2> happy shwanza
<jimbzy> On this day we celebrate the birth of our savior, Rod Serling.
dude12312414 has joined #osdev
heat has joined #osdev
<heat> on this day I celebrate the birth of our lord and saviour zid
<jimbzy> All hail zid, all hail zid!
<kaichiuchi> on this day I celebrate beastie and curse tux
<jimbzy> Oh zid can you see, by the dawn's early light, what so proudly we hailed...
<kaichiuchi> merry christmas to all
<kaichiuchi> awesome, clang crashed
<kaichiuchi> I've never seen clang crash until today
<kaichiuchi> ironically, compiling LLVM
<kaichiuchi> heat: dong
<heat> hehehehehehehehe
<heat> donggggggggggggg
<inegatives> fuck christmas, archaic backwards cavemen bullshit
<kaichiuchi> when jesus is born, I get presents
<kaichiuchi> he dies, I get candy
<kaichiuchi> i'm cool with it
<heat> reject christmas, reject celebration, reject people, always work #grindset
<inegatives> you also have to give presents so it evens out
<inegatives> buy your own shit with your own money
<heat> you must be a really fun person
<inegatives> i  dont strive to be
<kaichiuchi> i'm not really religious, but I still celebrate christmas
<kaichiuchi> not for the religious aspect, but it's nice when people get together
<inegatives> thats religion-enabler behavior
<kaichiuchi> scrouge
<kaichiuchi> er, scrooge*
<kaichiuchi> i can respect people's beliefs
<inegatives> they dont respect yours though
<inegatives> infidel
<heat> noooooooooooooooo dont respect people
<kaichiuchi> what, you think everyone here in this channel is irreligious?
<inegatives> better be
<inegatives> otherwise what the hell are you even doing here lol
<kaichiuchi> um
<heat> developing operating systems
<inegatives> go worship some fart of stone age men, why you need an os
<heat> and going on bants with zid
<kaichiuchi> i'm not even sure what's going on at this point
<kaichiuchi> but okay
<kaichiuchi> i will continue fucking with heat
<heat> sortie, hammer time?
<heat> kaichiuchi: dong
<kaichiuchi> hey you wanna buy me a threadripper for christmas?
<heat> no
<kaichiuchi> why not
<kaichiuchi> it's only $7000
<heat> because you were going to buy me one
<kaichiuchi> ah.
<kaichiuchi> you caught me
<kaichiuchi> I wonder how fast LLVM would've compiled with a threadripper and 128GB of RAM
<heat> non-LTO? very
<heat> some minutes
<heat> 4 or something? around that
<heat> I remember we benched that with doug16k
<inegatives> i have threadripper and it takes 12 minutes
<kaichiuchi> i'm on a 3800X
<kaichiuchi> unfortunately I'm still 18 years old at heart and want the latest and greatest shit all of the time no matter what the cost
<inegatives> i used to download latest versions of adobe acrobat with 56kbps even though i didnt read single pdf, i just wanted the latest and greatest software
<kaichiuchi> but there's no way I can spend $7k on a CPU
<kaichiuchi> maybe if I was running gentoo
<kaichiuchi> or something
<inegatives> apple faglets spend 7k on 10% of threadripper performance
<kaichiuchi> i have a macbook
<kaichiuchi> what does that say about me
<inegatives> that you dont have a good taste
* kaichiuchi shrugs
<kaichiuchi> it works for me
<theWeaver> let's dispense with the homophobic slurs shall we
<kaichiuchi> that too
<inegatives> sorry
xenos1984 has quit [Read error: Connection reset by peer]
<kaichiuchi> heat: what the fuck? you have to build libcxx?
<kaichiuchi> actually I think the correct command is: cmake -G "Ninja" -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/home/kaichiuchi/arfpgbe-clang-toolchain -DLLVM_ENABLE_PROJECTS="clang;lldb;lld;openmp;clang-tools-extra" -DLLVM_ENABLE_RUNTIMES="compiler-rt;libunwind" -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_C_COMPILER=clang ../llvm
<kaichiuchi> i think you don't actually need libcxxabi
<kaichiuchi> or even libunwind
<Ermine> I don't even have Christmas today :D
<kaichiuchi> yeah I think I should just include libunwind
xenos1984 has joined #osdev
wootehfoot has quit [Ping timeout: 264 seconds]
<heat> kaichiuchi, you = who?
<heat> me? yes. you? maybe? I don't know what you're doing
inegatives has left #osdev [#osdev]
<kaichiuchi> the official answer I got was: "It is used as the low level unwinder implementation, primarily for C++ implementations using the Itanium ABI.
<kaichiuchi> If you're not using a language making use of those exception handling capabilities, it's not required."
<kaichiuchi> and that's not me
<heat> I was talking about libcxx
<kaichiuchi> oh
<kaichiuchi> yeah I don't need it, it looks like LLVM's own flavor of the standard library
<kaichiuchi> which I don't need
<heat> sure
<heat> you may need compiler-rt and libunwind though
<kaichiuchi> compiler-rt yes
<kaichiuchi> libunwind I'm not using exceptions at all
<kaichiuchi> so I don't see why I'd need it
<heat> you don't have a complete libgcc implementation without libunwind
<kaichiuchi> oh.
<heat> glibc for instance does use _Unwind functions for backtrace(3)
<kaichiuchi> makes sense
xenos1984 has quit [Ping timeout: 248 seconds]
xenos1984 has joined #osdev
xenos1984 has quit [Ping timeout: 260 seconds]
dude12312414 has quit [Quit: THE RAM IS TOO DAMN HIGH]
xenos1984 has joined #osdev
Turn_Left has joined #osdev
Left_Turn has quit [Ping timeout: 265 seconds]
GeDaMo has quit [Quit: That's it, you people have stood in my way long enough! I'm going to clown college!]
<bslsk05> ​'Critical Program Reading (1975) - 16mm Film' by Technology Connextras (00:17:50)
<clever> and dont forget the main channel vid, on analog audio in film!
<FireFly> I watched the main-channel video, really cool :o
<FireFly> (as usual for TC :p)
<zid> yea I watched the main vid earlier, but was super interested in what the hell this was
<zid> glad he uploaded it
<clever> did he nerd snipe you with those clips? :D
<geist> heh yeah same here
gildasio has quit [Remote host closed the connection]
foudfou_ has quit [Write error: Connection reset by peer]
gxt has quit [Read error: Connection reset by peer]
foudfou has joined #osdev
gxt has joined #osdev
<zid> I'm unfortunately all out of flow diagrams :(
gildasio has joined #osdev
<kof123> its time to code and make flow charts, and im all out of flow charts
<zid> Wish they'd indent that else
<zid> they did it for the if
nick64 has joined #osdev
<geist> yeah right?
<kaichiuchi> it is so fucking cold
<kaichiuchi> and only now was I allowed to turn on my space heater
<zid> we had some cold weather last week, but it's 8C now just to confirm no white christmas
<geist> same. it warmed up yesterday and all the snow melted and now it's just rainy and above freezing
<geist> which is really fine. now i can get out and do stuff
<moon-child> gog: https://files.catbox.moe/hn75eu.jpg this u?
invalidopcode has quit [Read error: Connection reset by peer]
invalidopcode has joined #osdev
<zid> doesn't look like shark girl, hmm
scripted has joined #osdev
<scripted> Hello!
<moon-child> hmm? She's chomping the fishy
<scripted> So I just implemented paging in my kernel, but it's causing a boot loop. So I opened up gdb and debugged the init_paging function, and the loop never starts, which probably is why its causing a boot loop. I have looked at the linker script but the variables KERNEL_START and KERNEL_END seem to be linked fine. Any ideas? https://github.com/ScriptedDeveloper/CrazeOS/blob/unstable/src/paging/paging.c
<bslsk05> ​github.com: CrazeOS/paging.c at unstable · ScriptedDeveloper/CrazeOS · GitHub
<kaichiuchi> hehe, boot loop
<heat> scripted, qemu -d int
<zid> -d int,nochain -S -s -no-shutdown -no-reboot for life
<scripted> ok let me check
<zid> you know that's a piss take because lettuce truss is on there
<heat> who's bottom left?
<zid> 'uncle tom'
<zid> no wait
<zid> 'major tom'
<zid> uncle tom is the racist thing
<heat> lol
<scripted> this is what i got
<scripted> it seems to repeat itself
<zid> I'm building gcc with -j so my mouse is having a good old time ice-skating
<heat> scripted, thou hast a page fault
<heat> thine paging ist fucked
<zid> tps://i.redd.it/ifph3cy5r28a1.jpg
<zid> [21:32] <scripted> ok
<scripted> heat : why isnt it detected by my isr
<zid> okay I lost a ctrl-c there
<zid> Servicing hardware INT=0x08
<zid> check_exception old: 0xffffffff new 0xe
<zid> 30: v=0e e=0000 i=0 cpl=0 IP=0008:000000000030155c pc=000000000030155c SP=0010:000000000050bfa8 CR2=000000000030155c
<heat> scripted, maybe your isr is also not mapped :)
<scripted> hold on
<scripted> it worked before
<scripted> but that was half a year ago
<heat> 0x30155c isn't mapped
<heat> as you can see per CR2 and IP
<scripted> okay well
<zid> (and e=0 means it wasn't selector related)
<scripted> is it because the loop never starts?
<zid> It's because it isn't mapped.
<scripted> gdb giving me 0 values for kernel_start and kernel_end too
<scripted> oh
<heat> zid, e=0 only has meaning for GPFs
<heat> this a page fault
<heat> scripted, no.
<zid> heat: It's still factual.
<heat> you should mean &kernel_end
<scripted> ok
<zid> Okay we're creeping back towards the part where gcc failed earlier
<zid> I recognise this warning!
<zid> vec[1] may be used uninitialized in rtx vec[3]
justmatt has joined #osdev
scripted has quit [Quit: WeeChat 3.7.1]
<kaichiuchi> ok so my "toolchain" is 4.4GB
<heat> did you strip it?
<heat> 985M /data/toolchains/onyx-llvm/
<kaichiuchi> no I didn't strip anything
<heat> strippppppppppp it
<kaichiuchi> fuck I don't remember how to do it recursively
<zid> I am -o cc1'ing
<heat> llvm has ninja distribution and ninja install-distribution-stripped
<zid> find . | xargs strip
<zid> or find . -exec strip {} \;
<zid> bonus points: check for +x first :P
<heat> all of that sucks
<heat> find "$PKGDIR/usr/bin" -type f -exec sh -c '(! echo {} | grep -q .*.o) && (file {} | grep -q ELF)' \; -exec $STRIP {} \; || true
<heat> I do this on usr/bin, usr/lib, usr/libexec
<zid> I build splitdebug
<kaichiuchi> I just ran it on my entire directory
<kaichiuchi> 3.7GB now
<zid> in the first place
<kaichiuchi> but I also have other stuff
<heat> this still sucks
<heat> ok how many targets are you building and why
<zid> -o cc1 uses approx 8GB of memory.
<kaichiuchi> [kaichiuchi@megingjord arfpgbe-linux-toolchain]$ ls
<kaichiuchi> that's all I have man
<kaichiuchi> benchmark cmake git llvm ninja
<kaichiuchi> wait a minute
<kaichiuchi> a) why did that paste twice
<kaichiuchi> b) I didn't know I can choose what clang supports
<heat> it didn't
<kaichiuchi> I thought clang was "yes, I have everything, and there is nothing you can do about it"
<heat> negative
<kaichiuchi> see this is why I need you
<kaichiuchi> WHAT
<kaichiuchi> ...that's even in the manual
<kaichiuchi> god
<kaichiuchi> what's wrong with me
<heat> many things
<kaichiuchi> and what's this stripped distribution thing you're talking about
<heat> in any case I don't expect that to be your problem
<heat> can you like paste your du -smh on the llvm directory
<kaichiuchi> that I see absolutely nowhere
<heat> ninja distribution
<heat> DESTDIR=$target_dir ninja install-distribution-stripped
<heat> this is documented $somewhere
<kaichiuchi> I hate this
<kaichiuchi> god
<zid> does it have splitdebug
<heat> llvm's build system sucks
<heat> oh yeah btw make sure you're making a release build
<heat> debug builds take like twice as long
<zid> my VM has seized up heat
<zid> how I fix
<heat> sudo kill -9 1
<zid> >siezed
<zid> sizeid
<zid> how I type
<heat> get keyboard
<zid> I click for focus, but then nothing the happen
<zid> at least the amount of memory vmware is using is changing, even if it is using 0 cpu
<kaichiuchi> well of course I used the release build
<heat> >vmware
<heat> that's your issue
<heat> kaichiuchi, give du of directory things
<heat> thanks*
<kaichiuchi> it's 3.7GB
<heat> idk how I typed things, very gangsta of me
<kaichiuchi> i'm just going to build it again
<heat> kaichiuchi, the individual directories poopy mcpoopyface
<kaichiuchi> too late I nuked it
<heat> gj
<heat> i hope you understand the build will not be that much faster
<kaichiuchi> I assume I'll want to say x86_64
<zid> okay it's not totally broken, I got the mouse to move
<kaichiuchi> because X86 almost certainly doesn't have x86_64 included
<heat> it does
<kaichiuchi> what the _fuck_
<kaichiuchi> okay
<kaichiuchi> cmake -G "Ninja" -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/home/kaichiuchi/arfpgbe-linux-toolchain/llvm -DLLVM_ENABLE_PROJECTS="clang;lldb;lld;openmp;clang-tools-extra" -DLLVM_ENABLE_RUNTIMES="compiler-rt;libunwind" -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_C_COMPILER=clang ../llvm -DLLVM_TARGETS_TO_BUILD="X86"
<kaichiuchi> does that look good
<zid> targets to build change to alpha
<heat> do you need lldb and clang-tools-extra?
<kaichiuchi> yes
<heat> ya sure
<heat> ?
<kaichiuchi> sweet thanks
<heat> no
<heat> wait
<kaichiuchi> the fuck do you mean wait
<kaichiuchi> and it shouldn't be
<heat> tough shit this is cmake
<heat> real men use real tools like cmake
<heat> to make real products
<heat> oops, -DCMAKE_*
<kaichiuchi> ok
<heat> CMAKE_C_FLAGS and CMAKE_CXX_FLAGS should have -fuse-ld=lld for quicker linking
<kaichiuchi> cmake -G "Ninja" -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/home/kaichiuchi/arfpgbe-linux-toolchain/llvm -DLLVM_ENABLE_PROJECTS="clang;lldb;lld;openmp;clang-tools-extra" -DLLVM_ENABLE_RUNTIMES="compiler-rt;libunwind" -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_C_COMPILER=clang -DCMAKE_ASM_COMPILER=clang ../llvm -DLLVM_TARGETS_TO_BUILD="X86" -DLLVM_DEFAULT_TARGET_TRIPLE=x86_64-pc-linux-gnu -DCMAKE_C_FLAGS="-fuse-ld=lld"
<kaichiuchi> -DCMAKE_CXX_FLAGS="-fuse-ld=lld"
<kaichiuchi> please tell me that's correct before I cry
<kaichiuchi> :(
<heat> looks a-ok
<kaichiuchi> good
<heat> ninja and ninja install
<heat> I think distribution needs more set up
<kaichiuchi> .
<kaichiuchi> clang-14: warning: argument unused during compilation: '-fuse-ld=lld' [-Wunused-command-line-argument]
<kaichiuchi> [2/2] Linking C executable cmTC_dfe3c
<kaichiuchi> blows up
<heat> do you have lld installed?
<kaichiuchi> pretty sure
<heat> WAIT LOL
<kaichiuchi> i'm waiting
<heat> does -DLDFLAGS="-fuse-ld=lld" work?
<kaichiuchi> no I didn't have lld installed
<kaichiuchi> yes that worked
<heat> fuse-ld=lld will be unused in compilation so that can't/shouldn't be in cflags
<kaichiuchi> no it didn't work
<kaichiuchi> CMake Warning:
<kaichiuchi> Manually-specified variables were not used by the project:
<kaichiuchi> LDFLAGS
<kaichiuchi> at this point I don't care
<kaichiuchi> the linker taking its sweet ass time isn't a big deal
<heat> does it work if you pass it in the environment?
<heat> yes it is
<heat> shut up
<kaichiuchi> .
<zid> why is it building this file again, I've already seen this warning :(
<heat> zid, what are you building
<zid> cc1
<kaichiuchi> rebuilding
<kaichiuchi> I cannot believe this shit is actually this annoying
<heat> zid, why
<zid> cus I wanted my gcc to have lto and I got NEW RAM since I last built gcc
<kaichiuchi> okay so
<kaichiuchi> LDFLAGS=-fuse-ld=lld cmake -G "Ninja" -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/home/kaichiuchi/arfpgbe-linux-toolchain/llvm -DLLVM_ENABLE_PROJECTS="clang;polly;lldb;lld;openmp;clang-tools-extra" -DLLVM_ENABLE_RUNTIMES="compiler-rt;libunwind" -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_C_COMPILER=clang -DCMAKE_ASM_COMPILER=clang ../llvm -DLLVM_TARGETS_TO_BUILD="X86" -DLLVM_DEFAULT_TARGET_TRIPLE=x86_64-pc-linux-gnu
<zid> so now it might not actually be unpossible
<kaichiuchi> this worked
<heat> kaichiuchi, sweetie I've done that dozens of times WHILE PATCHING
<heat> it's depressing
<heat> on a fucking laptop btw
<heat> this is ULP, best I can get for a build is 40-50 minutes
<kaichiuchi> i really hope you're lying to me that the stripped distribution requires setup
<heat> I'm not I think?
<kaichiuchi> well i'm going to try it anyway because fuck you
<gog> nya
<heat> hacking on the runtimes stuff is very fun because it builds the whole toolchain before configuring the projects again and building those
* kazinsal headpats gog
<heat> the incremental bit of the build doesn't work there
* gog pr
<kaichiuchi> ok only 5,916 files to build this time
<heat> this is google gog, we use CLs
<gog> no
<zid> No this is patrick
<heat> hola patrick, yo soy el jefe de gog
<zid> I think I ust got called a soy boy
<zid> named jeff
<zid> of gog
terminalpusher has quit [Remote host closed the connection]
<gog> my boss is luis and he's in ibiza rn sorry
<zid> he flew over heat, I hope he waved
<gog> i hope he doesn't take a pill there
<zid> he's going to ride the vengabus
dude12312414 has joined #osdev
Burgundy has quit [Ping timeout: 265 seconds]
<zid> >>> Installing (1 of 1) sys-devel/gcc
<zid> we did it boys
<heat> I didn't quite understand, did you LTO gcc itself?
<zid> yea
<heat> pog
<heat> i've been meaning to do that
<zid> should I reinstall it and see if it seems quicker
<kaichiuchi> question
<kaichiuchi> google of course, is giving me conflicting answers
<kaichiuchi> can I define my own build type in CMake
<kaichiuchi> please I hate CMake I just want answers
<heat> i don't think so
<heat> but maybe? I'm not cmake expert
<kaichiuchi> people always tell me "don't add flags! CMake knows better than you!!!"
<kaichiuchi> no it fucking does NOT.
<zid> it just replaces fiddling with flags with fiddling with cmake
bauen1 has joined #osdev
dh` has quit [Ping timeout: 272 seconds]
<heat> zid, was your LTO gcc build just forcing -flto in CFLAGS and CXXFLAGS?
<zid> idk, gentoo supports it
gog is now known as pog
<zid> USE="lto -fortran" emerge sys-devel/gcc
<kaichiuchi> [kaichiuchi@megingjord build]$ ninja install-distribution-stripped
<kaichiuchi> ninja: no work to do.
<kaichiuchi> nice.
<heat> yeah no doesn't work then lol
<heat> ninja install baby!1111111!!!!1111111
<kaichiuchi> done and now i'm sad again
<heat> du -smh
<kaichiuchi> this time i'm at 2.8GB for the entire toolchain
<kaichiuchi> something I must clarify, by "toolchain" I'm including things other than LLVM
<kaichiuchi> [kaichiuchi@megingjord arfpgbe-linux-toolchain]$ du -smh
<heat> how does LLVM look?
<kaichiuchi> 2.9G .
<kaichiuchi> i don't know what you mean by that, if you mean using that command
<kaichiuchi> [kaichiuchi@megingjord llvm]$ du -smh
<kaichiuchi> 2.8G .
<zid> disk usage? smh.
<heat> wtf
<heat> du -smh * inside llvm
<kaichiuchi> [kaichiuchi@megingjord llvm]$ du -smh *
<kaichiuchi> 2.0G bin
<kaichiuchi> 758M lib
<kaichiuchi> 48K libexec
<kaichiuchi> 53M include
<kaichiuchi> 272K share
<heat> what
<kaichiuchi> the fuck do you mean what
<heat> why are your things that big?
<kaichiuchi> ;)
<kaichiuchi> i dunno.
<heat> make a gist with the du -smh of bin and lib
bgs has quit [Remote host closed the connection]
<kaichiuchi> https://termbin.com/4r7q - bin
<kaichiuchi> https://termbin.com/8rdn - lib
<zid> My entire gcc binary is 924kB
<zid> That's a lot smaller than I thought
<pog> that's the frontend
<zid> lto-dump is 34M :P
<zid> cc1 35M, cc1plus 38M, lto1 34M
<kaichiuchi> heat: help!
<heat> kaichiuchi, you're installing like literally every llvm tool
<heat> >du -smh /data/toolchains/onyx-llvm/bin/* | wc -l
<heat> 41
<kaichiuchi> what the fuck am I supposed to do
<zid> what's clang called
<zid> clang?
<kaichiuchi> i can’t control that with any granularity
<heat> you can
<kaichiuchi> how?
<zid> I have some kind of llvm, it has an assembler
<zid> not sure it has a C compiler
<kaichiuchi> there’s nothing obvious anywhere that shows me how to say “i literally just want to compile”
<heat> use that + install-distribution-stripped
<zid> hetakuso
<kaichiuchi> lord almighty
<pog> bless you
<kaichiuchi> so the actual command is something like
<zid> cd gcc; ./configure --target=x86_64 && make
<kaichiuchi> LDFLAGS=-fuse-ld=lld cmake -G "Ninja" -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/home/kaichiuchi/arfpgbe-linux-toolchain/llvm -DLLVM_ENABLE_PROJECTS="clang;polly;lldb;lld;openmp;clang-tools-extra" -DLLVM_ENABLE_RUNTIMES="compiler-rt;libunwind" -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_C_COMPILER=clang -DCMAKE_ASM_COMPILER=clang ../llvm -DLLVM_TARGETS_TO_BUILD="X86" -DLLVM_DEFAULT_TARGET_TRIPLE=x86_64-pc-linux-gnu
<kaichiuchi> DLLVM_DISTRIBUTION_COMPONENTS="clang;lldb" or something
<heat> yes
<heat> wait you can skip DISTRIBUTION_COMPONENTS if you use INSTALL_TOOLCHAIN_ONLY I think
<kaichiuchi> goodness
<kaichiuchi> okay
<kaichiuchi> this should not be this hard
<kaichiuchi> i’m going to go eat christmas dinner and hopefully things will work
<zid> Humans. Everyone. I'll show them all the REAL meaning of this world.
<epony> you can't
poisone has quit [Read error: Connection reset by peer]
terminalpusher has joined #osdev
<pog> mew
<heat> pog
<pog> heat
<kaichiuchi> take the plunge
<kaichiuchi> of remembrance, of learning
<heat> pog, baz
<kaichiuchi> ok
<kaichiuchi> heat: the build is done
<kaichiuchi> [kaichiuchi@megingjord build]$ ninja install-distribution-stripped
<kaichiuchi> ninja: no work to do.
<kaichiuchi> explain yourself
<heat> ninja install mate
<kaichiuchi> but... where does install-distribution-stripped come in
<kaichiuchi> after that?
<heat> it doesn't
<kaichiuchi> what..
<heat> RELEASE means everything should be stripped
<kaichiuchi> oh
<heat> install should only install toolchain stuff I think
wootehfoot has joined #osdev
<kaichiuchi> ok this is looking a metric fuckton better
<heat> if it's not feel free to send the build logs to idontcare@cockmungers.co.uk
<kaichiuchi> 1.6G now
<heat> how that du lookin
<kaichiuchi> [kaichiuchi@megingjord llvm]$ du -smh *
<kaichiuchi> 1.4G bin
<kaichiuchi> 286M lib
<kaichiuchi> 48K libexec
<kaichiuchi> 376K include
<kaichiuchi> 268K share
<heat> bin still looks fucken thicc
<kaichiuchi> well I have other stuff that you probably don't have
<kaichiuchi> -DLLVM_ENABLE_PROJECTS="clang;polly;lldb;lld;openmp;clang-tools-extra" -DLLVM_ENABLE_RUNTIMES="compiler-rt;libunwind"
<heat> correct but mine is half of that
<heat> I have clang, clang tools, llvm tools, lld
<kaichiuchi> i don't even know what llvm tools are
<heat> I doubt lldb polly and openmp make up 700MB
<kaichiuchi> shit like llvm-mca?
<heat> llvm-strip, llvm-size, blah blah
<kaichiuchi> oh
<kaichiuchi> https://termbin.com/9g37t - bin
<kaichiuchi> https://termbin.com/vxrmo - lib
<zid> yea but MEM[(struct case_info *)newmem_241].bb may be used unitialized
<heat> kaichiuchi, seems to include a bunch of other shit but looks good to me otherwise
<kaichiuchi> well that's an LLVM issue and not mine so it can suck a cock
<zid> or MEM[(struct poly_int *)&save].D.6971.coeffs[0]