00:00:00 --- log: started forth/06.07.14 00:00:58 "A nuclear bomb falls exactly on the ground zero." 00:01:38 "Student, justify why you have come to class wearing pants of our most probable military opponent!" (here the teacher means jeans made in USA) The right answer, as mentioned sometimes, is: "Because they are a probable war trophy." 00:02:43 What do you call one Ukrainian? --A partisan. What do you call two Ukrainians? --A partisan cell. What do you call three Ukrainians? --A partisan cell with a traitor in their midst. 00:02:46 I'll stop now. 00:59:44 --- quit: virl (Remote closed the connection) 01:32:32 --- join: zak_ (n=zak@073.a.001.beg.iprimus.net.au) joined #forth 01:33:57 anyone know of any benchmarks regarding different types of threading vs each other and vs native compiled code? 01:34:08 on modern x86 systems 01:39:25 --- nick: zak_ -> llama32 02:16:13 you can do the rediculous recursive fibbinocci algorithm 02:18:24 something like: : fib ( x -- y ) dup 2 < if exit then dup 1 - recurse swap 2 - tail-recurse ; 02:18:40 something like: : fib ( x -- y ) dup 2 < if exit then dup 1 - recurse swap 2 - tail-recurse + ; 02:19:12 something like: : fib ( x -- y ) dup 2 < if exit then dup 1 - recurse swap 2 - recurse + ; 02:20:12 this takes emense amounts of cpu time 02:21:13 for something that could be coded with something fast like this: : fib 0 swap 1 swap for tuck + next + ; 03:07:12 --- join: virsys (n=virsys@or-71-53-74-48.dhcp.embarqhsd.net) joined #forth 03:13:42 --- join: IPmonger (n=ipmonger@c-68-84-208-206.hsd1.pa.comcast.net) joined #forth 04:04:41 --- join: vatic (n=charlest@ool-45740b1c.dyn.optonline.net) joined #forth 04:34:51 --- join: nighty (n=nighty@66-163-28-100.ip.tor.radiant.net) joined #forth 04:47:45 --- join: vatic_ (n=charlest@146.96.190.1) joined #forth 04:50:31 --- join: madgarden (n=madgarde@Toronto-HSE-ppp3708723.sympatico.ca) joined #forth 04:52:59 --- quit: vatic (Read error: 104 (Connection reset by peer)) 05:03:03 --- join: vatic__ (n=charlest@ool-45740b1c.dyn.optonline.net) joined #forth 05:03:07 --- nick: vatic__ -> vatic 05:06:09 --- join: tathi (n=josh@pdpc/supporter/bronze/tathi) joined #forth 05:10:28 --- quit: vatic_ (Read error: 110 (Connection timed out)) 05:18:59 --- quit: IPmonger ("This computer has gone to sleep") 05:28:50 --- quit: vatic (Remote closed the connection) 05:31:36 --- quit: llama32 (Read error: 104 (Connection reset by peer)) 05:35:46 --- join: PoppaVic (n=pete@0-1pool47-115.nas30.chicago4.il.us.da.qwest.net) joined #forth 05:38:32 --- join: llama32 (n=zak@076.a.001.beg.iprimus.net.au) joined #forth 06:03:57 --- join: virl (n=virl@chello062178085149.1.12.vie.surfer.at) joined #forth 06:08:15 --- join: Ray_work (n=Raystm2@199.227.227.26) joined #forth 06:43:03 --- join: IPmonger (n=ipmonger@c-68-84-208-206.hsd1.pa.comcast.net) joined #forth 08:13:22 --- quit: llama32 ("Leaving") 08:25:17 --- join: sans (n=sans@ACBD3F12.ipt.aol.com) joined #forth 08:25:21 hi 08:37:28 --- quit: sans ("Leaving") 09:00:11 --- join: swsch (n=stefan@pdpc/supporter/sustaining/swsch) joined #forth 09:10:36 swsch: Hi. 09:10:50 Hi Ray_work, how's life? 09:11:19 Life is not worth dying for. 09:11:24 hehe. 09:12:16 how's your life? 09:12:21 yer alive? Yer already dead 09:12:31 ...leave docs and backups 09:12:32 already. yup. 09:12:35 will do. 09:12:43 hehe. 09:12:58 Folks never understand that 09:13:10 Dead folks? 09:13:19 Is it any wonder? 09:13:25 otoh, they never understand "I expect the universe to die when I do" 09:13:54 first it's: NO WHERE then NOW HERE then NO WHERE again. 09:14:08 Are you still alove when I log out? When I die? PROVE IT. 09:14:15 right. 09:14:18 alove/alive 09:14:23 right. 09:14:48 otoh, if it takes no more than a few pages of text to protect-against, go for it. 09:15:26 ...hell, you may come back and be PISSED ;-) 09:16:13 Hmmm, A business online that keeps memorials of everybody. Something you can update till you die, then the biz keeps modulateing to the new storage tech for eternity. 09:16:14 Ray_work: contexts and The Matrix - and the latter I was thinking about looong before a few films ;-) 09:17:20 no, if you "leave" you want some person/entity to hold the doc we spoke of - they may no longer exist from yer viewpoint, but We may be fooled by the process ;-) 09:18:00 maybe the "process" is "the videogame" ;-) 09:18:32 ..maybe you will rejoin the "game-in-progress" ;-) 09:19:08 metaphysics, well - it beats "religion" ;-) 09:19:10 --- join: JasonWoo1 (n=jason@c-71-192-33-206.hsd1.ma.comcast.net) joined #forth 09:19:35 --- quit: JasonWoof (Nick collision from services.) 09:19:45 --- nick: JasonWoo1 -> JasonWoof 09:19:56 --- mode: ChanServ set +o JasonWoof 09:20:07 You know what's odd? as a teeny-bopper, none of that mattered to me. 09:20:47 it matters just a "life-blows, CYA" bit more now. 09:21:37 Ray_work: it's very nearly either "don't care" or "well, we can hope" 09:21:43 ..a cusp 09:23:24 besides, I already _believe_ "Suicide" just raises yer taxation: I suspect you can't beat the IRS by "dying". 09:24:02 (otherwise, we'd not see suicide as a "crime") 09:24:42 --- quit: PoppaVic ("Stay well, folks - off to prep dinners") 09:25:47 * swsch comes back 09:26:04 just as soon as I start chatting, family requests attention. 09:26:25 otherwise: same ol', same ol'. 09:26:42 too much work, not enough in forth. 09:27:22 but there might be something coming ... interface to weighing equipment, massaging input data. simple, interesting and helpful to people. 09:58:16 sounds fun. 09:58:22 * Ray_work wishes he were a programmer. 10:02:40 are you the guy who did a chess program in colorforth or are you not? 10:05:44 he is 10:07:37 then he has no excuse to *not* call himself a programmer :-) 10:07:44 heard that Ray_work ? 11:18:49 --- quit: Quartus () 11:24:21 --- join: neceve (n=claudiu@unaffiliated/neceve) joined #forth 12:16:26 --- join: LOOP-HOG (n=jason@66.213.202.50) joined #forth 12:40:01 --- join: hrmpf (n=obi@gw.mastmoen.no) joined #forth 13:06:43 --- quit: hrmpf ("whatever u do, do it right!") 13:21:43 --- quit: tathi ("leaving") 13:27:32 --- quit: LOOP-HOG ("Leaving") 13:29:36 --- quit: madwork (Read error: 104 (Connection reset by peer)) 13:31:05 --- join: madwork (n=foo@derby.metrics.com) joined #forth 14:22:55 --- quit: swsch ("Leaving") 14:29:20 --- join: vatic (n=charlest@ool-45740b1c.dyn.optonline.net) joined #forth 14:41:14 --- quit: nighty (Read error: 113 (No route to host)) 14:58:24 --- quit: neceve ("Leaving") 15:08:13 --- quit: Ray_work ("User pushed the X - because it's Xtra, baby") 15:16:58 --- join: I440r (n=mark4@24-177-235-246.dhcp.gnvl.sc.charter.com) joined #forth 15:39:26 brb 15:39:29 --- quit: I440r ("Leaving") 15:53:38 --- join: I440r (n=mark4@24-177-235-246.dhcp.gnvl.sc.charter.com) joined #forth 16:23:49 --- join: Quartus (n=trailer@CPE0001023f6e4f-CM013349902843.cpe.net.cable.rogers.com) joined #forth 16:33:23 Hey. 16:37:39 --- join: segher_ (n=segher@dslb-084-056-146-252.pools.arcor-ip.net) joined #forth 16:38:53 --- join: crc (n=crc@pool-70-16-148-97.phil.east.verizon.net) joined #forth 16:39:30 --- mode: ChanServ set +o crc 16:47:47 --- quit: segher (Read error: 110 (Connection timed out)) 16:52:02 --- nick: segher_ -> segher 17:09:36 --- join: ASau (n=user@home-pool-170-3.com2com.ru) joined #forth 18:38:30 --- quit: virl (Remote closed the connection) 18:56:14 --- quit: uiuiuiu (Read error: 104 (Connection reset by peer)) 19:01:18 --- join: uiuiuiu (i=ian@dslb-084-056-228-179.pools.arcor-ip.net) joined #forth 19:28:43 --- join: snoopy_1711 (i=snoopy_1@dslb-084-058-136-123.pools.arcor-ip.net) joined #forth 19:36:10 --- quit: Snoopy42 (Read error: 145 (Connection timed out)) 19:36:18 --- nick: snoopy_1711 -> Snoopy42 19:48:02 --- quit: IPmonger ("Leaving") 20:10:21 --- quit: vatic ("Chatzilla 0.9.71 [Firefox 1.5.0.4/2006050817]") 20:58:17 --- join: tattrdkat (n=virsys@or-71-53-74-48.dhcp.embarqhsd.net) joined #forth 21:06:50 --- join: Mum (n=chatzill@host-84-9-28-78.bulldogdsl.com) joined #forth 21:06:58 hello all. Im fixing my comp with MS recovery console and was wondering, how do u copy files off the xp setup disk that are within compressed archives? 21:07:01 --- nick: Mum -> JimD 21:07:14 --- nick: JimD -> JIMMYD5432 21:13:44 --- quit: virsys (Read error: 110 (Connection timed out)) 21:23:53 --- join: virsys (n=virsys@or-71-53-74-48.dhcp.embarqhsd.net) joined #forth 21:35:03 Uh, JIMMYD5432, you are in the wrong place for Windows XP advice. 21:35:07 --- quit: ASau (Read error: 104 (Connection reset by peer)) 21:36:25 --- quit: tattrdkat (Read error: 110 (Connection timed out)) 21:38:45 --- quit: JIMMYD5432 ("Chatzilla 0.9.74 [Firefox 1.5.0.4/2006050817]") 21:39:56 --- quit: I440r ("Leaving") 22:34:07 http://paste.lisp.org/display/22624 22:35:06 tutorial-ness sabotaged by my not having solved the problem before I started. The final implementation is sudden there, but I had a few iterations that could've been commented on. /me shrugs. 22:43:50 Not surprisngly, I'm sure, there's a whole buncha things I'd change. :) 22:49:02 how would you do it? I'd guess that the next step would be to emit Forth that only creates the table and the final FIB 22:49:47 I haven't gotten as far as looking at the actual method. 22:51:38 the actual method commas N FIB , with ever-increasing N , until overflow in the calculation. 22:51:45 Ok. 22:53:41 You might want to add that as one of the comments. 22:53:57 \ How about building the table as we go? 22:54:34 Which doesn't say that it commas N FIB, with ever-increasing N, until overflow in the calculation. 22:55:05 : build-that-damn-table 0 1 BEGIN dup , tuck + 2dup u<= WHILE REPEAT 2drop ; CREATE fibs build-that-damn-table 22:55:34 here fibs - 1 cells / CONSTANT nfibs 22:55:40 and that's all 22:55:43 The comment not being there isn't my largest complaint with the code by any means. 22:56:01 oh, what's your largest complaint? 22:56:31 segher - yow 22:56:32 For starters, nomenclature. $ as a prefix for a throw code. ! prefixed to mean, I presume, 'not'. 22:56:53 well u> UNTIL of course, not u<= WHILE REPEAT 22:56:57 well, ! is very alarming, so !an-exception 22:57:11 ! says 'store' in Forth, it's confusing. 22:58:17 Also, carriage returns are free, and it needs some CR love. Verticalize. Throw in an occasional comment, maybe a stack diagram here and there for the more convoluted parts. 22:58:20 0 x within is normally spelled x u< 23:00:00 Of course, if you actually want to generate a Fib table for some reason (what are those ever used for?), segher's method is a lot shorter. :) 23:00:03 convoluted where? I only see maybe a ( u ) at the end of the first line of the final (fib) , and maybe a pair of stack comments to name (fib)'s return in build-fib-t to show that it reaching , 23:00:31 I know, it's hard for you to see where and why, as you wrote the code. 23:00:35 yes, segher's is much better. 23:00:44 of course :-) 23:01:13 i'm a mathematician, and foreth programming is my job 23:01:28 You're quite fond of using the 'exception' facility in gforth, but I think an abort" would be much clearer in the code. 23:01:30 so heh, don't ask me for fibonaccit stuff 23:02:50 now... write an arbitrary precision fib function, calculate F_n for n <= 1_000_000_000 23:03:14 well, I let errors that aren't !fib-domain pass through BUILD-FIB-T 23:03:36 abort" wouldn't change any of that. 23:04:10 quartus: only difference is that the caller cannot catch a specific error code 23:04:22 It would just replace all the s"..." exception ... if !whatever throw then with abort" fib domain exceeded" 23:04:23 segher - I'd use FSL's bignums 23:04:24 which in this case would be nonsense anyway 23:04:49 segher, the way it is the caller would have to know the exception code generated in this fib code specifically anyway. 23:05:04 ayrnieu: there's a better algorithm, but that should work okay yes 23:05:14 quartus: yes 23:05:29 quartus: it's called !fib-domain 23:06:08 Even if you could argue practicality in using 'exception' (which I don't think there's a strong case for), building it into a simple tutorial like this is completely unnecessary, and comes at an additional cost of making it gforth-only. 23:06:09 but if any code should expect errors from the fib function, the function should just return an error code, not throw an exception 23:06:33 Yes, I'd suggest that the whole business of using CATCH to generate each successive number is a bad idea. Really inefficient. 23:07:03 can't do otherwise when you use the recursive fib , though :-) 23:07:19 sure you can 23:07:31 just put the catch _outside_ of the loop 23:07:43 just like java handles arrays 23:08:30 shit. i just admitted knowing java. no one heard this, right? 23:08:38 segher - it's logged forever. 23:08:47 argh 23:09:54 if you hadn't said "i just admitted knowing java", you could've played it off. 23:10:23 well okay. but i don't know basic! 23:10:46 "i ['] (fib) catch dup !fib-domain = if 2drop unloop exit then throw" actually makes me cry a little. 23:11:08 :-) 23:14:12 I blame myself, for losing sight of the problem and for treating the given fib implementation as sacrosanct. 23:14:15 just a little eh? 23:14:25 You know, it really does. 23:14:45 That one line is about nine things that Forth shouldn't be. :) Sorry, ayrnieu. 23:16:16 even if it was : build-fib-t 0 begin dup 1+ (fib) , #fib-t 1+ to #fib-t again ; , I'd still have a nasty-looking test on the CATCH outside. 23:18:32 Not as nasty as the one that's there. 23:19:52 To stick with your naming habits: 23:19:55 : build-fib-t ['] (build-fib-t) catch dup !fib-domain <> and throw ; 23:20:24 I hate the !fib-domain a lot, and I'm not big on the (factor) naming. 23:20:57 Also, if you're going to haul 'build-fib-t' up the hill, spell out 'table'. 23:20:59 (internal), (randomly-intermediate) ; how do you name them? 23:21:44 I hope to give them their own meaningful names, only resorting to () if nothing better comes up. But I try. 23:23:09 well, there's some dissonance there. I expected to implement final FIB in terms of (FIB) , but realized that I'd already tested fibbed? away. 23:23:55 : (/) ASM HERE ; : / dup 0= abort (/) ; 23:24:21 The naming and factoring is not always the easiest part of the job, but when you get it right you can feel it. Like the other night when we improved your preamble code. 23:24:35 dup 0= abort just aborts. 23:25:18 oh, right. 23:26:16 I'd name '(/)' as 'divide', possibly as 'floored-divide' or 'symmetrical-divide', depending on what it actually is. I'd never have / check for 0, if the application needs that (and it's not trapped by hardware in a useful way) it can wrap it accordingly. 23:26:59 anyway, /me sets this file on fire 23:27:10 So in fact that would eliminate the earlier naming of 'divide', as I'd just call it / . :) 23:32:46 i often name the factor the same as the bigger thing 23:32:53 yeah bad habit i know 23:33:37 but just fine in this "/" example 23:33:59 both words have the same semantics, the later one is more general though 23:38:50 the latter has different exceptional behavior 23:40:48 sure 23:40:55 that's the whole point, eh? 23:42:42 yes, but I hadn't thought of it before in those terms. 23:59:59 --- log: ended forth/06.07.14