00:00:00 --- log: started forth/19.03.12 00:02:38 ... admittedly, i'd have to give str-diff some thought :) - but it basically comes down to continuing until either char is 0 or their diff is non-zero 00:03:28 str-diff becomes a useful thing in itself anyway 00:11:53 2dup - 2rot * 00:12:39 kinda thing? 00:21:59 what 2rot does? 00:23:11 rot rot 00:23:23 2dup is over over 00:23:53 hehahahaha 00:23:59 oh - am i assuming nul terminated strings here? :) 00:24:41 1 2 3 4 5 6 2rot cr .s 00:24:41 <8> 1 2 3 4 5 6 1 2 ok 00:25:23 bah. that was fubar. 00:25:25 1 2 3 4 5 6 2rot cr .s 00:25:25 <6> 3 4 5 6 1 2 ok 00:26:06 the_cuckoo, rot rot == -rot right? tho, what does the purpose of the multiplication at the end? 00:26:40 ah - ok :) - the mult is just to see if either char is 0 00:28:56 hence if tos is 0 after comparing a char, the result is the value below - and if that value is 0, continue, or it's the result 00:30:57 dunno if it helps but it seems actually comparing strings is more that just equality :) 00:31:10 but not much more 00:36:01 but again, this only works with nul terminated strings - and forth doesn't typically have that, right? :) 00:36:09 unless it's non-ascii string 00:39:27 that shouldn't matter - it just can't have nul anywhere but the end 00:43:30 if you have the lengths up front, you can skip the character diff loop and just use the counts - if the diff is non-zero, you could use that as the result, otherwise loop for count and just diff each pair of chars 00:46:39 *laugh in unicode* 00:49:23 well - that depends - if you're literally using wchar_t, then each char is 4 bytes (or 2) - utf-8 varies but doesn't contain a nul 00:56:12 while ( *p1 && *p1 == *p2 ) ++p1, ++p2; <- this would be a typical loop in a c implementation anyway 00:57:18 --- part: PoppaVic left #forth 00:58:01 removes the mult :) 01:00:19 the_cuckoo: a "strcmp" type thing is in Forth 2012 standard 01:00:56 is that the compare of gforth? 01:01:14 yep compare 01:01:17 k 01:02:14 a "string equal" which just returns true or false is still useful imho 01:02:37 if it's more efficient, yeah 01:03:42 and : str-cmp compare 0= ; gives you it if you just need the 1 liner 01:03:48 there's probably not much difference and if you've already written COMPARE you can get : str= compare 0= ; 01:03:55 beat me! 01:03:55 indeed 01:03:57 :) 01:06:12 and the count short circuit i suggested above is probably wrong - would need to think about that one :) 01:07:37 i'm still blown away from [ and ] while compiling 01:08:19 it's so much more powerful than anything C could ever do 01:10:28 knowing forth, there are probably millions of uses of [ ] :) 01:12:32 yeah! 01:12:57 like say i wanted a sorted array, and i want to put a few strings in it 01:13:37 you can just [, make a few strings, sort them, ], and include it directly in a compiled word! 01:13:49 you just can't do that in C 01:14:21 you either write a separate program to sort the strings, or you sort it at run time 01:14:24 in mine, i have [[ "this is a string" hello "another one" ]] list-sort 01:14:40 cool! 01:14:41 ah - i see what you mean 01:14:54 mine would be sorted at runtime there 01:15:23 of course, i'm interpreting, not compiling so the rules are slightly different :) 01:15:24 but you can sort at compile time with Forth :-) 01:15:31 :) 01:17:36 switching computers... 01:19:45 --- join: dave0 (~dave0@223.072.dsl.syd.iprimus.net.au) joined #forth 01:19:53 re 01:32:55 for the stuff at compilation time - hmm - if the macro stuff in c were more comprehensive... :) 01:35:15 --- join: xek (~xek@apn-37-248-138-83.dynamic.gprs.plus.pl) joined #forth 01:39:08 for those kind of thing in c++, i tend to assign maps (ie: say i want a str -> function map, i'd have general map = { { "bar", bar }, { "foo", foo } }; type of thing - and i would maintain the definition in alphanumeric order... 01:39:32 my colleagues however, will probably just throw in new stuff ... somewhere 01:41:24 even if i put a comment like "KEEP THIS LIST SORTED", it doesn't matter - randomness will still occur :) 01:43:46 the_cuckoo: the burden is on the programmer to keep it sorta 01:44:28 the_cuckoo: and what if the sort was suddenly different? eg. it is case-sensitive or vice versa 01:45:29 yeah - but it's not a necessary thing for runtime since the insertion in the map will order the keys anyway - it's just that when reading code/verifying stuff, it's nice to assume consistency 01:46:13 hence having some kind of ordering in the code is a courtesy, but not a runtime requirement 02:06:19 * the_cuckoo shudders as he contemplates firing up the windows machine 02:07:54 seems one of my colleagues is having trouble with audio on his windows laptop - i'll bet i have no such issues on my desktop, but will need to confirm 02:09:00 computers are good until something goes wrong :-( 02:09:40 i have an iffy thumb drive that i'm trying to use 02:09:42 or they run windows 02:11:22 windows is so buggy :-( 02:11:33 really have no time for windows at all :) - windows '98 was the last time i had windows in the house - until last year :( - work requirements and loss of a couple of colleagues kinda pushed me to get one 02:13:05 the software i'm working on is cross platform - linux, windows and osx supported 02:13:13 --- quit: koisoke (Ping timeout: 272 seconds) 02:13:23 what you making? 02:14:25 well, i'm mostly working on the video processing library - there are video editors, transcoders and other tools which are written around it 02:14:44 --- join: koisoke (xef4@epilogue.org) joined #forth 02:17:24 the main product is what is known as a MAM system (media asset management) - basically, when tv broadcasters receive video from outside, they need to a) convert to their inhouse format and store it, b) provide proxies for use by the editors, c) manage online/offline storage and recovery 02:18:45 hence, we need to process live video streams in realtime, and non-live stuff is preferably *way* faster than realtime :) 02:19:53 and through out it all, the video streams which are being created need to be accessible while they are being created - ie: not just when they complete :) 02:20:51 so my lib handles the comms, demuxing, decode, compositing, fx, encoding and muxing and subsets of these used in the apps iyswim 02:22:17 throw in a bit of audio mixing, deinterlacing, stream analysis, gpu integration, distributed encoding for a bit of fun, and that pretty much sums it up i guess 02:24:41 sounds complicated! 02:25:17 hmm - it nicely breaks down into quite manageable pieces 02:26:05 there are pockets of complexity (my demuxer/decode sucks, but luckily there are better ones to use) 02:27:15 but mostly it comes down to wrapping external libs as 'inputs', 'filters' or 'stores' - filters connect to inputs and become inputs - inputs provide frames - stores receive frames 02:30:34 (and when i mean 'sucks' i mean in terms of code quality/legibility - functionally it's fine) 02:31:48 haha windows shit itself 02:31:56 it has a complex set of requirements which changed throughout its long history - hence the resultant mess :) 02:32:10 i'm trying to copy some files... i got "There is not enough memory to complete this operation." 02:32:21 :) 02:34:01 the flash drive is really marginal 02:42:54 ah windows it really shitting itself 02:42:59 gotta disconnect 02:43:05 --- quit: dave0 (Quit: dave's not here) 03:08:32 --- join: dddddd (~dddddd@unaffiliated/dddddd) joined #forth 03:14:19 --- quit: gravicappa (Ping timeout: 246 seconds) 03:28:25 --- join: gravicappa (~gravicapp@h109-187-192-183.dyn.bashtel.ru) joined #forth 04:17:08 anyone else concerned about dave0's disappearance? :( 04:35:09 candle jack is not 04:48:54 hmmm - ok :) 05:27:55 added kbhit functionality last night - allows me to do stuff like: 05:28:05 : handle &{ +> 32 == { toggle } +> 27 == { leave } +> 106 == { back } +> 107 == { toggle } +> 108 == { play } } ; 05:28:38 the what 05:28:46 this looks like haskell 05:28:56 as in, if the key is space, toggle play/pause, esc is exit, j is backward, k is toggle and l is play :) 05:29:30 what's with the low semantic meaning symbols 05:29:31 the intent is to call like kbhit handle (though i avoid 0 going through that) 05:29:35 why not use verbs 05:29:53 less typing :) - looks prettier when written over multiple lines 05:30:10 is totally unreadable without reading what the symbols do 05:30:29 https://gitlab.com/lilo_booter/rpany/blob/master/README.md#cases 05:30:45 yea i can see it is a case 05:31:01 but not as easily as if they were actual words 05:31:24 possibly true - easy to support anything - just liked that :D 05:31:49 just reporting my experience with symbol heavy code 05:31:58 much harder to understand 05:32:13 sure - am taking it on board as a criticism and i think it's fine 05:32:15 because in my mind, i say "case", but i read +> 05:32:32 so i need to do an active cognitive process to translate +> to case 05:33:15 for sure - it looks odd on first encounter - no dispute there - but over multiple lines, i do think the intent is pretty clear 05:34:14 what does = do if == is equality 05:34:48 haven't defined it - vaguely wondering if i should change to = for the forth-familiarity 05:35:06 unsure if i'm aiming this at forther's or c/c++ devs though 05:36:40 internally, it's all about c/c++ - basically wrapping functions/objects so that they're accessible as words and get their args from the data stack/place results there 05:38:35 and in this case, my object is a video playing thread which you can interact with via a few methods (like playing with speed/direction, pitch, position etc) 05:40:06 by adding kbhit, i get transport controls by just running a begin get-key handle again loop 05:40:23 which i like, even if no one else does :D 05:40:49 --- join: dave0 (~dave0@223.072.dsl.syd.iprimus.net.au) joined #forth 05:40:59 dave0: wb :) 05:43:57 thanks the_cuckoo :-) 05:45:24 machine recovered? :) 05:46:37 i found that if you copy the files over the old files, it works better 05:47:11 maybe it doesn't reuse the bad sectors or whatever 05:47:38 but who knows with windows? 05:47:56 yeah - not really knowable 06:38:19 dammit - vsync issues on my tv - hate that :( (had a powercut the other week - thought i'd fixed that already though) 06:38:38 tv = second monitor i use for testing 06:39:19 better :) 06:46:49 this is my basement/office setup btw - https://www.dropbox.com/s/c2hgtmztme7qnjw/2018-09-13%2010.53.47.jpg?dl=0 06:48:51 corecode: recurse in forth is not tail recursive no 06:55:28 the_cuckoo: nice looking office 06:56:04 cheers :) - i have a 'posh' one upstairs, but prefer it down here - more room 06:57:13 I don't have an office; have to make due with a folding table and chair for now. https://www.icloud.com/photos/#0AonrvcqhxYNKxxwkEwVBQ5ig 06:57:52 https://www.dropbox.com/s/x2yiun53wgm600v/2018-07-20%2018.46.39.jpg?dl=0 06:59:25 that's a lot of displays :) 07:00:03 :) - way too many :) - have cut it down significantly since then 07:02:09 managed to entirely retire the computer with the twin monitors on the right - now i only have two computers running - the big white one and one down here (and sometimes i fire up windows but try not to) 07:02:47 am also considering just running a usb-c long usb cable down here and use the white one only 07:03:14 should be good enough for a couple of monitors, keyboard and mouse 07:04:38 --- join: koisoke_ (xef4@epilogue.org) joined #forth 07:05:04 --- join: mechanip1ter (~alan@188.166.100.122) joined #forth 07:05:12 --- join: dzho_ (~dzho@unaffiliated/dzho) joined #forth 07:06:15 but 'rdrop recy 07:06:33 I cannot bloody type 07:07:27 'rdrop recurse' is practically tail recursive ;) 07:08:47 --- join: ecraven- (~ecraven@www.nexoid.at) joined #forth 07:10:01 --- quit: koisoke (*.net *.split) 07:10:01 --- quit: mechaniputer (*.net *.split) 07:10:01 --- quit: dzho (*.net *.split) 07:10:01 --- quit: ecraven (*.net *.split) 07:10:02 --- nick: ecraven- -> ecraven 07:10:55 --- quit: dave0 (Quit: dave's not here) 07:21:33 --- join: X-Scale` (~ARM@244.200.137.78.rev.vodafone.pt) joined #forth 07:22:50 --- quit: X-Scale (Ping timeout: 250 seconds) 07:22:51 --- nick: X-Scale` -> X-Scale 07:27:52 --- quit: tabemann (Ping timeout: 252 seconds) 07:36:44 ""Portability is not important. Portability is not possible. Real applications are closely coupled to hardware. Change the platform and all the code changes. If it didn't, you wouldn't have changed the platform." - Chuck Moore 07:37:12 :-/ 07:37:31 "To abstract the problem from the hardware requires massive software like Windows, that's a permanent tax on all applications to save some one-time programming. Programmers should object to job-elimination concepts. Of course, jobs are actually multiplied to deal with the hyper-complex abstraction. And modern hardware has computers in the displays and disks. They've already made many interfaces 07:37:37 portable. How many layers of portability are needed?" [Moore, 2002] 07:38:17 those are the same quote but the first part is what resonates. 07:42:44 yeah - well, don't disagree with the layers and complexity required to support it - but "not possible"? "not important"? 07:43:29 The former, maybe. The latter, probably. 07:44:13 You have to remember Chuck's reality with quotes like that 07:46:39 take something complex like a codec implementation - the first draft in a high level language will undoubtedly be suboptimal, but will be sufficient to iron out the bugs and provide portability (assuming standards of course) - the next revision will likely optimise speciifics in a specific assembly (like, say, intel) - the optimisations should be portable to any intel system 07:47:29 arm and the rest will still be on the slow path, but there's nothing stopping them adding that too and compiling conditionally 07:47:36 "Chuck's reality"? that's a weird way of spelling bubble 07:47:49 he 07:48:11 he lives in a "bubble" now? 07:48:23 the colorForth tools are unning on Wangblows 07:48:32 it's not like he doesn't use computers 07:48:47 there is no "Chuck's reality." There is reality. This is dangerously close to the #MeToo "my truth" nonsense 07:49:42 s/reality/environment/ or s/reality/experience/ and profit 07:49:49 do you lack the faculties required for absract thinking 07:49:58 *abstract 07:50:09 i don't think so 07:51:09 or are you a robot processing every sentence as literal, as if I'm saying he lives in a parallel universe 07:51:19 clearly, chuck does not want to think about "abstract" things either 07:51:24 he doesn't like them 07:51:54 lol. 07:52:01 WilhelmVonWeiner, i'm not an apostle who quotes scripture 07:52:20 it's not scripture 07:52:56 --- nick: mechanip1ter -> mechaniputer 07:53:10 I kinda disagree with blocks vs a filesystem 07:53:10 --- quit: mechaniputer (Changing host) 07:53:10 --- join: mechaniputer (~alan@fsf/member/mechaniputer) joined #forth 07:53:35 --- nick: dzho_ -> dzho 08:01:06 am cursing my filesystem right now - trying to remux a 50GB xdcam MXF (this mpeg2 hd at 50Mb/s) - when the sync occurs like every 5000 frames or so, my entire system grinds to a near halt 08:03:26 When people live by Carmack and Djikstra quotes nobody calls it scripture. It's always 'C' type programmers who seeth with disdain for Chuck 08:03:51 because they can't figure out how to implement a struct 08:04:14 who lives by carmack and djikstra quotes? 08:04:32 about as "low level" as my balls 08:04:41 i'd be just as critical of anyone who did 08:05:00 I see - that's even worse 08:05:06 kekeke 08:05:27 usually i see people repeating quotes from guys like that because there's some comedy to them 08:05:34 programming = occupation/hobby/interest != religion 08:05:35 why even bother learning from smarter people 08:05:57 probably a waste of time 08:06:15 * WilhelmVonWeiner shrugs 08:06:20 the quotes you just posted from chuck are demonstrably false 08:06:25 there's nothing of value to be learned there 08:06:40 "Demonstrably" 08:07:26 yes, this idea that "portable code is a myth" is debunked by almost every piece of user-facing software you use on a daily basis 08:08:26 did you read the rest of the quote 08:08:50 yes, it was nonsensical 08:08:53 i did - it doesn't backup the first part at all 08:08:54 I think you fail to understand what's being said 08:08:59 nah 08:09:13 you're probably a smarter guy 08:09:31 it just says "actually, i'm wrong - it can, but it's suboptimal" - which is fine 08:09:59 not only that but it comes across like he thinks that the reason abstraction exists is to save the programmer some work 08:10:07 this whole idea that everything must be written to be optimal is weird 08:10:31 I think it's just nonsensical and not a quote worth mulling over 08:11:10 me too 08:11:26 #MeToo 08:11:53 brb, suboptimally installing 4MB of javascript to run a text editor so I can use 20 imported left-pad packages 08:12:14 #ifdef Considered Portable 08:47:38 I'm with Chuck and WilhelmVonWeiner on this. Portability & standardization are explicitly anti-innovation. 08:47:38 Trying to prevent people from trying new things or specializing for an application without authorization is an undesirable and pointless undertaking... 08:47:39 ...which is why standards bodies end up including everything they've ever heard of in their standards. Proof that portability is an intractable problem. 08:49:28 you could also argue that lack of portability is also anti-innovation - it'd be a barrier to providing new stuff to many - moot point though - he's clearly wrong when he says it isn't possible 08:49:58 it is possible - he just doesn't like it - not the same thing 08:56:11 If you're making new stuff the same as other stuff in the name of portability then it's no longer new stuff. 08:56:11 Intractable means brute force is the only way, and that's why portable codebases are huge. 08:56:39 the sum of them can be, yes 08:57:38 it's a rhetorical technique called "hyperbole" 08:58:48 sure - certainly qualifies as that 09:18:46 ...Portability through better logical-abstraction sounds better: 09:18:46 Natural unit systems https://en.wikipedia.org/wiki/Geometrized_unit_system for instance, can make physics formulas more readily composable because they won't need as many physical constants as glue/interfacing. 09:18:46 However, I'm not writing everything in straight lambda calculus because getting trapped in the turing tarpit leads to equally bloated code on the other end. https://en.wikipedia.org/wiki/G%C3%B6del%27s_incompleteness_theorems 09:43:55 is there really a problem with large codebases? i mean, most projects which get large tend to be large because they provide a large number of functional points - i don't really think they tend to be large because of portability concerns (barring the case of the codec i cited above which accumulates low level implementations) 09:48:14 from an individuals point of view, i can understand that a large codebase can be daunting, but a large, well organised codebase can have a proper structure which allows involving oneself in specific areas (linux kernel and ffmpeg would be two such projects which spring to mind) 10:14:04 --- quit: dgi (Remote host closed the connection) 10:17:23 --- join: dgi (~dg@s559515c3.adsl.online.nl) joined #forth 10:23:44 --- quit: Zarutian (Read error: Connection reset by peer) 10:24:41 --- join: Zarutian (~zarutian@173-133-17-89.fiber.hringdu.is) joined #forth 10:51:47 --- quit: nighty- (Remote host closed the connection) 11:15:30 --- join: proteusguy (~proteusgu@wsip-70-163-45-233.ks.ks.cox.net) joined #forth 11:15:30 --- mode: ChanServ set +v proteusguy 12:03:40 Ok, assembler is now working, I think, for absolutely all 64 and 32 bit aspects of add or adc sbb and sub xor cmp mov. All addressing modes, including immediate. 12:11:41 --- join: PoppaVic (~PoppaVic@unaffiliated/poppavic) joined #forth 12:11:53 hehehe https://pastebin.com/LtLnYpVx 12:35:01 --- quit: proteusguy (Ping timeout: 246 seconds) 12:37:56 --- quit: dddddd (Ping timeout: 246 seconds) 12:44:14 --- quit: gravicappa (Ping timeout: 246 seconds) 12:55:22 that's working awfully well.. I'm somewhat shocked. 12:59:57 Cool! +1 13:00:02 :-) 13:00:06 Nice job, man. 13:05:17 --- join: dddddd (~dddddd@unaffiliated/dddddd) joined #forth 13:14:08 --- join: dave0 (~dave0@223.072.dsl.syd.iprimus.net.au) joined #forth 13:14:35 hi 13:14:43 Hi dave0. 13:14:51 hi KipIngram 13:15:01 What's cookin'? 13:17:38 not much got my coffee C4[_]~ C8[_]~ C3[_]~ C2[_]~ 13:17:46 KipIngram: how are you? 13:19:14 the_cuckoo: I can agree somewhat 13:19:48 I wouldn't use linux for my example though, 4.4BSD maybe 13:20:23 but, large codebase, maybe you do too much stuff. 13:22:27 https://flak.tedunangst.com/post/features-are-faults-redux 13:25:39 Doing well, dave0. Got a code generator for a big slew of x86 instructions working. 13:26:00 ah cool! 13:26:12 x86 has zillions of instructions 13:26:15 Yeah, I'm working on making my system able to recompile itself. 13:26:18 This is step 1. 13:26:21 aah 13:26:21 I won't be doing all of them. 13:26:38 so an assembler? 13:26:46 This batch includes add or adc sbb and sub xor cmp mov 13:26:57 All 64 and 32 bit variations of them, all addressing modes. 13:27:02 Yes, a "partial" assembler. 13:27:22 Next I want to get XCHG and then some jumps. 13:27:30 And that's probably enough for my needs. 13:28:17 I've got all the facilities to *enter* 16 and 8 bit instructions, and a stub where the code generator for those would go, but no real progress toward encoding them at all. 13:28:44 Damn processor threw me a curve ball. 13:28:59 I was doing my "research" by entering instructions into my source file and assembling with nasm. 13:29:06 Then looking at the listing, and seeking patterns. 13:29:21 i looked up some x86 assemblers 13:29:31 At first it looked like MOV was just totally different for immediate operands - so different there was no way for me to cover that in this basic piece I've written so far. 13:29:42 right now i use gnu as in intel-mode 13:29:54 But then via an online assembler / disassembler site I discovered that (apparently) you can encode those immediate move instructions more than one way. 13:30:02 And the way that that site used was MUCH more compatible with my pattern. 13:30:08 So I finished them off that way. 13:30:14 oh cool! 13:30:47 It's interesting - all the other instructions will store an immediate argument in a single byte if the number is in the right range, and then switch to 32 bits for numbers outside that range. 13:31:02 But MOV doesn't. MOV immediate always uses 32 bits even if 8 bits could represent the number. 13:31:13 For *offsets* it optimizes that, but not for immediates. 13:31:40 there's also a mov with 64-bit constant 13:32:01 i had to use it in primitive 0< and 0> 13:32:06 I could have made my life easier by doing the 32-bit format all the time, but I didn't - this generator will do the single-byte thing when it's applicable, for offsets and immediates. 13:32:20 Oh, interesting. 13:32:29 I didn't know about that one, but I could go take a look see. 13:32:35 Shouldn't be too hard to recognize that. 13:32:55 I can't really imagine ever needing it, though. 13:33:26 i wrote some tight code for 0< and 0> 13:33:57 Nice. Share? 13:34:47 0< mov rax,0x8000000000000000 ; add TOS,rax ; sbb TOS,TOS 13:35:23 I'm really enjoying my screen editor. So much better than anything I've edited blocks with before. 13:35:30 0> mov rax,0x7fffffffffffffff ; sub TOS,1 ; sub TOS,rax ; sbb TOS,TOS 13:35:39 ehehe cool 13:35:59 Oh, hey - that's pretty clever. 13:36:01 0< and 0> use large constants 13:36:02 I like that. 13:36:08 it's tight :-) 13:36:13 It is. 13:36:15 i tested it too, it works 13:36:58 Isn't that constant min-int or something like that? 13:37:01 0<> add TOS,-1 ; sbb TOS,TOS 0= sub TOS,1 ; sbb TOS,TOS 13:37:07 It might be useful to have around as a constant. 13:37:24 Do you have a copy of "Hacker's Delight"? 13:37:24 yeah but i think it's a coincidence 13:37:30 It's just chock full of things like that. 13:37:39 Groovy little trickery. 13:37:41 no but i've seen bit ops! 13:38:12 they count bits by doing mod 99 or something heh 13:38:35 Yes - I bet that's in that book. It's got tons of stuff; it's a gold mine. 13:38:51 You should snag a copy. 13:39:48 it sounds familiar 13:41:00 once i saw a circle-drawing algorithm 13:42:44 Ah, that sounds kind of interesting. 13:42:56 Without the cost of computing all the sines and cosines, I suppose? 13:43:23 The relationship between circles, the exponential function, and complex numbers is pretty fascinating. 13:43:44 If you looked at a plot of e^x over the real line, you'd never dream it had anything to do with circles. 13:43:52 But it does, in a very deep and significant way. 13:44:24 The exponential function is the function that has its slope (it's rate of change) equal to its value. 13:44:25 KipIngram: yeah the circle algo used add and sub in the inner loop, it looked fast 13:44:41 There's a whole family of them, where the slope is *proportional* to the value. 13:44:45 i can't get my head around the math 13:45:17 And a circle is the path you get when you multiply the coordinate (as a complex number) by the square root of -1 to get the rate of change vector. 13:45:35 Euler :) 13:45:44 Yep. 13:46:25 dave0: There's a math thingie out there (very old) called quaternions. 13:46:36 I've read that they can be very useful in computer graphics. 13:46:48 Apparently you can use them to implement 3D rotations without any "pathologies." 13:47:07 i did a bit of that in school 13:47:22 yeah 3d graphics 13:47:40 we had to do a ray tracer.. it's a shame i didn't do tht assignment heh 13:48:00 a game with real-time ray tracing would be awesome 13:49:22 The neat thing about that integer circle drawing algo is that you could put it in an FPGA. 13:49:30 Screaming circles... 13:49:33 Batman. 13:49:51 Sorry - I suddenly just could imagine Robin saying that. :-) 13:50:43 So I shrunk my font size a bit in my Forth window today, so that my editor could show me all 64 lines of my block without scrolling. 13:50:55 It also made the 64-char column narrower - I could get two of them in that window now. 13:51:04 So I'm thinking of adding dual-block support to the editor. 13:51:10 with a key to toggle back and forth. 13:52:06 Whichever one wasn't active I could draw a little dimmer. 14:16:23 --- quit: xek (Ping timeout: 252 seconds) 14:26:09 WilhelmVonWeiner: well, too many features is a possible problem from a large codebase, but that can the case of a small codebase too - i mean, it's easy to write an assembler and run the results - the program is small, the data (ie: the assembly) you would need to give it to do stuff would grow though 14:27:31 KipIngram: can't manage this with Terminator? (I know yer endrunning the OS and terminal apps) 14:28:06 Oh, well, I am using Terminator on my Linux box, but I'm running in a single window there. 14:28:09 Forth is, that is. 14:28:20 On the Mac it's iTerm2, but it's extremely similar. 14:29:23 KipIngram: well, I grok the ENDGAME - but it seems like.... "meh" ;-) 14:29:26 doesnt both pretty much emulate the old Visual Terminals from Data Entry Corporation? That is respond to the apropos CSI ANSI escape sequences? 14:31:09 everyone has ansi escapes - that ain't the point: iterm2 and terminator let you split the window h/v, zoom, etc - so.. In theory you can tell the termwin (from a program) what panes you want, where, sizes, etc 14:32:12 meself have been looking into if I should implement the RFB protocol (The Remote Frame Buffer protocol that VNC uses) 14:37:24 CSI:ANSI is way better than CSI:Miami. (•_•) / ( •_•)>⌐■-■ / (⌐■_■) YEEEEEEEEEAH! 14:38:17 that was nearly as bad as I inflicted to peeps today: Dance the Impe-dance. 14:38:43 it got moves such as the Standing Wave and Relfection 14:40:28 modern problem need modern solutions 14:41:03 presiden: isnt that the motto of Dupont Chemicals? 14:42:27 WilhelmVonWeiner: actually, what is a large codebase anyway? how many lines of code are we talking about? :) is it relative to the language? the functionality provided? does it include the totallity of its dependencies? even if it only uses a fraction of them? 14:42:52 --- part: PoppaVic left #forth 14:43:02 Zarutian, https://knowyourmeme.com/memes/modern-problems-require-modern-solutions 14:43:35 * Zarutian heard that a nominal line of code has something like ten actions/operations. 14:43:54 presiden: dont dissolve my pun that way please 14:52:18 BUT... EVERY problem doesn't require a modern solution. Some things we figured out just fine long ago, and there's no reason to go screwing around with it. 14:56:52 That's a common think you see people do these days - to denigrate and look down on a practice simply because it's old and traditional. 14:56:58 It still might be OPTIMUM. 14:57:03 that may well be true, but don't we have to identify the ones we do need to screw about with? by, you know, considering alternatives? (and the passport thing is probably my best bet for escaping the ramifications of one particular modern 'solution' which isn't working at all...) 14:57:21 Of course we do. 14:57:32 If we have a poor solution to a problem, we should look for a better one. 14:57:45 I just think that people get carried away a lot of times, that's all. 14:57:51 There's something to be said for tradition. 14:58:07 how do we identify which are which without considering alternatives for everything? :) 14:58:20 The tech progress we've made virtually guarantees that a lot of problems are now amenable to better solutions. 14:58:55 I didn't say don't consider alternatives. Just prove that they are truly better than the traditional way, before insisting we have to change just because the standing solution is old. 14:59:10 There needs to be an objective criterion by which you can argue the new solution is better. 14:59:15 It needs to pay its way. 14:59:37 My only point here is that "old" is not *inherently bad*. 15:01:44 agreed - and i wasn't suggesting we would replace a working solution with a non-working one 15:02:01 or indeed a poorly working one 15:03:07 just mean that there should always be a movement which is looking to overturn tradition, even if traditions ultimately survive :) 15:03:42 the_cuckoo: I don't know about lines of code as a metric. "Large" is problem-specific 15:04:02 WilhelmVonWeiner: fair 15:04:14 I don't even like saying it that way. 15:04:27 It implies tradition is bad and wrong, and that is a facet of the modern leftist argument. 15:04:35 *Solve* *Problems*. 15:04:43 We can express this in clean engineering terms. 15:04:48 Look for a problem. 15:04:53 When you find one, work on solving it. 15:04:56 That will get us there. 15:05:24 I think that's a mischaracterisation of the left, no matter how wrong they are 15:05:40 I would say that it's on you to prove there is a problem in a particular domain - not on the current solution to prove there's not one. 15:05:45 KipIngram: well, some tradition is :) - some isn't - but probably best not get into specifics of what we agree with and disagree with in here - probably way off topic :) 15:06:17 i prefer the code metric thread :) 15:06:33 ? What is the code metric thread? 15:06:51 acceptable lines of code in a give codebase 15:07:02 Oh. I hate loc as a metric. 15:07:05 Well, wait. 15:07:08 What thread? 15:07:18 But also LOC sucks my Wilhelm 15:07:26 I think it's probably ok for measuring the amount of stuff that's associated with some situation. 15:07:30 Afer writing Forth I realised how LOC is so pointless 15:07:34 I object to it being used as a metric of programmer productivity. 15:07:41 So I object to loc/day, and all such. 15:07:53 yeah - that's rubbitsh for sure 15:07:54 It encourages you not to THINK about your problem before you start coding. 15:07:56 And that's bad. 15:08:02 LO 15:08:16 Sometimes you WANT to see your programmer looking at his ceiling with his feet on his desk. 15:08:16 and behold 15:08:20 yeah - and i always think the fewer the lines the better anyway 15:08:21 Provided he's thinking about the right stuff. 15:08:35 There's a great cartoon in Thinking Forth. 15:08:39 Let me see if I can find it... 15:08:42 (as long as the lines are clear that is :)) 15:08:54 oh well 15:09:38 the_cuckoo is approaching APL levels with the symbolic words 15:09:48 :D 15:10:10 i have no idea what APL is though :p - and i've never touched haskell 15:10:33 Well, I can't find it. But anyway, throughout TF the "antagonist" is "Wiggins." He's the "traditional programmer." In this one scene, our hero is standing there with a stack of program listing about a quarter inch thick, while Wiggins has a > 1 foot tall listing. 15:10:34 APL is awesome 15:10:42 it is SO cool 15:10:48 it's sort of the opposite of forth 15:10:49 The manager is chastising our guy, saying "Why don't you ever write *serious* programs like Wiggins here???" 15:11:07 prefix oriented? 15:11:12 only writing funny programs? 15:11:13 Oh, APL was an old language for scientific / numerical work. 15:11:14 I wouldn't compare apl and forth 15:11:28 the_cuckoo: https://www.youtube.com/watch?v=a9xAKttWgP4 15:11:33 Supposedly extremely efficient in terms of amount of code entered to solve any particular problem. 15:11:41 did it really survive past the early 80's? 15:11:55 just like us forthers 15:11:57 Dyalog still offers services and special keyboards, i think 15:11:58 I haven't seen real references in decades. 15:12:00 there are aplers 15:12:06 corecode: ah :) - cool :D - will watch the rest later 15:12:08 twitter has a lot 15:13:59 for context, corecode is criticising my case statement :D - https://gitlab.com/lilo_booter/rpany/blob/master/README.md#cases 15:14:21 i went for abstract :) 15:16:15 case statements to me always seem like a function would just do it better 15:16:19 was just looking at the codebase for the open source side of the video framework i've been working on for... hm.. about 14 years i think - 100k c++ 15:16:34 is that big? 15:16:40 yes 15:17:01 even without knowing the functions it provides? 15:17:04 100 lines is tiny, 1k lines is small, 10k is medium, 100k is big 15:17:06 yes 15:17:17 cool :) 15:17:28 it might be small for what it does 15:17:33 but it's still big 15:18:43 bigger than i would have wanted, but it's mostly plugins - plugins are loaded on demand 15:21:04 i do think for what it covers and for the number of devs working on it over the years, it's still pretty manageable 17:06:37 --- quit: dddddd (Ping timeout: 246 seconds) 17:11:37 --- join: dddddd (~dddddd@unaffiliated/dddddd) joined #forth 17:42:13 --- quit: john_cephalopoda (Ping timeout: 252 seconds) 17:56:05 --- join: john_cephalopoda (~john@unaffiliated/john-cephalopoda/x-6407167) joined #forth 18:23:21 --- join: tabemann (~travisb@h193.235.138.40.static.ip.windstream.net) joined #forth 18:40:21 --- join: PoppaVic (~PoppaVic@unaffiliated/poppavic) joined #forth 19:24:34 Do any of you guys have any ideas for a really thorough way to test this code generator? So far I've been just keying in instruction which prints my bytes, and then keying in the corresponding instruction on this assembly website I use. Then visually compare the generated bytes. 19:24:48 It's a certain test, but good grief - there are so MANY instructions. 19:25:02 I have a pretty good feel for the "cases" and I'm trying to touch on all of them. 19:27:25 --- quit: dddddd (Remote host closed the connection) 19:31:46 KipIngram: convert some C to asm (-S) and feed it in? 19:32:11 you'd have to cvt the .s file, sadly 19:33:28 Well, I suppose I could write a C program to generate a bunch of instruction in both formats, assemble the regular format with nasm, extract the listing bytes, feed the others into my Forth and capture those bytes, an compare. 19:33:54 I suspect that's my best short. 19:51:08 i generated a bunch of permutations for each instruction, assembled it with gas and saved the binary form (disassembled it with objdump and manipulated the output), and then compared that to what my assembler generated 19:51:53 it's kind of tedious and obviously it can fail if you don't encode exactly the same way 19:52:38 e.g., add %eax, %edx can be encoded two different ways 19:52:52 --- quit: dave0 (Quit: dave's not here) 19:58:04 Yes - that's the sort of thing I have in mind. 19:58:07 It will get me there. 19:58:11 But... yuck. :-) 19:58:23 Of course, the thrill when it passes is likely worth it. 19:58:54 I already ran into one set of instruction that can encode two different ways. 19:59:43 I think the effort is worth it. 20:04:21 --- quit: tabemann (Ping timeout: 252 seconds) 20:18:00 --- join: nighty- (~nighty@b157153.ppp.asahi-net.or.jp) joined #forth 20:24:56 --- join: tabemann (~travisb@2600:1700:7990:24e0:6112:d47b:3dbc:b8d7) joined #forth 20:32:17 --- join: gravicappa (~gravicapp@h109-187-192-183.dyn.bashtel.ru) joined #forth 22:41:39 --- quit: Zarutian (Ping timeout: 252 seconds) 23:25:11 KipIngram: Walter Bright used this feature of the 80x86 family to catch people who used his Datalight compiler's library without paying royalties. 23:25:41 Since there were several ways to encode several instructions, he had a pattern of encodings he used that was like a fingerprint of his code generator. 23:50:27 --- join: proteusguy (~proteusgu@2600:1700:9b70:2e90:d8bb:60d:6b31:54e) joined #forth 23:50:27 --- mode: ChanServ set +v proteusguy 23:59:59 --- log: ended forth/19.03.12