<bslsk05>
<Wikipedia> Here's how the "Ship of Theseus" page looked in July 2003 when it was first created! Since then, the article has been edited 1792 times. 0% of its original phrases remain. https://cdn.masto.host/wikisworld/media_attachments/files/111/587/002/680/243/749/original/a14f92f74ab0dc66.png [A Wikipedia page for Ship of Theseus is shown. The article reads "According to an ancient Greek legend, Theseus had a warship that was preserved as a historic
<heat>
maybe you mandela effected from a multiverse where #osdev is on discord
<zid>
we should find a category of meme to give to geist to repost here, factorio maybe?
<geist>
VAAAAAAX
<zid>
vax *is* a meme, I'll grant you that
<heat>
vax rust vax rust cargo
<geist>
$ gtelnet mvax
<geist>
Connected to mvax.
<geist>
Welcome to OpenVMS (TM) VAX Operating System, Version V7.3
<geist>
Trying 192.168.0.42...
<geist>
mwahaha
<zid>
archaic = doesn't support rust
<zid>
bronze age, basically
<geist>
hmm, i should see if there's some sort of irc client for this
<zid>
telnet is good enough
<zid>
do ircds typically strip IAC?
<geist>
what's IAC?
<heat>
C is going to get bronze aged by RUST
<zid>
I've connected to irc a few times with a telnet client, but I've never had anybody send me an IAC SHOULD TERMTYPE IAC or anything
<zid>
0xFF
<geist>
oh oh yeah last i checked at least freenode had the PING PONG set really low
<geist>
like once a minute
<geist>
haven't actually tried on libera
<zid>
heat: I'm going to make a succesor to C that rivals rust, called patina
pretty_dumm_guy has quit [Quit: WeeChat 3.5]
<heat>
is it just a new name for zidc?
<zid>
yea basically
<zid>
remove w, can dereference pointers to structs with incomplete members, enum types are type checked, etc
Arthuria has joined #osdev
<zid>
null must be (void *)
<zid>
and some other stuff I likely forgot
<heat>
null is now guaranteed to not have the 0 bitpattern
<moon-child>
how generous of wg14
edr has quit [Quit: Leaving]
<geist>
WG14 the tagger?
<zid>
working group 1914?
<moon-child>
zid: wait what's w
<heat>
wprintf, etc
<zid>
wvacstombsrintf
<geist>
ah no, WD14 is the tagger
<moon-child>
oh that w
<moon-child>
but how will I live without glibc's optimised wmemcpy
<heat>
why is wmemcpy not "shl $2, %rdx; jmp memcpy"?
<moon-child>
don't need as many special cases for small lengths
<zid>
how does wshit handle nuls btw, is it just two?
<geist>
yah seems that memcpy would be the same, but then of course wstrcpy needs special code to handle w
<zid>
so yes, it's two
<zid>
that's the only reason printf woudln't just work then I guess
<moon-child>
only on w indows
\Test_User has quit [Ping timeout: 260 seconds]
<zid>
and codepoints with 0x00xx or 0xx00
<moon-child>
?
<geist>
sure but if it were uft8 it wouldn't be w
<geist>
i think the point being that the 'w' stuff is when using something like ucs2 or ucs4 right?
<zid>
I was thinking more 'some random 16bit chars'
<heat>
yeah geist
<zid>
than unicode, cus unicode is *mostly* nul clean already as far as I know
<heat>
it's utf-32 on everything except windows AFAIK
<zid>
it's just the terminator that'd be an issue sometimes
<geist>
i mean honestly on modern machiens a 32bit char seems like a great solution
<geist>
just go for it, deal with the endian issues and make it nice a clean and fast
<moon-child>
meh
<heat>
youuu teee efff eight
<moon-child>
I mean the question is what ar eyou actually doing with strings
<geist>
windows going all ucs2 is much malinged but i think it was just a bit too early
<moon-child>
most of the time unless you're writing a text renderer all you're doing is concatenating, reading/writing, or maybe doing substring searches. all of which don't care about the actual textual representation
<geist>
the *idea* is pretty solid
<heat>
rust's .chars() iterator converts the whole string to codepoints
<geist>
nice thing with something W is you're not having to do all the utf8 conversions when counting size, finding boundaries, etc
<zid>
yea, you should basically never ever inspect random text yourself
<zid>
only leads to bugs, hi apple
<moon-child>
remember the thing in apple's libc where it literally shells out to like perl or something
<zid>
(They tried to cut off text that would overflow the notification bar by just chopping after so many bytes and adding ...)
<heat>
thats for regex
<zid>
This bricks the arabic.
<epony>
moon-child, greetings and best regards
Arthuria has quit [Remote host closed the connection]
<epony>
the bigger joke is about the location of the actual Troy where the famous horse was used as a stage in primitive "turn based" strategy game
netbsduser has joined #osdev
<epony>
cause everybody knows C is too large to fit in 8bit CPUs of the early 80ies, and Rust is not fitting on 32bit machines either ;-)
<bslsk05>
regex101.com: regex101: build, test, and debug regex
<gog>
the very last line i want to not match, but because of the 52:20
<zid>
You're trying to group times? nice
<heat>
regex was a mistake
<gog>
it's more like i'm trying to allow anything that looks like a time and has the right number of digits in the right sequence
<gog>
it doesn't have to be fully sensible
<gog>
just has to reject obviously wrong times
gorgonical has quit [Ping timeout: 260 seconds]
<zid>
I'd just you know
<zid>
parse this
<zid>
instead of using regular sexpressions
<gog>
i guess i could do that too
<gog>
but the easiest solution is to fix the regex i already have there because the form component i'm using already does this for me and i don't have to write more code in a thing that already is janky
<gog>
idk
<gog>
and none of the time formats we get back are consistent and we have no reasonable way to make them consistent
<zid>
(hour):(minute)(AM|PM) then mechanically filter
<zid>
rather than tring to do it all in regex
<zid>
seems the nicest
<gog>
i want to not add parsing code though
<gog>
i want to not add code to this
<zid>
disgusting
<gog>
adding code means i need to test it
<gog>
i don't want to test it
<gog>
i don't even want to fix it but i broke it
<heat>
HAVE YOU TRIED
<heat>
USING CODE
<gog>
i will not
<gog>
you cannot make me use code
<gog>
code is of the devil and i am a godly woman
<gog>
begone satan
<heat>
regex is of the devil
<heat>
code is chaotic neutral
<zid>
yea this is a fucking mess
<zid>
you need to add all the cases by hand
<zid>
copy pasting the regex
<zid>
or you end up with fucking nonsensical capture groups
<zid>
I got as far as (([0-9][0-2]|[0-9]):[0-5][0-9][ ]*PM|.*([0-2][0-9]|[0-9]):[0-5][0-9][ ]*AM) then gave up
<heat>
if the solution is too obvious you lose ioccc
<kof123>
so an old compiler...might even divide and remainder...
<geist>
since this is C i dunno what the type of *robust is, but it's probably an int or char, as a bool?
<heat>
int yeah
<geist>
then you get into the very real issue of whether orn ot it is hard fixed at 0 or 1, or is it 0 and !0
<geist>
i've seen various C bugs slip in because of that before
<geist>
assinging some non zero to and int-as-a-bool, and then later on some code does something like foo == true
<geist>
where true is 1
<geist>
one of the reasons i'm a little leery of generally using == true and == false
<geist>
C++ bool type solves this
<epony>
the difference is, a new compiler sometimes can work too, but an old compiler does not have these optimisations available, you have to do it
<epony>
s/robust/todoit/g
<heat>
yeah
<kof123>
i have to make one quick joke for gog > you cannot make me use code goggins... it is all code :D > He was in Bethany, “the place where John was at the first baptizing” (cf. John i. 28 with John x. 40, 41), but it took him two more days to get there at this particular time. > Mad Hatter: “Well, no wonder you are late. Why, this clock is exactly two days slow!” White Rabbit: “Two days slow?!” Mad Hatter
<kof123>
: “Of course you are late! The White Rabbit is late as usual and the Hatter explains that his watch is two days slow. > Usually, a full Moon arrives a few days to weeks before or after the equinox
<heat>
tbf == true and == false is a codesmell IMO
<heat>
and my clang-tidy screams THIS IS REDUNDANT
<heat>
(in C++, in C it probably doesn't in these situations)
<Ermine>
heat: at my $dayjob I saw return cond? true : false
<netbsduser>
one nice trick to identify a good lock ordering for atomic waits for several things to simultaneously become acquirable is to quicksort your pointers to the objects and use that for your lock ordering
<netbsduser>
geist: great choice, i wonder how highly it ranks among the slowest systems to run netbsd
<geist>
it's usable. you really feel it when compiling
<geist>
but think of it as being approximately as fast as say a 20mhz 486
<geist>
but with 32MB ram so it's not really under that much memory pressure, with a netbsd that old at least
<heat>
netbsduser, ... how many things are you locking at once
<heat>
and why is higher than 2 at any moment in time
<geist>
average command line binaries have fairly small footprint (<500KB,etc)
<Ermine>
geist: how much does it consume
<geist>
consume what?
<Ermine>
ram
<heat>
512 byte pages are ideal
<geist>
not too much. i think the kernel shaves off about 3 or 4, once the handful of things have started i think it's maybe 8MB out of 32MB used
<netbsduser>
heat: for atomic waits which are to be satisfied only when everything the thread is waiting for is available, everything that the thread is waiting for
<geist>
unclear if it's using 512 byte pages. netbsd at this point may be treating them as 4K
<heat>
netbsduser, but you don't need lock ordering for waits
<Ermine>
iirc windows can pages with different sizes
<mjg>
that's a mid-00s tech
<mjg>
at best
<geist>
oh much less than that actually
<netbsduser>
you do if you want to lock everything simultaneously so you can poll all their availability atomically, and then every time that one of them becomes available
<heat>
but you don't need that
<netbsduser>
i had it before and i would hate to sacrifice a feature
<heat>
why do you want that?
<heat>
that's not a feature, it's a horrific lock warcrime
<netbsduser>
originally i anticipated using it to acquire multiple mutexes or similar atomically so i don't need to have regard to their rank
<netbsduser>
but in practice you have two cases where you need to acquire multiple mutexes
<zid>
I use 1 byte pages
<heat>
THATS SO OPTIMAL
<netbsduser>
in the one case, you also have ownership semantics mixed in, and you've got to acquire them in a specific order in order to even know safely what the next one you've got to acquire is
<geist>
yah it's using virtual 4K pages i think: hw.pagesize = 4096
<geist>
from sysctl
<heat>
bastards
<netbsduser>
in the other case, probably locks protecting "sibling" objects, you can use the same principle of letting lock order equal pointer address order. so it is a probably useless feature to have atomic acquisition of multiple mutexes
<heat>
guess you need those for some filesystems? if they have the block size <= page size restriction
<netbsduser>
i don't think it's currently possible in netbsd to have the contrary
<netbsduser>
i haven't looked very thoroughly or indeed at all but i'm sure i would've seen provision for that case if it did, having looked through uvm a few times
<geist>
hmm i dont haved it booted but i also have a sparc64 install on netbsd
<geist>
i think that uses 8k pages hardware
<geist>
but then i think by default FFS uses 8k blocks (with 1k fragments)
<heat>
netbsduser, anyway yeah qsort ordering for locks is exquisitely overkill :v
<netbsduser>
heat: it will be a race against time to see whether i can implement my entire solution for the problem of atomic waits for several waitables in what's left of this day
* geist
queues late night hacking montage music
<netbsduser>
if i don't do it tonight, i will probably forget the solutions i figured out to it after i've slept
<heat>
in heat news: i'm unfucking writeback
<heat>
we're making this usable baybee
<heat>
my solution is exquisitely linux
gildasio has joined #osdev
<heat>
it is my duty as a dollar-store-linux vendor
<bslsk05>
'In Motion (HD) - From the Soundtrack to "The Social Network"' by CookieAdventures (00:05:02)
<netbsduser>
all this for a "feature" i will have to avoid because it pessimises everyone else dealing with the waitables (since if you make a waitable ready when it's got a waiter on it doing this, the readiness notification then has to lock everything else that waiter is waiting on and test whether they're all ready)
<netbsduser>
but every kernel needs some personality
<heat>
fyi many common linux objects have lock-free waiting
<heat>
pipe polling for instance is lock-free
<netbsduser>
how about if you put a pipe into an ePoll? or indeed a select()/poll()