Search logs:

channel logs for 2004 - 2010 are archived at ·· can't be searched

#osdev2 = #osdev @ Libera from 23may2021 to present

#osdev @ OPN/FreeNode from 3apr2001 to 23may2021

all other channels are on OPN/FreeNode from 2004 to present

Wednesday, 25 January 2023

01:17:00 <ornx> what's the best hardware timer to use on amd64? (apic, hpet, tsc(?? can this generate interrupts?), regular pic, rtc, ...)
01:18:00 <Mutabah> HPET probably, but does depend on what you need the timer for
01:19:00 <klange> tsc if you're on hardware where it's "reliable", hpet otherwise, and those two are generally synchronized to each other.
01:20:00 <klange> I use apic timers / pit for simple periodic signalling to force task switches because I don't care, I abuse TSC times for everything else, and I claim a minimum hardware requirement of Nehalem since that's when reliable tsc became the norm.
01:21:00 <klange> and my clock is completely broken in bochs :)
01:22:00 <ornx> i only care about recent hardware so TSC might be best, since it seems to have lowest overhead
01:22:00 <ornx> (intended use is scheduling)
01:23:00 <klange> If you want interrupts out of the TSC, APIC timers can be set to "TSC deadline" modes.
04:17:00 <mctpyt> hello
04:42:00 <sham1> Hello
14:19:00 <kaichiuchi> hi
14:22:00 <immibis> hi
14:23:00 <sham1> lo
14:25:00 <immibis> off-topic reminder: capitalism is fascism justified with spreadsheets
14:27:00 <sham1> For certain values of "capitalism" and "fascism"
14:27:00 <sham1> And "spreadsheet"
14:28:00 <immibis> for their usual values
14:33:00 <immibis> nothing that the usual value of capitalism is not "free markets", the usual value of fascism is not Auschwitz, and not all spreadsheets are made in Excel
14:33:00 <immibis> Noting*
16:40:00 <Jari--_> Migraines panic attacks over, so I was thinking I could finish my runtime dynamic loader / dynamic linker
16:41:00 <Jari--_> It helps a lot to understand the code you do borrow, avoiding doing mistakes.
16:42:00 <Jari--_> So basically it is the relocation tab, and there are ASCII symbols pointing to them, you walk through the binary dynamic area and dang you got a static binary in the memory allocated by the kmalloc (or whatever you do call it).
16:43:00 <Jari--_> I would like to have aid on this, a good example for dynamic loader, I was thinking about an OSDEV project with a working loader, to avoid doing the mistakes 10s 100s others do writing it from the scratch.
16:43:00 <Jari--_> No library support needed
16:44:00 <Jari--_>
16:44:00 <bslsk05> ​alexdboxall/ATOS - ATOS is an operating system inspired by OS/161. It is designed to be lightweight and easy to understand. Currently implemented for x86, but should be easy to port to other platforms. (0 forks/5 stargazers/BSD-3-Clause)
16:44:00 <Jari--_> I am looking at this
16:47:00 <Jari--_> cant find a linker
16:50:00 <Jari--_> Execution Loader
16:55:00 <mjg> spinlock_acquire(&node->reference_count_lock);
16:56:00 <mjg> oh noes
17:12:00 <kaichiuchi> mjg: i’m going to get a truenas
17:12:00 <kaichiuchi> you might be thinking “ok” but what I really want is your blessing
17:12:00 * kaichiuchi wait
17:13:00 <mjg> kaichiuchi: truenas is moved to linux i think
17:13:00 <kaichiuchi> no not entirely
17:14:00 <zid`> what's that spanish for, mjg?
17:15:00 <mjg> you can feel blessed to use any bsd or linux you see fit
17:15:00 <mjg> oh huh
17:15:00 <mjg> x86 asm: Replace .align with .balign
17:15:00 <mjg> The .align directive used to align storage locations is
17:15:00 <mjg> on others the argument is interpreted as a shift value. The current
17:15:00 <mjg> usage expects the first interpretation.
17:15:00 <mjg> ambiguous. On some platforms and assemblers it takes a byte count,
17:15:00 <mjg> TIL
17:15:00 <zid`> oopsie, did someone align to 2^4 instead of 4
17:18:00 <froggey> always .balign or .p2align, never .align
17:18:00 <mjg> never even .align!
17:19:00 <mjg> there is this funny idea that computers are fast bro, therefore no need to optimize anything
17:22:00 <geist> sometimes you gotta. but i 100% agree with the balign thing
17:22:00 <geist> since it's ambiguous of it's byte or shift
17:23:00 <mjg> i did not know it is ambiguous
17:23:00 <mjg> good thing everytihng is well defined, innit
17:23:00 <geist> it's just different arches define their .align to mean different things, is all
17:24:00 <mrvn> But I do want to align my data to a 2^4096 boundary.
17:25:00 <mjg> heh, i have to say the sometimes seen changelogs on top of files
17:25:00 <mjg> are kind of amusing
17:25:00 <mjg> i wonder why nobody whacked them
17:25:00 <mjg> is this seen as part of copyright perhaps?
17:26:00 <mjg> * Start bdflush() with kernel_thread not syscall - Paul Gortmaker, 12/95
17:35:00 <geist> i guess the other question is why whack them? it's basically a historical artifact
17:37:00 <mjg> to not teach people to ignore comments
17:39:00 <marshmallow> might sound stupid, but when on linux I launch the browser, who's actually invoking fork()+exec() to spawn an instance of the browser?
17:40:00 <mjg> i guess depends how you spawn the browser
17:40:00 <mjg> pstree may be able to tell you
17:40:00 <mjg> note though if the parent is systemd then the real thing was something else
17:43:00 <marshmallow> systemd invokes the kernel which spawns the browser?
17:44:00 <marshmallow> uhmm OK should make sense
17:45:00 <geist> marshmallow: if it's a modern browser it probably has a process per tab, in which case theres *probably* a main control process in your stack of firefox/chrome/etc processes
17:45:00 <geist> it gets the 'create new tab/window' message from the gui process, spawns a new one, sets up all the IPC between it so it can share graphics bits, and then that process runs that tab
17:46:00 <geist> otherwise if you mean the first time it's started, probably depends on how you start it
17:46:00 <geist> if you run it on the command line, it's probably ust running like any other program
17:46:00 <marshmallow> sure, no doubt about it, probably like a process for each renderer (gpu, ui, etc...)
17:47:00 <geist> if you click on an icon it'll be whatever your window manager/environment shell does, but probably same. probably not involving systemd
17:47:00 <geist> yeah
17:47:00 <marshmallow> oh OK, so the window manager may invoke fork for the browser when clicking on an icon
17:48:00 <geist> yah
17:48:00 <marshmallow> if on CLI, possibly systemd?
17:48:00 <geist> folks may nitpick if it's a window manager or it's part of a desktop environembt, etc
17:48:00 <geist> cli it's probably just the shell
17:48:00 <mrvn> the WM might just tell dbus
17:48:00 <geist> i seriously double systemd would be involved in starting a process like that
17:48:00 <geist> s/double/doubt
17:49:00 <mrvn> geist: systemd --user?
17:49:00 <geist> maybe, i guess i dunno how that part of systemd works
17:49:00 <geist> but still seems that's mostly for per user services, like pulseaudio, or something
17:49:00 <geist> or a per user dbus or whatnot
17:49:00 <mrvn> s/that part of// and the answer is "badly"
17:49:00 <geist> a browser is still an app in this 'click on it' context
17:50:00 <mrvn> geist: yes and now. Because the second time you click it just tells the first instance to open a new tab. So it's kind of a service too
17:50:00 <mrvn> -w
17:50:00 * geist shrugs
17:51:00 <mrvn> my firefox is started from a terminal. I don't do the icon thing.
17:51:00 <geist> i'd like to think the model is still mostly: there's a gui shell you're interacting with that's largely directly spawning an instance of the program the link refers to
17:51:00 <geist> ie, explorer.exe on windows, or whatever your gui shell is on linux (gnome, kde, whatever)
17:52:00 <geist> but yeah it could send a dbus message to something else which starts it, etc
17:52:00 <mrvn> one could just look at the desktop file behind the icon to see what it starts
17:55:00 <mjg> so looking at pstree on my laptop show stuff for me to remove
17:55:00 <mjg> like cups
17:56:00 <mjg> what on earth is mbim-proxy
17:56:00 <geist> OH NO DONT TOUCH THA....
17:57:00 <mjg> The following packages will be REMOVED: fwupd fwupdate libmbim-proxy libqmi-glib5 libqmi-proxy modemmanager
17:57:00 <mjg> now fwupd makes me worried
17:58:00 <geist> yeah i have manually removed modemmanager on a few of my ubuntu boxes. definitely something i dont need that sits around and futzes with things
17:58:00 <mjg> bluetoothd
17:58:00 <mjg> looks ilke i got tons of cleanup to do here
17:58:00 <geist> if you're not using bluetooth, sure
17:58:00 <mjg> ye
17:58:00 <mjg> i only got 12G of ram
17:59:00 <mjg> and lollerfox eats vast majority of it
17:59:00 <geist> gosh yeah you better get rid of those services before your shell stops working
17:59:00 <geist> happiness is a clean unix install with like a shell and one process
18:00:00 <mjg> dude 2 free megs of ram are a difference between smooth sailing
18:00:00 <mjg> and swapping
18:00:00 <mjg> and once it starts swapping...
18:00:00 <geist> dude yeah and with 12G you're right on the edge
18:01:00 <geist> 64G minimum or i aint touchin no computer
18:01:00 <mjg> you think i'm fucking around with that statement?
18:01:00 <clever> i recently found that 16gig of my ram was suspect (bit flips occuring) and removed it, so ive lost half my ram, but its barely noticable
18:01:00 <mjg> i got 1G swap and it is nearly full most of the time
18:02:00 <geist> yeah i do think you'er fucking around with that statement
18:02:00 <mjg> there is a point i don't understand where it magically decides to OOM shit instead
18:03:00 <geist> and/or you have a misconfigured system
18:03:00 <mjg> basically everything works until it suddenly does not, all while i don't change squat
18:03:00 <geist> sounds like you have something misconfigured
18:03:00 <mjg> it may be firefox randomly decides to grab way more ram
18:03:00 <mjg> it is a default ubuntu install, except i whacked the default vm in favor of i3
18:03:00 <geist> huh. how many tabs do you keep open?
18:04:00 <geist> i honestlyd ont have any experience with firefox with lots of tabs but i assume it's as smart as the other browsers and knows when to stop things in the background
18:04:00 <geist> chrome will consume a lot of ram, but also knows how to back off when the system si running low
18:04:00 <mjg> hard to say, definitely 30+
18:04:00 <mjg> includes wankers like slack
18:04:00 <geist> do you have a bunch of other processes that are consuming lots of it?
18:04:00 <mjg> times two
18:05:00 <mjg> no, rss is almost all firefox
18:05:00 <geist> well, anyway youre smart enough to figure it out, but that's a bit odd
18:05:00 <mjg> i think it just leaks memory man
18:05:00 <geist> but it's possible firefox is not as good at dealing with that sort of thing
18:05:00 <geist> or that
18:06:00 <mjg> it's been quite a while since i straced firefox
18:06:00 <mjg> mprotect(0x13e23b614000, 4096, PROT_READ|PROT_WRITE) = 0
18:06:00 <mjg> mprotect(0x13e23b614000, 4096, PROT_READ|PROT_EXEC) = 0
18:06:00 <mjg> mprotect(0x13e23b614000, 8192, PROT_READ|PROT_WRITE) = 0
18:06:00 <mjg> mprotect(0x13e23b614000, 8192, PROT_READ|PROT_EXEC) = 0
18:07:00 <mjg> massive loop with things like hte above on repeat
18:07:00 <mjg> and yes, it is the same thing twice in a row
18:07:00 <geist> then restart it
18:07:00 <mjg> i'll after my free ram drops to 0.5G
18:08:00 <mjg> i rebooted yesterday
18:08:00 <GeDaMo> Something to do with JS JITting?
18:08:00 <puck> yeah that was my guess
18:08:00 <puck> w^x jit
18:09:00 <mjg> poll([{fd=38, events=POLLIN}, {fd=39, events=POLLIN}], 2, 0) = 0 (Timeout)
18:09:00 <mjg> poll([{fd=38, events=POLLIN}, {fd=39, events=POLLIN}], 2, 0) = 0 (Timeout)
18:09:00 <mjg> poll([{fd=38, events=POLLIN}, {fd=39, events=POLLIN}], 2, 0) = 0 (Timeout)
18:09:00 <mjg> poll([{fd=38, events=POLLIN}, {fd=39, events=POLLIN}], 2, -1) = 1 ([{fd=39, revents=POLLIN}])
18:10:00 <mjg> read(39, "\372", 1) = 1
18:10:00 <mjg> write(40, "\372", 1) = 1
18:10:00 <mjg> sup with the first 3 poll calls
18:10:00 <mjg> i presume the read/write thingy is heartbeat
18:17:00 <mjg> hrm can i whack avahi and not have dhcp breakdown?
18:17:00 <mjg> i don't know the deps here
18:17:00 <clever> avahi is for operating in an environment that may lack dhcp
18:18:00 <mjg> fair
18:19:00 <clever> avahi lets you auto-detect services on the LAN using broadcast packets, and works even with the 169 automatic IP's when dhcp is down
18:19:00 <clever> chromecast, some printers, apple devices, and more, are avahi based
18:20:00 <mjg> good grief, can't remove libgnome-bluetooth-3.0-13:amd64
18:20:00 <mjg> The following packages will be REMOVED: gdm3 gir1.2-gnomebluetooth-3.0 gnome-shell libgnome-bluetooth-3.0-13 ubuntu-session
18:20:00 <mjg> i'm pretty sure this will mess up the system
18:23:00 <gog> this kills the linux
18:23:00 <mjg> to say something positive for a chagne, i have updated this ubuntu install 18 -> 20 -> 22
18:24:00 <mjg> and apart from minor snafus there were no problems with it
18:24:00 <mjg> in contrast, should you try to upgrade freebsd after 6 months it is almost guaranteed something in the ports will be messed up
18:25:00 <gog> it helps that ubuntu has a consistent configuration across install bases
18:25:00 <gog> you can't really guarantee that on freebsd
18:25:00 <gog> makes the upgrade path less likely to break everything
18:26:00 <mjg> in that spirit freebsd has a 'base' system separate from ports, that always updates nicely
18:26:00 <gog> that said, arch-based distros also have a consistent configuration (when you're using only official repos) but there's often upgrade snafus
18:26:00 <gog> yes
18:26:00 <mjg> it is the 3rd party ports you add which keep going haywire
18:26:00 <mjg> the extra stuff i added on ubuntu would definitely cause trouble
18:27:00 <gog> ppa?
18:27:00 <mjg> ppa?
18:27:00 <gog> private package archive
18:27:00 <gog> apt-based distros equivalent of ports but binary distributiopns thereof
18:27:00 <mjg> never herad of it
18:28:00 <gog> they often have backported packages or alternate builds
18:28:00 <mjg> anyhow, modulo sometimes running out of ram, i have to say ubuntu is a smooth ride for me
21:22:00 <heat> henlo
21:22:00 <heat> is this operating system development
21:23:00 <zid`> no
21:23:00 <zid`> dark souls user support
21:23:00 <zid`> heat is buying me a new controller yes?
21:23:00 <heat> is your thumb good now
21:23:00 <heat> or is it still ouchie
21:23:00 <zid`> yea for now
21:26:00 <heat> this is brilliant
21:26:00 <heat> my controller is still all kinds of broken in linux
21:27:00 <heat> this is such a garbage desktop operating system holy shit
21:27:00 <sortie> heat, osdev, sortie speaking, the problem is between the keyboard and chair, thank you (hangs up)
21:27:00 <heat> sortie, u support usb hid yet
21:27:00 <zid`> rawinput doesn't work in wine apparently
21:27:00 <sortie> heat: WONT_FIX
21:28:00 <heat> sortie, oh, kinda reminds me, you should use bugzilla or something on your OS
21:29:00 <sortie> No need already got plenty of bugs
21:41:00 <heat> sortie, actually isn't gitlab self hostable?
21:42:00 <heat> is it just a bunch of linux binaries or actual source?
21:42:00 <sortie> Was it Ruby?
21:42:00 <sortie> I think it's theoretically doable but just pretty big
21:43:00 <heat> would be pretty freaking cool though
21:43:00 <sortie> gerrit
21:44:00 <heat> unless you're still thinking about gerrit
21:44:00 <heat> lmao
21:44:00 <sortie> Need Java tho
21:44:00 <heat> I suspect Java is Not That Hard(tm) to port
21:44:00 <heat> last I checked even the BSDs used a bunch of linux code in openjdk
21:45:00 <sortie> You still don't get that if you port X then you got X
21:46:00 <heat> yeah
21:46:00 <heat> sortix coreutils rewrite in enterprise java, what's wrong?
21:55:00 <sortie> Right regular Java won't do
21:57:00 <sortie> Poor Java should've used even more modern Java
21:57:00 <sortie> *Poor heat
21:59:00 <FireFly> reminds me I should set up cgit
22:01:00 <heat> aight i give the fuck up
22:01:00 <heat> linux is perma broken
22:02:00 <heat> the controller Just Works in android, does not work whatsoever in linux
22:07:00 <kaichiuchi> embrace it heat
22:08:00 <heat> i installed 2 (two) fucking different drivers just to see it reconnect-loop with bluetooth and have a broken ass button mapping in usb
22:09:00 <heat> two drivers on dkms because ofc why would my distro give me useful stuff
22:09:00 <heat> every system should have a compiler installed!
22:10:00 <kaichiuchi> remember though
22:10:00 <kaichiuchi> it's your fault
22:10:00 <kaichiuchi> even when it isn't
22:10:00 <heat> yes
22:11:00 <heat> it's my faulting for using linux, I agree
22:11:00 <heat> s/faulting/fault/
22:11:00 <AttitudeAdjuster> heat: yeah, smh
22:11:00 <heat> i should be using one of the BSDs so I could struggle with even more basic shit
22:15:00 <heat> this is why I would never actually use musl on a personal system
22:15:00 <heat> all the struggles of linux but worse
22:15:00 <heat> much worse!
22:16:00 <mjg> is this how i sound?
22:17:00 <heat> no, you don't use FreeBSD
22:17:00 <heat> like a good freebsd developer
22:18:00 <mjg> all gentoo devs are on debian
22:18:00 <AttitudeAdjuster> lmfao
22:19:00 <heat> all debian devs use slackware on thinkpads
22:19:00 <sortie> Sortix developers use Debian
22:20:00 <mjg> onyx developers use arch
22:21:00 <sham1> Do they use Arch, btw?
22:21:00 <heat> absolutely
22:21:00 <heat> I do use it, btw
22:23:00 <mjg> and debian developers use itanium
22:24:00 <sham1> A brilliant architecture that just… died
22:24:00 <sham1> And now we're stuck with AMD64 and Arm
22:24:00 <sham1> Great
22:24:00 <samis> brilliant, really?
22:24:00 <heat> debian developers are computer necrophiliacs
22:25:00 <heat> samis, way ahead of its time at least
22:25:00 <samis> yeah, but brilliant implies that it worked better than it actually did?
22:26:00 <heat> oh brilliant is a large overstatement ofc
22:26:00 <sham1> I find it technically appealing
22:26:00 <mjg> it is different for sure
22:26:00 <sham1> And yeah, an overstatement for hyperbole
22:28:00 <mjg>
22:28:00 <bslsk05> ​'Let’s go whaling: Tricks for monetising mobile game players with free-to-play' by PocketGamerbiz (00:19:48)
22:28:00 <AttitudeAdjuster> bruh
22:28:00 <moon-child> I don't like the idea of vliw
22:29:00 <moon-child> no opportunity for dynamic scheduling
22:29:00 <moon-child> (unless you do it at a meta level like gpus. Then it's fine. Or if completely serial _anyway_)
22:30:00 <moon-child> mjg:
22:30:00 <bslsk05> ​'1,500 Slot Machines Walk into a Bar: Adventures in Quantity Over Quality' by GDC (01:00:26)
22:30:00 <AttitudeAdjuster> bslsk05: bruh
22:30:00 <moon-child> AttitudeAdjuster:
22:31:00 <heat> AttitudeAdjuster, you realize its a bot right
22:31:00 <AttitudeAdjuster> heat: nope
22:31:00 <AttitudeAdjuster> i thought it was just some regular person shitposting
22:31:00 <moon-child> lol
22:31:00 <kaichiuchi> AttitudeAdjuster: are you named after the wrestling move
22:31:00 <AttitudeAdjuster> and shitposting really diabolical shit
22:31:00 <AttitudeAdjuster> like roblox
22:32:00 <AttitudeAdjuster> kaichiuchi: no
22:32:00 <kaichiuchi> ah.
22:33:00 <AttitudeAdjuster>
22:33:00 <bslsk05> ​ Attitude Adjuster | The Culture Wiki | Fandom
22:34:00 <AttitudeAdjuster> ohhh it was responding to yt links people posted
22:34:00 <AttitudeAdjuster> now it all makes sense
22:35:00 <heat> this is moderately hilarious
22:35:00 <kaichiuchi>
22:35:00 <bslsk05> ​'Extreme Attitude Adjustments - WWE Top 10' by WWE (00:01:50)
22:35:00 <AttitudeAdjuster> heat: what is, me being oblivious to bot behaviour?
22:35:00 <heat> yes
22:36:00 <AttitudeAdjuster> XD
22:36:00 <heat> you thinking it was a bot shitposting at the exact same time someone posted a link
22:36:00 <AttitudeAdjuster> i was skim reading okay
22:37:00 <AttitudeAdjuster> look ill be honest i had a few drinks at the office with my work crew, i am not sober rn
22:37:00 <kaichiuchi> i miss those days.
22:37:00 <AttitudeAdjuster> my new company has the "break things" and "drinking culture" parts of the modern startup down for sure
22:37:00 <AttitudeAdjuster> the rest idk