00:00:00 --- log: started forth/05.04.07 00:01:36 --- quit: onetom (Read error: 145 (Connection timed out)) 00:14:38 --- join: onetom (~tom@ns.dunasoft.com) joined #forth 01:08:20 --- join: YoyoFreeBSD (~yoyo@222.90.44.226) joined #forth 01:21:45 --- quit: cmeme ("Client terminated by server") 01:22:33 --- join: cmeme (~cmeme@216.184.11.2) joined #forth 04:20:46 --- nick: sk1p_ -> sk1p 04:29:56 --- join: ASau (~user@83.102.133.66) joined #forth 05:30:28 --- join: tathi (~josh@pcp01375108pcs.milfrd01.pa.comcast.net) joined #forth 05:30:28 --- quit: ASau (Read error: 104 (Connection reset by peer)) 05:57:04 --- join: madwork (~madgarden@derby.metrics.com) joined #forth 06:01:56 --- quit: Al2O3 (Read error: 110 (Connection timed out)) 06:07:03 --- join: Al2O3 (~Al2O3@c-24-1-126-202.hsd1.tx.comcast.net) joined #forth 06:18:41 --- join: aum (~aum@60-234-138-239.bitstream.orcon.net.nz) joined #forth 06:19:12 --- part: aum left #forth 07:33:24 --- join: Herkamire (~jason@c-24-218-95-147.hsd1.ma.comcast.net) joined #forth 07:33:24 --- mode: ChanServ set +o Herkamire 08:14:29 --- join: slava (~slava@CPE00096ba44261-CM000e5cdfda14.cpe.net.cable.rogers.com) joined #forth 08:14:41 anybody body assembly programming with libc on freebsd? 08:15:05 i'm getting really confused with something related to errno 08:16:40 ask 08:16:48 whats the problem ? 08:17:03 ok, so i'm calling close() in libc (not making the syscall directly) 08:17:09 ok 08:17:15 if you call this with an invalid fd, it stores the error in errno right? 08:17:31 i would assume so 08:17:34 now if you have this C code: void foo() { close(1); } 08:17:47 when i CALL foo (literally, from assembler), it works 08:17:54 if i have foo() { close(23); /* some invalid fd */ } 08:17:59 and call it from assembler, it also works (sets errno) 08:18:05 errno will have EBADF 08:18:10 but if i have void foo(int fd) { close(fd); } 08:18:28 then I have some C calling convention glue -- and it works fine if i call foo(1) from my C lib interface. -- it closes fd 1 08:18:33 but if i call foo(24) or something 08:18:35 it segfaults 08:18:36 oh. hehe 08:18:40 segfaults ?????? 08:18:41 and it segfaults in cerror() 08:18:46 that sounds like a libc bug 08:18:48 which is an internal function that takes the value in EAX and stores it in errno 08:18:51 right after making a syscall 08:18:53 but it works from C code, you see 08:19:04 it only breaks when via my C calling convention wrapper, and only if errno is to be set 08:19:12 and it gets better 08:19:42 i looked in gdb, and the problem is that its doing 08:19:48 MOV [EAX],ECX 08:19:50 but EAX is 0 08:20:02 but this is done right after calling some internal libc shiznit, which presumably returns the address of errno 08:20:09 (in EAX) 08:20:30 yea this definatly sounds like a libc bug 08:20:46 have you tried to do the same thing on a linux box ? 08:20:51 but its only triggered from *my* C library interface 08:21:01 oh, the same code works fien in linux, fbsd 5.x. only on my fbsd 4.x box it breaks 08:21:11 so like, if i report it, they'll tell me its a problem in my code 08:21:20 but anyway, i need a workaround, since i still want fbsd 4 support... 08:21:27 unless you can be more specific 08:21:38 this part of libc is written in assembler 08:21:46 and i bet they forget to push/pop some volatile reg or something? 08:22:04 because I have weird register usage, but *technically* compatible with the x86 unix ABI spec :) 08:22:22 * slava grumbles at C programmers messing up their assembly in libc 08:22:51 oh, this only happends if i link with libc_r (the user-space threading library). with normal libc there is no problem. 08:23:13 and factor doesn't use libc threads anyway. wanna know why I link with libc_r? SDL fucking *REQUIRES* it!! 08:23:21 busdfagsubigfhaigds 08:23:22 sorry 08:23:24 i had to vent 08:24:23 i'm just gonna link against libc, i'm not using the sdl binding at this time anyway. 08:28:54 hang on brb, work calls :) 09:03:20 --- quit: YoyoFreeBSD ("Leaving") 09:06:40 --- join: YoyoFreeBSD (~yoyo@222.90.44.226) joined #forth 09:11:06 --- quit: Al2O3 ("Leaving") 09:16:58 --- join: Al2O3 (~Al2O3@c-24-1-126-202.hsd1.tx.comcast.net) joined #forth 09:17:33 :/ 09:55:49 --- quit: YoyoFreeBSD (Read error: 110 (Connection timed out)) 12:25:13 slava, you working on the retroforth PPC port? 12:28:34 that should be tathi :) 12:28:42 he ported isforth to ppc :) 12:29:39 heh. 12:29:42 tathi is working on retro for ppc. hmmmmmm 12:29:53 I was working on it, but kinda got sidetracked, apparently someone else picked it up. 12:29:57 no, though I've thought about it a couple of times. 12:30:10 Oh, well I actually started on it. 12:30:21 how do you know someone else picked it up? 12:30:26 Al2O3, ever used isforth ppc ? 12:30:41 I got sidetracked with picking a new scripting language (Ruby) over Sensetalk, and have been spending many months learning it and doing the IORCC (code contest for Ruby). Now the contest is over, I can spend more time with Forth agai. 12:30:53 I440r, nope. But I have used ratlast 12:30:58 on PPC 12:31:02 ratlast ? 12:31:07 ruby atlast. 12:31:16 it is an inline forth implementation in ruby. 12:31:22 isforth is my compiler, tathi ported it 12:31:30 You just make a Forth interpreter instance, and it will execute your forth code. 12:31:39 lol 12:31:44 cool., tathi, are you good at teaching ASM. 12:32:00 I need some help at some point, one of the reasons I gave up. You using a Mac? 12:32:11 What did you use as your compiler/assembler? 12:32:15 yeah, I have a Dual-G4 533 PowerMac. 12:32:25 running Linux though. Never used OS X. 12:32:32 the GNU assembler. 12:32:50 ah, OS X is pretty nice. Ubuntu for you? 12:32:54 Ubuntu? 12:33:06 or FreeBSD PPC, YDL? 12:33:11 Gentoo. 12:33:20 err fbsd is running on ppc now ? 12:33:23 I was just doing everything by hand, but it got boring after a while. 12:33:33 I440r, I thought it was. 12:33:50 * Al2O3 admits to not knowing about FreeBSD PPC. 12:33:51 i know theres alot of talk about it but as far as i know *bsd is x86 only 12:33:58 err...I thought FreeBSD was still x86 only. 12:34:05 isforth runs in fbsd too :) 12:34:17 tathi lst i checked it is x86 only 12:34:30 Both the other BSDs do though. 12:34:37 2002 update 12:34:37 What is the current status? 12:34:37 FreeBSD/PowerPC currently is on the verge of booting to single-user mode. 12:34:52 I'd say that is a dead end project. 12:35:24 Anyway...I don't know of any other assemblers for PPC. 12:35:46 I keep meaning to write one, but... 12:36:03 I do 12:36:04 :) 12:36:10 And according to slava, OS X ships with a fairly old version of binutils. :( 12:36:13 I have been spending last 5 mins finding the info for you. 12:36:22 but the asm is for osx 12:36:32 its a full commercial/shareware tool. 12:38:26 google for Dark Tower PPC 12:38:41 http://www.versiontracker.com/dyn/moreinfo/macosx/11484 12:39:03 It may not be the answer for you in linuxland, but it is really coming along (have P19 licensed here for the port) 12:39:03 tathi: how does that matter ? 12:39:51 Frek: GNU as only is reliable in the parts used by gcc. 12:39:57 Other parts tend to be horribly buggy. 12:40:05 tathi: apple has it's own source tree 12:40:22 you may want ot spend some time with otool also if you are able and interested in osx 12:40:42 Frek: well, I'm pretty sure slava ran into some problems with it when he was writing Factor's PPC compiler. 12:41:35 tathi: and why is that ? 12:42:00 I don't know the details. 12:42:12 ok. 12:42:44 but either way the version number of the binutils aren't relevant as apple don't use the FSF binutils 12:42:51 although it's originally based on them 12:43:04 http://www.jroller.com/page/slava/20050319#mac_os_x_woes 12:43:08 though no details there 12:43:37 yes as I said; it's not relevant 12:43:59 wait, you're saying apple started over with their version numbers or something? 12:44:20 I'm saying that apple develops their binutils/compiler tools in parallel of the FSF tree 12:44:49 and I'm saying that if they started with an old version of binutils, it would have taken a TREMENDOUS amount of effort to make it decent. 12:45:09 the code for the GNU binutils assembler is utter crap. 12:45:10 tathi: so ? 12:45:30 so...I doubt if apple actually took the effort to fix everything and/or rewrite everything from scratch. 12:45:49 It works for gcc, so unless they're expecting people to use it manually, why should they fix it? 12:45:55 yes the fix everything 12:46:01 they fixed even 12:46:20 "as -v 12:46:21 Apple Computer, Inc. version cctools-525.obj~1, GNU assembler version 1.38" 12:46:44 that means as is from the cctools-525 tree, originally based on GNU as 1.38 12:46:57 right 12:47:11 cc --version 12:47:12 cc (GCC) 3.3 20030304 (Apple Computer, Inc. build 1671) 12:47:20 that's apples own gcc tree as well 12:47:36 it had stuff like DFA and other thing that's not available in FSF gcc until 4 etc 12:49:24 and I know for instance that apple wanted to use the FSF tree directly; but FSF/GNU refused alot of patches forcing them to keep the development in a separate tree. 12:50:09 and the only explaination I heard of so far is that "FSF don't have the same goals as apple" which I interpret as they're not interested in getting their PPC toolchain up to level with the x86 toolchain. 12:50:40 Yeah, they're certainly not very responsive. I've given up complaining to them. 12:51:28 so anyway my point is that one can't say "buhuhu apple uses GAS 1.38" cause infact it's very different from the FSF GAS 1.38 12:51:47 yeah, ok. 12:52:36 I'm just saying that the FSF GAS code is still hideous. 12:53:16 anyway the source for apples GNU toolchain is available if one want to inspect and compare the differences 12:57:56 all fsf code is hideous :) 13:05:27 I440r, that is a fairly accurate statement. 13:05:39 * Al2O3 admits his code is mostly crap too. 13:11:29 ok, looks like they did do a complete rewrite. 13:12:04 good for them 13:17:49 tathi can it assemble the ppc version of isforth ? 13:18:04 is it still a stinky rear end to a c compiler or is it an actual assembler now 13:18:47 I didn't just read the whole thing. 13:19:04 Just a bunch of spot-checks. 13:20:34 isforth ppc would need some work to run under OS X anyway. 13:22:12 I wasn't too careful in writing it as I wasn't planning to use it. 13:22:23 Just translated it to PPC and made the minimum adjustments to make it work. 14:21:39 --- quit: tathi (Read error: 110 (Connection timed out)) 15:50:09 --- quit: I440r ("Leaving") 15:52:29 hi all 15:52:50 hi 15:53:28 --- quit: Frek ("Client exiting") 15:53:41 --- join: Frek (13285-iden@h89n2fls31o815.telia.com) joined #forth 16:39:51 --- join: segher (~segher@p0770.nas1-asd6.dial.wanadoo.nl) joined #forth 16:43:35 --- join: aum (~aum@60-234-138-239.bitstream.orcon.net.nz) joined #forth 17:06:57 --- quit: I440r_ ("Leaving") 17:13:22 --- quit: slava ("Leaving") 18:26:03 --- quit: Raystm2 (Read error: 104 (Connection reset by peer)) 18:27:39 --- join: Raystm2 (~vircuser@adsl-70-248-100-177.dsl.rcsntx.swbell.net) joined #forth 18:40:57 --- join: Sonarman (~cleetus@adsl-64-169-95-25.dsl.snfc21.pacbell.net) joined #forth 18:50:51 --- join: saon (1000@c-66-177-224-130.hsd1.fl.comcast.net) joined #forth 19:05:18 --- join: FA (2808-ident@h89n2fls31o815.telia.com) joined #forth 19:06:45 --- quit: Frek (Read error: 104 (Connection reset by peer)) 19:18:30 --- quit: Sonarman (Read error: 104 (Connection reset by peer)) 19:25:12 --- join: Sonarman (~cleetus@adsl-64-169-95-25.dsl.snfc21.pacbell.net) joined #forth 19:27:20 --- quit: saon ("leaving") 19:34:09 --- join: sk1p_ (alex@pD958CFBB.dip.t-dialin.net) joined #forth 19:37:07 --- quit: sk1p (Read error: 145 (Connection timed out)) 19:43:23 --- nick: FA -> Frek 21:56:53 --- join: thinfu (thin@bespin.org) joined #forth 21:59:15 OMGOMGOMG 21:59:17 OIMGOMGOMG 21:59:18 OMGOMGOMG 21:59:18 OMGOMGOMG 21:59:20 thinfu: !!!!! 21:59:22 thinfu: PWNAGE! 21:59:29 thinfu: lets r0x3n t3h s0z3n 21:59:38 heh 21:59:48 the sozen? 21:59:55 s0x3n* 22:00:47 soxen ? 22:00:49 hmm 22:00:53 what is that 22:02:14 --- quit: Herkamire ("off to bed") 22:02:21 just us doing some crazy shit here 22:02:25 heh 22:02:34 hey did you think the topic was funny? 22:02:45 particularly this bit " #1xforth - a secret channel for 1x forthers. " 22:02:50 :) 22:02:52 :P 22:03:14 see you in the other chans :P 22:03:15 --- part: thinfu left #forth 22:25:41 --- quit: segher ("Leaving") 22:31:01 --- quit: Sonarman ("leaving") 22:50:19 --- join: I440r (mark4@rrcs-24-242-160-169.sw.biz.rr.com) joined #forth 23:06:11 --- join: OrngeTide (~orange@c-67-180-163-152.hsd1.ca.comcast.net) joined #forth 23:28:08 HI! 23:59:59 --- log: ended forth/05.04.07