ChanServ changed the topic of ##yamahasynths to: Channel dedicated to questions and discussion of Yamaha FM Synthesizer internals and corresponding REing. Discussion of synthesis methods similar to the Yamaha line of chips, Sound Blasters + clones, PCM chips like RF5C68, and CD theory of operation are also on-topic. Channel logs: https://freenode.irclog.whitequark.org/~h~yamahasynths
ej5 has joined ##yamahasynths
<cr1901_modern> Btw, random, but... for those who don't know yet, I am done treatment. I hope to stop being out of commission by the end of next week so I can do weekly vectorizing. But I haven't been able to do much since I got out on Nov 17. Not sure what's wrong with me/my motivation...
<ej5> congrats! take it easy/don't be too hard on yourself getting back into the normal swing of things.
<cr1901_modern> I've been doing a lot of reading (mostly Rust stuff), trying to parse complex topics, and it's been draining me from actually _doing_ shit.
<cr1901_modern> I'm just tired...
<andlabs> treatment for what?
<ej5> why are you using rust? it's like hitting yourself in the head with a hammer; it feels so good when you stop.
<cr1901_modern> andlabs: In May I was diagnosed w/ lymphoma... I made a brief announcement to the room back then. On Nov 17, I finished treatment.
<cr1901_modern> ej5: Because I've decided I _aesthetically_ resent GC more that learning Rust is worth the pain; I don't have any good technical reasons for disliking GC.
<cr1901_modern> Well, learning Rust in the detail that I (at one point) knew C
<ej5> hmm, what i would really like is a version of C that fixes the glaring problems, but doesn't try to do too much more than that
<ej5> C+ as it were.
<whitequark> the problem here is that no two people can agree what the glaring problems are
<ej5> GC solves a particular problem with a very big sledgehammer. you ever see how QT does memory management? it's not quite right, but it's not so bad
* ej5 lookie lookie
<andlabs> cr1901_modern: ah
<whitequark> a new language needs network effects to make even a tiny dent and you don't get network effects from being "slightly less bad than C but basically the same otherwise"
<andlabs> well congratulations; get fully better soon
<ej5> yeah i figured i haven't been writing C code, i've actually been writing GCC code :P
<cr1901_modern> ej5: Even my aesthetic disdain for GC has waned in recent months... I've like Lisp and OCaml (though I only really know how to use a subset of each).
<whitequark> especially given that most people who would be entirely happy with writing "slightly less bad C" are already basically happy writing "C plus workarounds for the worst things"
<whitequark> there's even a perverse result where they would argue that these glaring problems are, in fact, features, and are good and proper
<ej5> i hate the fact that cdecl.org has to exist.
<cr1901_modern> andlabs: Tyvm
<cr1901_modern> It's fairly easy to get cdecl to f*** up too
<ej5> honestly, i've only ever seen function pointers used *once*
<ej5> production code, anyway.
<cr1901_modern> Can't use "q"sort or bsearch without them tho :P
<ej5> i'll do a twitter thread about it tomorrow, but i found some printed docs from some code i wrote in the 90s
<whitequark> aren't you using one each time you write pthread_create or atexit or qsort or ... yeah
<whitequark> glib is *mostly* function pointers
<whitequark> that C makes writing higher order functions so painful people end up thinking it's a bad idea, is one of its worst crimes
<ej5> interesting, i've never dug into dlib
<ej5> *glib
<whitequark> glib and gtk are slapping objects on top of C and classes are bags of function pointers
<ej5> basically yes, that's how i've seen function pointers used in production code
<cr1901_modern> There's a literal book on getting 90% of C98 features by filling structs w/ function pointers and arrays (for vtables). Would hardly be surprised if multiple books exist.
<whitequark> C98 features?
<whitequark> do you mean C++98?
<cr1901_modern> yes
<whitequark> the first C++ compilers did output C
<ej5> whitequark, interesting links. every point in the list makes me think carefully, cringe slightly, shake my head, maybe nod a bit, grit my teeth, and then move on.
<whitequark> John Regehr's blog posts and papers are very good
<ej5> yes, it's clear he's thought it out very carefully.
<whitequark> he's only been thinking about it for a decade :)
<ej5> c is a pretty archaic language, designed before formal language descriptions were really even invented
* ej5 points at my Duffs Device rant a few days ago
<cr1901_modern> TIL that the cfront source code was preserved as can be downloaded: http://www.softwarepreservation.org/projects/c_plus_plus/index.html#release_30
<cr1901_modern> wonder how templates are implemented (particularly since reusing "<" for templates causes... a number of problems...)?
<ej5> seems to me that someone ought to create a synthetic one's complement machine, then implement a c compiler, just for checking standards compliance
<cr1901_modern> Clemency CPU is such a machine
<ej5> feels like once you get down to bit math all bets are off :P
<ej5> have you ever tried to write a cpu simulator? the ALU is the hardest part
<whitequark> it's kind of pointless because most existing code would already not compile or work on non-8-bit-byte targets
<ej5> yeah how many programs break when int is 8 bits?
<cr1901_modern> int can't be 8 bits
<cr1901_modern> although curiously enough, the gcc manual says it can (even though the spec says it can't)
<cr1901_modern> >it's kind of pointless because most existing code would already not compile or work on non-8-bit-byte targets
<cr1901_modern> ZipCPU ran into this problem porting a libc (glibc?) to the original 32-bit char version of his CPU. It was bad enough he redesigned the CPU to have an 8-bit char.
<ej5> a 32-bit char???!?
* ej5 looks for a spare torch and a lighter
<whitequark> my CPU has 16-bit char
<whitequark> but I see inability to run C code on it a feature :p
<cr1901_modern> A smart assembler should make writing larger swaths of code for Boneless tolerable to semi-pleasant.
<whitequark> yea
<ej5> whitequark, wth happened to dr taber? i see you r/t but twitter seems to have forgotten her?
<cr1901_modern> ej5: >it's like hitting yourself in the head with a hammer; it feels so good when you stop.
<cr1901_modern> I don't think it's that bad. But I am discouraged tonight b/c I hit a wall with something undocumented, and learning about it will likely be a multi-day back and forth on Rust Discourse forum.
<ej5> looks like i got blocked somehow? that's extremely odd
<ej5> best of luck cr1901_modern
<cr1901_modern> thanks. I'll get it eventually. Just not as fast as I'd like...
<ej5> looks like she's blocking people based on who they follow. apparently someone i follow is objectionable? no idea who that could be. anyway the tweets whitequark linked are quite fascinating.
<cr1901_modern> I once got blocked for what I _suspect_ were due to my opinions on systemd (It's not good). That was fun.
<whitequark> ej5: yeah. lots of people have to do that for twitter to be tolerable.
<ej5> i do that myself, i use a combination of blocking a muting to turn it into something usable
<ej5> *and
<cr1901_modern> This is a very privileged position to take but in general I only block obnoxious bots, and my mutes in general are petty, not b/c the mutee did something bad.
<ej5> anyway it's the first time i've found someone with very interesting tweets that i can't follow, nor can i find out why i can't follow them. :(
<cr1901_modern> i.e. I mute dril b/c I'm no fun and find the account absolutely obnoxious.
<ej5> hmm, never heard of them. *clicks* ok, pinned tweet is "no" with 59,000 retweets. ok.
<cr1901_modern> It's some ex-SA goon IIRC who gets a bunch of RTs by stringing together random words to be funny and everybody loves it for its absurdity
<cr1901_modern> Oh and a photoshopped image of Jack Nicholson smoking a cigar
<ej5> SA=something awful? holy crap i have not heard that name in a very long time
<cr1901_modern> _I_ never paid for it :P
<whitequark> to be fair, dril is more funny than most people who think they're funny
<ej5> neither did i, got some mild entertainment from browsing GBS back in the early 2000s
<cr1901_modern> whitequark: dril has some good tweets. The "zero difference between good things and bad things". "It's impossible to say if it's bad or not".
<cr1901_modern> I think that's it
<ej5> but the rest isn't even that funny, and so many problematic tweets
<whitequark> cr1901_modern: what about "my disrespectful teen son somehow got hold of a gluten product and now he wants to become a cat girl"
<whitequark> there's a generation of people who grew up on that tweet alone.
<cr1901_modern> Never seen that one before. It's cute :).
<ej5> huh, it's basically a shitposting account where "hi i'm bob" gets 22,000 retweets
<ej5> lines up with my experience. tweet out some particularly tricky technical achievement: lukewarm. tweet some shitpost about using a floppy drive to upgrade firmware in an oscilloscope: ermagerd, lolz
<cr1901_modern> Or if you're me, you've never had a tweet get triple-digit RTs
<ej5> btw the scope firmware guy is pretty cool, i RTed it to give him some followers
<whitequark> wow rude
<ej5> last week he had zero followers.
<cr1901_modern> scope firmware guy?
<ej5> yeah he used to work for HSC electronics. that's where i met him.
<ej5> turns out he's pretty cool, builds modular synths, that sort of thing
<cr1901_modern> Does he like FM synths ;)?
<ej5> yes he does
<ej5> not sure if he's into IRC, but i'll check ;)
<cr1901_modern> Noooo, I wasn't insinuating anythi- tyvm!
<cr1901_modern> Oh right re: Rust... any YM2151 core I make from the vectorization will be in Rust w/ C bindings. I want the core to be accurate, and if nukedOPN2/OPL3 is any indication, such a core will really only work on contemporary machines anyway. So I don't gain much practical portability using C.
<cr1901_modern> whitequark: Completely OT, but... OCaml uses nominal typing, but the language has sugar to make definining records with structural typing, correct?
<whitequark> no, ocaml doesn't have structural records at all
<whitequark> it has structural tuples, which are similar to a degree
<cr1901_modern> I think I might be confusing "structural" and "nominal" with another feature; you can declare a record with a specific layout "foo" as a new type. Subsequently, _every_ time you _instantiate_ a record with said specific layout in the same order, it is considered type "foo".
<cr1901_modern> Contrast to other languages where two structs w/ the same layout are different types
l_oliveira has quit [Quit: ChatZilla 0.9.92-rdmsoft [XULRunner 35.0.1/20150122214805]]
_whitelogger has joined ##yamahasynths
_whitelogger has joined ##yamahasynths
<whitequark> layout "foo"?
<whitequark> what is that?
<cr1901_modern> I meant if you did something like this: type foo = { one : int; two : int };; type bar = { one : int; two : int };;, you could use bar as an input arg anywhere a foo was expected (because records are instantiated without referencing the actual type name).
<cr1901_modern> Turns out this is not true, and I was just confusing myself.
<cr1901_modern> (In the code snippet "type foo = { one : int; two : int };; type bar = { one : int; two : int };; let my_record = { one = 1; two = 2; };;" my_record has type bar. OCaml uses the most recent definition if there's ambiguity.)
<cr1901_modern> In fact, Idk if it's possible, assuming an environment after that code snippet is run, to construct a type "foo" aside from OCaml doing it for you after type inference.
<whitequark> not quite the most recent
<whitequark> you can do umm
<whitequark> let r: foo = { one = 1; two = 2; }
<whitequark> you could also do
<whitequark> let r = { foo.one = 1; two = 2; }
<whitequark> IIRC
<cr1901_modern> oh that second one is nice
<whitequark> ok no that doesn't actually work
<whitequark> it only works with modules
<whitequark> hence the Foo.t pattern
<cr1901_modern> >not quite the most recent
<cr1901_modern> Noted. I'll look it up later. The important part is that foo and bar are distinct types, and I managed to think for a long time "no they're not".
<Lord_Nightmare> ej5: re: https://twitter.com/TubeTimeUS/status/1110325906193543168 I think I mentioned this already, but the building that magazine is/was located in was near the Bala Cynwyd shopping center, ~3 miles from here.
<ej5> hah, that's cool
<ej5> maybe you know how to pronounce the name then ;)
<Lord_Nightmare> bah-luh kin-wood
<Lord_Nightmare> lots of welsh names around this area
<ej5> neat
<Lord_Nightmare> clwyd road, bryn mawr, cynwyd, etc
<Lord_Nightmare> or kin-widd... there's probably a proper pronunciation i don't even know, and i live basically there