00:00:00 --- log: started forth/01.06.12 00:46:31 --- nick: adugone -> adu 01:37:45 hi 01:37:58 --- part: adu left #forth 01:37:58 --- join: adu (andrew@adsl-63-201-89-121.dsl.snfc21.pacbell.net) joined #forth 03:09:22 * aaronl is away: Yawn 03:41:33 hi 03:41:41 bye 03:41:45 --- quit: adu (IRCStep) 06:39:55 --- quit: aaronl (farmer.openprojects.net benford.openprojects.net) 07:23:23 --- join: grurp (grurp@pc19987.batc.tec.ut.us) joined #forth 08:05:10 --- join: cleverdra (jfondren@1Cust89.tnt4.florence.sc.da.uu.net) joined #forth 08:11:32 --- quit: grurp (Bye all) 08:24:02 --- join: cleverser (jfondren@1Cust251.tnt2.florence.sc.da.uu.net) joined #forth 08:25:15 --- quit: cleverdra (Ping timeout for cleverdra[1Cust89.tnt4.florence.sc.da.uu.net]) 08:25:21 --- nick: cleverser -> cleverdra 08:38:28 Good morning, cleverdra. 08:41:21 g'morning, Trey. 08:42:39 I went to add PCI bus support to Enth, only to find that Sean left out the 16 and 32 bit I/O primatives. 08:44:03 Yes, he doesn't have a general assembly-level access to the machine built in yet, which is why I haven't tried to get an IDE disk or NIC working with Enth. SASM should help that, which is actually in his version of Enth but not yet released. 08:44:13 This is why some people have daily snapshots, ne? =) 08:44:17 :-) 08:44:43 He offered me a version of SASM, and I accepted but I haven't received it yet. 08:46:07 Cool. 08:47:12 Perhap he'll just roll out what he's got. It seems to take him about 24hrs to respond to Emails, so I won't know until later today. 08:50:31 cleverdra: have you signed up for his Enth mailing list? 08:51:00 Yes, though it doesn't get much traffic and I don't check it much. 08:51:08 I don't check it frequently. 08:51:23 You have to "check it"? 08:51:43 (you funnel it to a separate in-box, I suppose?) 08:53:00 My personal computer isn't on the 'net, so I have to actually make an effort to check my email, Trey. 08:53:48 Ah. 08:53:54 * Trey feels spoiled. 08:55:35 Yes, I used to feel spoiled like that. 08:55:57 I wanted to use the Enth mailing list to come to some kind of concensus about an appropriate word list for PCI access. 08:56:38 And one day, I shall feel so spoiled again! You know, I've four computers right now, and it's amazing how much you miss simply by not being connected to a global information passing network upon which all your peers are connected and from which your lifeblood comes. 08:56:47 So why don't you, Trey? 08:57:15 I will. I didn't think of it until just a few minutes ago, though :-) 08:57:25 Cool, OK. 08:58:45 Have you come up against the need for a locking API yet? 09:00:08 We'll need one Real Soon Now if multiple folks start writing drivers. 09:02:00 No I haven't, Trey -- but understand that what little OS and hardware knowledge I've gained, I've mostly gained through Forth and Enth specifically. Why would you need a locking API? 09:03:25 * Trey comes from an SMP background, and thinks of this sort of thing on a regular basis. 09:03:58 Well, cool. 09:03:59 Right now, Enth uses cooperative scheduling. 09:04:18 Right. futhin and I have had discussions on that. 09:04:21 (tasks switch only when the programmer says) 09:05:49 So, in theory, we don't _really_ need locking. But it can simplify one's life if you have it. 09:06:11 What do you mean by locking? 09:06:18 Also, if he switches to preemptive scheduling, we will have problems. 09:06:50 You don't want two different threads trying to read/write the PCI bus configuration registers at the same time. 09:07:02 (for example) 09:07:24 Ah, right. OS's with filesystems deal with this in the FS. 09:07:40 They deal with it in a number of places. 09:07:52 Yes, I'm just specifying one that I am strictly aware of. 09:07:56 Right. 09:08:42 In a preemptivly schedules system, something like 'bload bload' would be bad if the editor's FDC stuff works in its own thread, ne? 09:09:16 ...without some kind of locking being done. 09:09:34 If you mean 'bload' in two different threads, both trying to read from the FDC, yes. 09:09:46 The FDC needs to serialize access to the device. 09:10:06 Rather, something needs to serialize access to the device. 09:10:41 It'd be simple for FDC to do that with a FIFO stack of sorts. Are you thinking of a general solution? 09:12:00 Probably something more general. It all depends on where Enth ends up going. 09:13:33 Yeah. login passwords and memory access controls and runtime security checks. Blah. 09:13:41 We probably ought to just work on a PCI wordset first, and see where that leads us. 09:14:44 I don't know if we need all of that stuff for Enth. But a flexible pre-emptive multi-tasker can simplify a programmer's life in some cases. 09:14:45 That sounds like a plan. 09:15:14 I need to bail for an hour or so. Later, all. 09:15:20 * Trey is away: errands, etc. [11:15] 09:15:21 bye Trey. 11:15:49 This forum sure does get a lot of traffic. 11:26:46 The forum off of pringle.sphosting.com? Most of that traffic is mine, with replies 11:40:55 I meant this one. Nary a word between when I left and returned. 11:53:05 Oh. No it doesn't. Somebody mentioned it on clf and that's what brought be here, but others don't seem to be in the coming. 12:03:28 --- join: aaronl (aaronl@vitelus.com) joined #forth 12:08:17 --- quit: aaronl (zelazny.openprojects.net farmer.openprojects.net) 12:08:20 --- topic: set to 'http://isforth.sourceforge.net -- http://cvs.sourceforge.net/cgi-bin/cvsweb.cgi/isforth/?cvsroot=isforth' by ChanServ 12:08:28 --- mode: ChanServ set mode: -o Trey 12:08:28 --- mode: ChanServ set mode: -o lar1 12:08:28 --- mode: ChanServ set mode: -o clog 12:08:34 --- join: aaronl (aaronl@vitelus.com) joined #forth 12:09:07 --- quit: aaronl (simak.openprojects.net farmer.openprojects.net) 12:10:46 --- join: aaronl (aaronl@vitelus.com) joined #forth 12:20:44 --- quit: cleverdra (Ping timeout for cleverdra[1Cust251.tnt2.florence.sc.da.uu.net]) 12:21:43 --- join: cleverdra (jfondren@1Cust243.tnt4.florence.sc.da.uu.net) joined #forth 12:40:54 * aaronl is away: breakfast 12:56:38 --- join: grurp (grurp@pc19976.batc.tec.ut.us) joined #forth 13:09:15 --- quit: cleverdra (Ping timeout for cleverdra[1Cust243.tnt4.florence.sc.da.uu.net]) 13:12:43 --- join: cleverdra (jfondren@1Cust149.tnt3.florence.sc.da.uu.net) joined #forth 13:29:07 --- quit: grurp (Bye all) 13:30:18 * aaronl is back (gone 00:49:24) 13:56:26 --- join: dired (infobot@adsl-207-214-111-232.dsl.snfc21.pacbell.net) joined #forth 13:56:53 --- quit: dired (regrouping; bbiab) 14:17:09 --- join: dired (aaronl@vitelus.com) joined #forth 14:17:21 --- quit: dired (Read error to dired[vitelus.com]: EOF from client) 14:18:23 --- join: dired (aaronl@vitelus.com) joined #forth 14:19:14 --- quit: dired (regrouping; bbiab) 14:19:35 --- join: dired (aaronl@vitelus.com) joined #forth 14:19:39 --- quit: dired (regrouping; bbiab) 14:20:09 --- join: dired (aaronl@vitelus.com) joined #forth 14:20:12 dired: emacs? 14:20:12 it has been said that emacs is /ee'maks/ [from Editing MACroS] n. The ne plus ultra of hacker editors, a program editor with an entire LISP system inside it. It was originally written by Richard Stallman in TECO under {ITS} at the MIT AI lab, but the most widely used versions now run under UNIX. It includes facilities to run compilation subprocesses and send and receive mail; many hackers spend up to 80% of their {tube time} inside it. Some versions running under 14:25:11 --- quit: dired (regrouping; bbiab) 14:25:16 --- join: dired (aaronl@vitelus.com) joined #forth 14:25:26 * cleverdra looks up. 14:25:29 That's interesting. 14:25:36 dired: forth? 14:25:36 no idea, cleverdra 14:25:50 dired, forth is at www.forth.org 14:25:50 OK, cleverdra. 14:26:00 dired, forth is also at www.ultratechnology.com 14:26:01 okay, cleverdra. 14:26:08 dired, forth is also at www.forth.org.uk 14:26:09 okay, cleverdra. 14:26:16 dired, status? 14:26:16 Since Tue Jun 12 14:25:15 2001, there have been 3 modifications and 1 questions. I have been awake for 1 minute, 1 second this session, and currently reference 5091 factoids. Addressing is in optional mode. 14:26:29 5091? From what? 14:26:30 --- join: futhin (thin@h24-67-113-99.cg.shawcable.net) joined #forth 14:26:37 hello futhin 14:26:37 cleverdra: jargon, mostly 14:26:50 forth? 14:26:50 forth is probably at http://www.forth.org or at http://www.ultratechnology.com or at http://www.forth.org.uk 14:26:53 dired, cleverdra is cleverjulian@hotmail.com -- but he doesn't check it much 14:27:04 aaron - cool. 14:27:11 hello all 14:27:13 dired: FORTH? 14:27:14 FORTH is at http://www.forth.org or at http://www.ultratechnology.com or at http://www.forth.org.uk 14:27:15 hmm 14:27:22 dired: cobol? 14:27:22 cobol is /koh'bol/ [COmmon Business-Oriented Language] n. (Synonymous with evil.) A weak, verbose, and flabby language used by {card walloper}s to do boring mindless things on dinosaur mainframes. Hackers believe all COBOL programmers are suits or {code grinder}s, and no self-respecting hacker will ever admit to having learned the language. Its very name is seldom uttered without ritual expressions of disgust or horror. See also {fear and loathing}, {software rot} 14:27:23 dired, cleverdra =~ s/much/frequently/ 14:27:23 I didn't have anything matching 'cleverdra', cleverdra 14:27:30 erm. 14:27:35 Hah, that's cool. 14:27:49 you know what i find weird.. forth is supposed to be extremely portable, but all these losers keep writing forth in C?!?! 14:27:59 lol 14:28:11 lots of assembly Forth going on too, futhin. 14:28:17 cleverdra: use s/// 14:28:37 brb. Very cool of you to put an infobot in here, aaron =) 14:28:57 Thx :) 14:29:02 cleverdra: yeah, but i'm not sure there are any assembly Forth for windows and linux?? 14:31:32 were older computers stack-based rather than register based? or were they register based from the get-go?? 14:31:38 --- quit: cleverdra (Ping timeout for cleverdra[1Cust149.tnt3.florence.sc.da.uu.net]) 15:15:41 --- quit: dired (Read error to dired[vitelus.com]: EOF from client) 15:16:04 --- join: dired (aaronl@vitelus.com) joined #forth 15:45:32 --- quit: futhin (sleep) 17:19:34 * Trey is away: life, etc. [19:19] 18:21:32 --- join: Chaynez (chaynez@cc461258-b.srst1.fl.home.com) joined #forth 18:21:38 anyone' seen Mark/I440r? 18:28:14 --- nick: aaronl -> aaronl_ 19:27:54 --- join: I440r (mark4@purplecoder.com) joined #forth 19:31:35 hey Mark 19:31:37 u get my ICQ? 19:31:49 nope let me go look :) 19:31:58 s'ok 19:32:05 just point chaynez.purplecoder.com to 24.250.80.13 19:32:24 heh 19:32:30 im takin my sis round her friends house man ill brb 19:32:33 then ill do it :) 19:32:36 Chaynez: do you use forth? 19:32:53 naah 19:32:58 I finally got a copy of Kylix though :) 19:32:59 heh 19:33:01 neither do i :/ 19:33:03 thanks Mark 19:33:16 I want to learn forth but I440r has to finish isforth first :) 19:33:25 Hey Mark.. you know where I can buy a cheap (like $20) PCI Dual Parallel Port card? 19:33:34 I ordered 4 new cams, but my machine's only got one parallel port card :) 19:33:34 heh 19:34:12 --- join: cleverdra (jfondren@1Cust205.tnt6.florence.sc.da.uu.net) joined #forth 19:35:00 dired, status 19:35:01 Since Tue Jun 12 15:15:31 2001, there have been 37 modifications and 4 questions. I have been awake for 4 hours, 19 minutes, 7 seconds this session, and currently reference 5141 factoids. Addressing is in optional mode. 19:35:14 dired, seen futhin 19:35:14 futhin was last seen on #forth 5 hours, 3 minutes and 19 seconds ago, saying: were older computers stack-based rather than register based? or were they register based from the get-go?? [Tue Jun 12 14:31:32 2001] 19:37:40 --- join: cleverser (jfondren@1Cust186.tnt4.florence.sc.da.uu.net) joined #forth 19:39:30 * cleverser pokes cleverdra. Die. 19:39:33 --- quit: cleverdra (Ping timeout for cleverdra[1Cust205.tnt6.florence.sc.da.uu.net]) 19:39:40 --- nick: cleverser -> cleverdra 19:41:32 mmm dired, Enth is at pringle.sphosting.com 19:41:36 dired, Enth is at pringle.sphosting.com 19:41:36 OK, cleverdra. 19:42:04 dired, forths? 19:42:04 cleverdra: i haven't a clue 19:42:19 * cleverdra thinks of a good factoid. 19:44:48 dired, time? 19:44:48 trey: no idea 19:44:55 Hmm. 19:45:13 dired, seen cleverdra? 19:45:14 cleverdra was last seen on #forth 2 minutes and 54 seconds ago, saying: thinks of a good factoid. [Tue Jun 12 19:41:57 2001] 19:45:29 dired, Time is time to get a watch! 19:45:29 OK, Chaynez. 19:45:29 :P 19:45:34 dired, time? 19:45:34 time is time to get a watch! 19:45:37 hee. 19:45:40 heh 19:45:51 dired, date? 19:45:51 trey: i haven't a clue 19:45:54 feh 19:46:02 no dired, time is heh, $who, looks like \you need to get \yourself a watch\! 19:46:02 okay, cleverdra. 19:46:13 hey ppl, what's the time? 19:46:13 dired, time? 19:46:13 heh, Trey, looks like you need to get yourself a watch! 19:46:18 hm. 19:46:26 dired, date is something I haven't had for a while, not since the last one went horribly wrong with the shellfish incident :`( 19:46:26 OK, Chaynez. 19:46:31 dired, date 19:46:31 date is probably something I haven't had for a while, not since the last one went horribly wrong with the shellfish incident :`( 19:46:37 lol 19:46:39 shellfish incident? 19:47:09 a friend of mine.. he was at a restaurant with some friends.. 19:47:18 a few tables away was this gorgeous girl showing off a lot of cleavage... 19:47:30 so they were havin' bets on who could get some crab meat down hear cleavage the first :P 19:48:01 so they were throwin' bits of crab at her for about 15 minutes before the management ejected them 19:48:02 heh 19:48:51 --- join: cleverser (jfondren@1Cust202.tnt3.florence.sc.da.uu.net) joined #forth 19:49:15 shellfish incident, Chaynez? 19:49:23 [03:47:54] a friend of mine.. he was at a restaurant with some friends.. 19:49:23 [03:48:03] a few tables away was this gorgeous girl showing off a lot of cleavage... 19:49:23 [03:48:15] so they were havin' bets on who could get some crab meat down hear cleavage the first :P 19:49:23 [03:48:46] so they were throwin' bits of crab at her for about 15 minutes before the management ejected them 19:49:23 [03:48:47] heh 19:49:25 :) 19:49:39 --- quit: cleverdra (Ping timeout for cleverdra[1Cust186.tnt4.florence.sc.da.uu.net]) 19:50:01 --- nick: cleverser -> cleverdra 19:50:21 purl, shellfish incident is (don't ask) 19:50:23 err. 19:50:26 dired, shellfish incident is (don't ask) 19:50:26 OK, cleverdra. 19:50:29 lol 19:50:44 cleverdra: I still haven't heard back from Sean. 19:51:20 dired, time 19:51:20 heh, Chaynez, looks like you need to get yourself a watch! 19:51:27 lol 19:52:02 hey is this the same bot/script they got on #linuxhelp on Undernet? 19:52:21 dired, help? 19:52:34 trey - hm. I think he gets on the net/(checks things) at 12PM EST -- at least, that's one time I definitely know that he once checked the forum. Hopefully he's doing some important work with Enth or Flux, and is too tired to do anything else. Sigh. 19:52:50 dired, tell chaynez about infobot 19:52:59 nice one, tnx cleverdra 19:59:51 ok im back 20:00:00 gimme that ip again :) 20:00:48 just point chaynez.purplecoder.com to 24.250.80.13 20:00:50 24.250.80.13 20:02:16 whats the date today ? 20:02:17 --- quit: cleverdra (Leaving) 20:02:24 12th 20:02:29 13th in another hour or so though 20:03:46 not here :) 20:05:14 do this 20:05:25 nslookup chaynez.purplecoder.com purplecoder.com 20:05:40 that says use purplecoders name server to look up that address 20:06:25 i dont know if im supposed to do this or not but i dont know why not :) 20:06:31 let me know if the IP changes 20:07:08 by doing the above nslookup you force propogation of the name too 20:07:24 have all ur friends do that too and it will propogate nicely :) 20:07:55 * aaronl_ does it 20:08:12 BTW, my name server has it now :) 20:08:21 :) 20:08:57 see if i get any nasty letters off my isp hhe 20:09:00 aight nice one 20:09:01 my isp is secondary 20:09:08 all my friends ain't usin' Linux :) 20:09:09 heh 20:09:13 I440r: ? 20:09:17 but it's cool 20:09:21 oh hehe 20:09:22 they normally charge for doing name service but because i asked if i can do my own i dont get charged :))))) 20:09:27 Heheh 20:09:34 :) 20:09:38 my ISP runs my secondary nameservice too 20:09:40 (i run primary) 20:09:42 they can nslookup from windows too if they have it 20:09:50 im promary for my own domain 20:09:50 * Trey has always run his own DNS. 20:11:13 it solves alot of problems ill tell u :) 20:12:35 yeah 20:13:47 ugh c is yucky 20:13:54 c sux 20:13:56 nuff sed 20:14:05 i wish it was lower level 20:14:12 so i didn't have to guess about things like alignment 20:15:15 reverse is a bitch tho 20:15:20 do u do ur own reverse ? 20:15:26 no, my isp does 20:15:28 (fortunately) 20:15:31 yea 20:15:42 do they subnet their ip range to sub class c networks ??? 20:15:47 yes 20:15:48 that REALY makes it a bitch 20:15:51 it does :/ 20:15:58 but they're great to work with 20:16:06 but it IS POSSIBLE if they do it smart... 20:16:16 i couldnt ask for a better isp 20:16:17 ya 20:16:18 me too 20:16:34 my ISP hosts dns and lets me run servers 20:16:37 do you use ipchains or iptables ? 20:16:39 and they're very reliable 20:16:40 so no complaints 20:16:41 iptables 20:16:42 i realy need a firewall 20:17:03 every time i try implement one i get a very nice "blocks everything" firewall 20:17:04 grrrr 20:17:12 So I HATE dealing with incompetent c coders 20:17:13 do yo uuse ipmasqurading ? 20:17:20 thats 99% of them 20:17:20 LOOK at these functions 20:17:21 yes i do 20:17:27 static int 20:17:27 test_bit (char *buf, int bitno) 20:17:27 { 20:17:27 char c, m; 20:17:27 c = buf[bitno / 8]; 20:17:28 bitno = bitno % 8; 20:17:30 bitno = 7 - bitno; 20:17:32 if (!bitno) 20:17:34 m = 1; 20:17:36 else { 20:17:38 m = 2; 20:17:40 while (--bitno) 20:17:42 m *= 2; 20:17:44 } 20:17:46 return c & m; 20:17:48 } 20:17:49 ugh 20:17:50 I replaced that SHIT with: 20:17:54 #define test_bit(buf,bitno) ((buf>>bitno)&1) 20:18:00 apparently the person who wrote it had never heard of shifts :P 20:18:07 (LOOK at that while loop!!) 20:18:11 hehehe 20:18:18 he also wrote an inverse_bit function 20:18:30 that set a bit n to 0 if it was 1 and 1 if it was 0... 20:18:33 he did not use XOR 20:18:37 hehehehe 20:18:41 instead, he anded it with a bitmask 20:18:42 so 20:18:45 a ^= b 20:18:48 b ^= a 20:18:48 i know!!! 20:18:50 a ^= b 20:18:57 would confuse him :) 20:18:59 yeah 20:19:03 i dont think he knows what xor is 20:19:05 erm i missed the ; 20:19:07 bleh 20:19:20 Oh yeah, the best thing was, he didn't really NEED the inverse_bit function 20:19:26 since he was writing code like this: 20:19:26 look on cdrom.comn for some realy nifty functions 20:19:40 like to get the # set bits in a byte 20:20:05 or a routine to bit reverse a buyte... 20:20:07 if (should_be_on && test_bit(buf, n) != 1) 20:20:12 obfuscated but nifty :) 20:20:18 inverse_bit(buf, n); 20:20:21 dont need the =1 part 20:20:34 if (blah && bit) 20:20:36 \{ 20:20:41 else if (!should_be_on && test_bit(buf,n) == 1) 20:20:42 bit_is_set(); 20:20:42 } 20:20:47 inverse_bit(buf, n); 20:20:50 crazy freak 20:21:06 hhehe 20:21:18 basically, he tested the bit, then he tested it again, and tepending on that result he either anded it with the complement or or'd it with the bitmask :P 20:21:21 well, enough of that 20:21:31 heh i've seen some pretty fucked up coders in my day 20:21:35 and i blame most of it on C 20:21:38 u get used to it :P 20:21:41 yup 20:21:46 like, this one person didn't know how a linked list works 20:21:59 so he made a transversal function in O(N^2)!!!!! 20:22:00 erm.. thats basic shit 20:22:39 6 new spam messages 20:22:40 grrr 20:22:42 for (i=0; i != length(LinkedList); i++) { Node *p = get_nth_node(LinkedList, i); operate(p); ... } 20:22:45 heh very stupid 20:23:10 :) 20:23:23 does forth have binary operations? 20:23:42 have you ever seen a 10 page function with a single switch statement where each case was a 10 case switch statement where each case was a 10 case switch statemetn ???? 20:23:43 i have 20:23:45 argh! 20:23:50 yes 20:23:51 and 20:23:52 or 20:23:53 xor 20:23:53 not 20:23:56 cool 20:24:10 anyway i disagree with you on "C style" 20:24:14 like, the post to linux-kernel 20:24:17 and 2* isalways done in asm as a SHIFT in forth 20:24:19 Forth has n-ary operators. 20:24:32 linus didnt like that post :) 20:24:35 hehe 20:24:41 i think that embedding the switch statment is GOOD because otherwise you have a new function and you have to branch for no reason!!! 20:25:04 otherwise you would have to call it, even though there would only be one source of the call 20:25:11 i NEVER use the c switch stattement 20:25:13 AT ALL 20:25:18 do you ever use c? ;-) 20:25:36 there are ways of doing it that dont cost any more time or space but save alot of vertical source space 20:25:40 yes i use c 20:25:50 like what ways of doing in? 20:25:57 can you show me what it would be like in asm? 20:26:18 heh, i guess you're right 20:26:27 because for every case you have to branch anyway... 20:26:28 ok lets say you have a switch statement for different input keys 20:26:30 just C hides that 20:26:32 ok 20:26:55 and each for each key you run a different function 20:27:04 i would do something like the following 20:27:17 let me think this out a second.... been awhile hehe 20:27:20 hehe 20:27:38 typdef struct 20:27:38 { 20:27:45 char key; 20:28:06 void how do you do a pointer to a function here again; 20:28:07 } 20:28:15 ok 20:28:23 that woudl bbe void function how do you do this again ???; 20:28:24 then 20:28:27 er 20:28:31 } options; 20:28:32 then 20:28:49 options vecdtors[] = 20:28:55 key, vector 20:28:57 key, vector 20:28:59 } 20:29:04 cdecl> declare f as pointer to function returning void 20:29:04 void (*f)() 20:29:13 UGLY syntax :( 20:29:21 that sort of thing, make an array of key,vectors pairs 20:29:26 ya i see what you mean 20:29:33 i did that in my bot... 20:29:35 and then u call the function member of the stuct 20:29:38 yes 20:29:39 right/ 20:29:40 ok 20:29:48 the source code to my bot is in /pub 20:29:52 not finished but working 20:30:00 its been ages since i did any of this :P 20:30:06 but u get the ida 20:30:07 also 20:30:31 like i said, the source for my loop is alot smaller than a 10 case switch statement 20:30:34 case a of 20:30:35 alaqeoighs 20:30:36 askfhlksahf 20:30:37 laksdghlkf 20:30:37 asdlfalksf 20:30:39 case b of 20:30:40 a;lkfpsaf 20:30:41 asdlasdj 20:30:42 lsadfkj 20:30:42 aslkdfhhf 20:30:47 bullshit visual clutter 20:30:47 mmmkay 20:31:01 * I440r hates c :P 20:31:05 you know what is even moer evil? 20:31:07 inline asm 20:31:16 * aaronl_ pulls out some that he wrote 20:31:42 __asm__ __volatile__(" 20:31:42 loop: 20:31:42 subq #1, %1 /* Dec loop counter */ 20:31:42 bmi out /* Terminate loop? */ 20:31:42 clr.l %d6 20:31:43 move.b (%2,%1), %d6 /* Get normal char */ 20:31:45 ....... 20:31:52 " 20:31:53 : 20:31:53 : "a" (rot_str), "d" (len), "a" (norm_str) 20:31:53 : "d6", "cc", "memory"); 20:32:02 that is so fucked! 20:33:08 :) 20:33:43 i forget what your stance on commenting was... 20:33:45 i remember it came up 20:34:24 the more you comment your code the better, 20:34:25 well 20:34:35 as long as you comment it properly, not just like.... 20:34:46 mov ax,0 ; move 0 into ax 20:34:48 ugh 20:35:00 Hrm. gcc produced better code using a 'long long' than using a char[]. I think i'll go with the long long, especially since it will produce MUCH better code on some archs 20:35:04 i agree with you completely 20:35:07 and not with linus 20:35:21 write and tell him :P 20:35:45 linus believes that if you cannot understand teh code simply by reading the code youdo not belong in the code 20:35:51 long long is pretty morbid tho 20:36:03 i think comments should be able to help someone who _almost_ can follow and wouldn't otherwise 20:36:46 i think that if you comment it properly and enabled some totally clueless coder to follow your code you have done him a great service 20:36:59 ya me too 20:37:02 aned you might even make him learn a little and eventually become a good coder 20:37:10 i mean, it can even help experts 20:37:30 if you write bizarre code that's highly optimized it helps to have some simple idea of wtf it's doing 20:38:00 Ok 20:38:06 i have a simple assignment for you 20:38:10 i wanna see if you can beat gcc ;-) 20:38:16 very simple function.... 20:39:31 sure 20:39:35 I have a lower longword and an upper longword in ecx and edx respectively 20:39:42 ok 20:39:47 upper in edx 20:40:24 i want to test a certain bit, where 0==last bit of upper word and 63==first bit of lower word 20:40:51 and put either 1 or 0 in eax depending on if it's set 20:40:51 --- join: adu (andrew@adsl-63-201-89-121.dsl.snfc21.pacbell.net) joined #forth 20:41:46 ok you want to move any one of the 64 bits into eax then 20:41:58 umm ya, i guess 20:42:00 where is the parameter 20:42:11 i.e. the bit # 20:42:26 oh, its in eax 20:42:51 and is it expressed as a bit number or as a bit mask 20:42:58 for some reason gcc puts a JUMP in this function!!! i bet you can do better 20:43:00 bit number 20:43:07 e 0==last bit of upper word and 63==first bit of lower word 20:43:33 u got your bit numberings backwards :P 20:43:46 umm, other way is actually easier for me :-) 20:43:57 if you can write code that's >= the speed and efficiency ;-) 20:44:25 ya in fact i think it shouldn't matter 20:44:44 so go with 0== first bit lower longword ... 63 == last bit upper longword 20:45:07 mov eax,1 20:45:11 xchg eax,ecx 20:45:17 shl eax,ecx 20:45:26 oh 20:45:28 erm no 20:45:29 shit 20:45:36 heh 20:45:38 this is a little more complecated 20:45:47 i gotta see which register im testing :) 20:45:48 ok wait 20:45:51 gcc does: 20:45:54 shrdl %edx, %eax 20:45:54 gona write this out by hand :) 20:45:55 sarl %cl, %edx 20:45:57 hehe 20:45:59 thanks 20:46:02 \nononon 20:46:06 dont show me 20:46:08 ok ok :) 20:46:10 * I440r not lookming... 20:46:13 type /clear ;) 20:46:38 is that intel? 20:46:45 0 - 15 is edx, 16 to 31 is eax... yes ? 20:47:12 umm, whatever. i don't care :-) 20:47:17 it's actually taken off the stack ... 20:47:19 or at&t syntax 20:47:28 hrm that shrdl im not familiar with :P 20:47:41 16 up on the stack is lower longword 20:47:42 hrm 20:47:46 12 up on the stack is upper 20:47:54 8 up on the stack is bit number 20:48:15 erm wait 20:48:18 im confused 20:48:24 screw the registers 20:48:24 edx = high dword 20:48:26 eax = count 20:48:31 wheres low dword again ? 20:48:33 do whatever 20:48:37 it's actually all on the stack 20:48:42 gcc was moving them into specific registers 20:48:46 but use your own ... 20:48:48 aha 20:48:49 ok 20:48:51 well 20:49:02 tho, it shouldn't be on the stack if i was using asm 20:49:06 well discount the pops used byu gcc to set the registers 20:49:15 why don't you just pick whatever registers you want and document it/ 20:49:15 yeah 20:49:17 im jhust going to assume that eax is the low word 20:49:20 edx = high 20:49:21 ok 20:49:22 great 20:49:27 and ecx = count 20:49:29 s/word/longword, tho 20:50:09 What is SFENCE? 20:50:16 i'm finding all these instructions i dunno in my book... 20:50:43 o, i see what shrd is 20:50:54 "Dbl precision shift right" 20:51:03 yes 20:51:19 sfence ? 20:51:23 i know wht fense is 20:51:32 wait 20:51:34 thunkin 20:52:15 it says "store fence" 20:52:33 hmm. i don't like how xor is named EOR on m68k 20:53:03 am i allowed to use self modifying code ??? :) 20:53:44 Sure ! :) 20:54:23 tho what gcc does is pretty straightforward. i didn't get it until i looked up shrd, but that instruction is exactly what we need... 20:54:40 mov b[foo+7],cl ; set shift count 20:54:55 jmp foo ; this is needed to flush prefetch 20:54:59 foo: 20:55:05 shrd edx,eax,0 20:55:08 ret 20:55:10 done 20:55:30 wow 20:55:38 does that put 1 or 0 in eax? 20:55:44 oh 20:55:48 youshould prolly do an 20:55:51 hehe 20:55:51 and eax,1 20:55:52 yeah 20:55:56 before the return 20:56:00 also, what's the point of shrd edx,eax,0 20:56:07 isn't the last arg the one of how much to shift? 20:56:22 it shifts the 64 bit edx = high and eax low by the immediate cound of 0 20:56:22 oh, i see 20:56:25 n/m 20:56:31 self-modifying :) i like it ;) 20:56:33 the 0 is overwritten by the shift count you pass 20:56:44 i know... im a heretic 20:56:47 but i admit it :) 20:56:56 isn't there a form that uses CL implicitly? 20:56:56 if ur gona use that i would test it if i were you 20:57:05 hehe 20:57:47 anyway, here's what gcc did (without stack stuff stripped, in INTEL syntax just for u) 20:57:55 erm wait it might not work 20:57:57 test_bit_64: 20:57:57 push %ebp 20:57:57 mov %ebp, %esp 20:57:57 mov %ecx, DWORD PTR [%ebp+16] 20:57:57 mov %edx, DWORD PTR [%ebp+12] 20:57:58 mov %eax, DWORD PTR [%ebp+8] 20:58:00 shrd %eax, %edx, %cl 20:58:02 sar %edx, %cl 20:58:03 and %ecx, 32 20:58:05 je .L2 20:58:07 mov %eax, %edx 20:58:09 .L2: 20:58:11 and %eax, 1 20:58:13 pop %ebp 20:58:16 ret 20:58:57 i don't get why it jumps like that 20:59:46 brb 20:59:52 it wont work 21:00:09 shrd wont allow shifts of beyond 32 bits with an immediate shift count like that 21:00:10 grrr 21:01:27 but that gcc code is fscked....wait :) 21:04:55 well my idea would have worked if shrd reg,reg,immediate wasnt crippled 21:05:45 hehe 21:07:32 have you ever coded on a 64bit arch? 21:07:36 there this would be really simple 21:08:48 yea it would have :) 21:11:00 i think 64bit is overkill for most things 21:11:11 i bet it would be nice for high-precision timing, or databases... 21:11:20 * Trey waits impatiently for AMD 64bit CPUs. 21:16:15 :) 21:22:58 it will be hell to align stuff on 8-byte boundries, and stuff 21:23:07 itanuim has 128 integer registers tho 21:23:09 crazy 21:27:39 If you have a machine with 64bit addresses, you probably have at least a GB of memory to throw around. 21:27:49 tru 21:29:18 erm that depends 21:29:32 just because you have the address space doesnt mean yhou have the addresses :P 21:29:32 Gar 21:29:36 I need a htonll() function 21:29:49 :) 21:30:07 i'm being an idiot 21:30:16 you know those bit offsets i was storing for the 64bit int? 21:30:29 well, the int is being recieved from the network 21:30:36 :) 21:30:45 so the offsets are totally bogus on little endian 21:31:01 hehehehehehe 21:31:17 right? 21:31:23 :) 21:31:31 prolly :P 21:31:34 i mean, i should just ntohll() it when i get it in from the network 21:31:41 * aaronl_ digs up a function to do that from his personal library 21:32:10 ah 21:32:13 /* Host to network 64-bit */ 21:32:13 static u_int64_t hton64 (u_int64_t x) 21:32:13 { 21:32:13 #ifdef M_LITTLE_ENDIAN 21:32:13 if (sizeof(long) == 8) /* also evil */ 21:32:14 return htonl (x); 21:32:16 # ifdef __bswap64 21:32:18 return __bswap64 (x); 21:32:19 # else 21:32:22 { 21:32:23 /* We demand a shrubbery. */ 21:32:25 union { u_int64_t ll; u_int32_t l[2]; } w, r; 21:32:28 w.ll = x; 21:32:29 w.ll = x; 21:32:32 r.l[0] = htonl (w.l[1]); 21:32:34 r.l[1] = htonl (w.l[0]); 21:32:36 return r.ll; 21:32:38 } 21:32:40 # endif 21:32:41 #else 21:32:43 return x; 21:32:45 #endif 21:32:47 } 21:32:51 eh i dont know how that comment got in there :P 21:33:11 how would i compute a bit offset for a big endian quadword? 21:33:37 ? 21:33:39 like, "on a big endian system i know this would be 63 bits to the right, what would it be on this pathetic little endian sys?" 21:33:48 in a quadword 21:35:43 Bits as they sit in memory, or bits when you take the uint64 as a whole? 21:36:25 the latter 21:36:34 i know how it sits in memory -- it is in big endian format by definition 21:40:24 Once you get it in a register, you can do all the bit tests you want. 21:40:37 Hey Mark... you here? 21:40:38 or anyone? 21:40:46 * Trey heads for bed 21:40:51 What's the command to find out how much space a dir and all sub-dirs/files is takin' up? 21:40:58 du 21:41:04 tnx 21:41:05 that's the one 21:41:14 * Trey is away: sleeping [23:40] 21:42:50 or df 21:42:59 well df is for the whole drive 21:43:06 heh, so i learned two's complement a few days ago 21:43:08 du says what teh dir and sub dirs are using 21:43:11 it's so cool! 21:43:15 :) 21:48:13 how goes it? 22:20:42 want to see something scary? 22:20:44 #define ENTRY(x,y) {(x!=-1)? 22:20:45 (63-((WORDS_BIGENDIAN)? 22:20:52 x: 22:20:52 (n%8)+8*(7-(n/8)))): 22:20:52 -1, 22:20:53 y} 22:29:53 --- join: edrx (edrx@200.240.18.76) joined #forth 22:38:40 edrx! 22:38:40 nite ppl, ive gotta go zzz 22:38:45 hey, long time no see you! 22:38:48 :) 22:38:49 'night 22:38:55 yea i was on a contract job 22:38:59 now im between :P 22:39:02 looking for a new one 22:39:17 nice 22:40:11 I'm trying to finish an article (it's about 25% done :( ) and I should be going to Montreal in january (math-related stuff, not computer-related) 22:40:31 these are my main news, I think 22:40:36 night 22:40:49 teach me mafz ;P 22:40:59 r = (1/r) + 1 22:41:10 solve that for r :) 22:41:17 heh 22:41:43 which number is exactly 1 more than its own reciprocal 22:41:43 r^2 = 1 + are 22:41:51 r^2 = 1 + are 22:41:57 r^2 = 1 + are 22:42:05 nope 22:42:11 (1/r) = r/2. Solve that for r. 22:42:15 edrx: having xchat problems? :) 22:42:16 ? there's something translating my "r" to "are"... 22:42:17 1.61803499 or something 22:42:30 edrx: Settings->Setup... 22:42:32 Err 22:42:33 aaronl_: you got it :) 22:42:37 its xchar 22:42:43 Settings->Replace... 22:42:48 I HATE that xchat "feature" 22:42:52 its what i like least about xchat 22:42:55 i always turn it off first thing :P 22:43:03 me too 22:43:12 except for the teh -> the 22:43:14 heheh 22:43:28 great - deleted, thx 22:43:39 heheh 22:43:54 I440r: what was your bigest forth program? 22:44:12 hrm 22:44:27 the long wall coal mining shit 22:44:44 roof support system 22:44:57 wtf was that? 22:45:00 they wrote a roof in forth? 22:45:01 :) 22:45:05 yes :P 22:45:15 ill explain next time 22:45:18 k 22:45:25 troo tired to run error hgehe 22:45:31 : sleep 22:45:36 bed go tuck 22:45:43 light off ; immediate 22:45:47 :) 22:45:49 (tm) 22:45:51 :) 22:46:19 what would :) do in forth :))) 22:46:42 what would it do? 22:51:21 you need to define it 23:12:49 --- quit: edrx ([x]chat) 23:22:26 --- quit: Chaynez (Rebooting) 23:35:09 --- quit: adu (IRCStep) 23:59:59 --- log: ended forth/01.06.12