00:00:00 --- log: started forth/12.03.01 04:05:07 --- quit: ASau (Ping timeout: 244 seconds) 05:57:16 --- join: nighty^ (~nighty@static-68-179-124-161.ptr.terago.net) joined #forth 05:57:16 --- mode: ChanServ set +v nighty^ 06:08:55 --- join: IAmHere (~IAmHere@c-75-70-9-151.hsd1.co.comcast.net) joined #forth 06:08:56 --- mode: ChanServ set +v IAmHere 06:10:14 --- join: adasfdasf (~adasfdasf@187.38.69.78) joined #forth 06:10:14 --- mode: ChanServ set +v adasfdasf 06:10:27 HAIL! 06:15:14 sleet, snow, rain. 06:15:30 precipitation peaks. 06:21:51 Glory, Majesty, Unity - Hail, Hail, Hail 06:52:32 --- quit: karswell (Remote host closed the connection) 06:53:05 --- join: karswell (~coat@93-97-29-243.zone5.bethere.co.uk) joined #forth 06:53:05 --- mode: ChanServ set +v karswell 07:00:14 --- quit: adasfdasf () 07:00:19 --- part: hlavaty left #forth 07:10:30 --- quit: ttmrichter (Quit: Leaving) 07:34:39 --- join: I440r (~zhiming@24-183-5-217.dhcp.fdul.wi.charter.com) joined #forth 07:34:40 --- mode: ChanServ set +v I440r 07:51:48 there sure are a hellof alot of idlers in #forth these days that never ever say antything lol who ARE you guys! :) 07:52:10 --- join: adasfdasf (~adasfdasf@187.38.69.78) joined #forth 07:52:11 --- mode: ChanServ set +v adasfdasf 07:52:19 hi adasfdasf 07:52:25 hi I440r! 07:52:34 you are here! :D 07:53:33 I remembered the name of forth in C: is pforth (portable forth). 07:53:51 *the name of that forth in C 07:54:04 do you know? 07:54:21 oh yea ive hered of it 07:54:43 seens to be simple 07:54:59 any forth developed in anything other than forth is never going to be simple 07:55:01 not ever 07:55:23 it would be like writing gcc in visual basic 07:55:27 because vb is simpler than c! 07:55:33 but for now I'm still reading jonesforth, I'm getting the nuances of forth 07:55:40 good 07:55:56 That's bullshit. 07:56:15 if you have starting forth thats years out of date but STILL a good place to start 07:56:57 but that's the question, it's only kernel, only kernel was done using C. like most forths uses asm to do it. So, how is the problem of use C instead asm to build the kernel? 07:57:20 the problem is that the kernel is NOT written in forth 07:57:24 There's no problem using C instead of asm to build the kernel. 07:57:32 No, the problem is in another place. 07:58:01 if you are going to write the forth kernel in C then just go ahead and write the applications in C too 07:58:04 is on the C runtime? 07:58:05 If you want to communicate to the outer world, you want anything in C. 07:58:40 DGASAU yes. but the kernel using asm can use CALL, I think 07:59:03 adasfdasf, DGASAU was saying "dont use forth at all" 07:59:10 Kernel in assembler means that jonesforth is non-portable. 07:59:17 Just like isforth and other similar shit. 07:59:19 yes, like isforth 07:59:53 but, once the kernel is done, are there real problems in use it to do final forth programs? 08:00:19 Yes. 08:00:23 In a practical sense it doesn't much matter what the kernel is written in. One in portable C will likely be slower, but that's generally not a real problem. 08:00:30 You have to implement FFI somehow. 08:01:05 what's FFI? 08:01:09 Well... If you mean that it belongs to kernel, then you don't have problem. 08:01:14 Foreign Function Interface 08:01:22 But that's not what forth lovers usually mean. 08:01:25 calling external libraries 08:01:32 okay, the interface with the outer worlf 08:01:41 *world 08:01:49 DGASAU, yea and thats going to be impossible in forth which is why vertex rsi (now general dynamics c4 systems) uses FORTH almost exclusivly in their satellite tracking systems. that includes the sat tracking AND the mux/demux of the data signals 08:02:16 forth couldnt possibly be used to write COMPLEX applications 08:03:53 Pigs can fly too. 08:03:59 You only need to give enough thrust. 08:04:07 DGASAU, ive never wanted to kick or ban anyone from this channel before. your constant HATING and negative input on everything pro forth is changing my mind very quickly 08:04:28 if you hate forth this much fuck off 08:04:33 go away and stay there plzkthx 08:04:48 Just give people objective information. 08:04:53 bullshit 08:04:57 What you do is even more harmful. 08:05:02 so I can create my own forth using nasm, but if I do it using C it wont be pure forth and maybe slower 08:05:21 and will take you a hell of alot longer to get working 08:05:25 Instead of getting work done, people invest their time into language they won't use for more than two projects. 08:05:31 and will not give you the same level of understanding 08:05:51 adasfdasf: it may be faster as well. 08:05:58 DGASAU, again. vertex rsi has used forth on ALL their products for many many years 08:06:10 How many? 08:06:18 they are the ones that amongst other customers manufactures the entire tracking systems for direct tv 08:06:56 they make the dish. they make the mux/demux hardware/software (in forth). the tracking software is all forth 08:07:04 You didn't answer the question. 08:07:20 how many products do they have? 08:07:20 They may choose Forth as a kind of vendor lock-in mechanism. 08:07:21 adasfdasf: what are you planning to use this for/ 08:07:33 I think this need not be a war. 08:07:41 Some rarely met holdout. 08:08:00 adasfdasf, it is war. if dgasau is going to be in here ONLY to give constant "dont use forth EVER" statements im going to ban him 08:08:22 tathi: for fun, to learn. but I want to switch to forth my computer vision job too, hereafter 08:08:22 That way some companies profit by writing software in Visual Basic and even COBOL. 08:09:13 DGASAU, knows who fedex is? 08:09:26 Sure. 08:09:37 their entire fucking tracking system is a forth inc product 08:09:37 It is old company, it can even use COBOL software. 08:10:05 That's not because Forth is so much efficient. 08:10:19 That's because it was efficient 30 years ago, and they invested into it. 08:10:39 yes, now we have thinks like .net and java 08:10:50 adasfdasf, high five 08:11:02 Or even worse, because somebody thought back then that Forth was efficient. 08:11:03 we don't need performance anymore, just classes and libraries 08:11:40 running all things on top of windows, over complex fs rules, users, networks, slowing down all.. 08:11:45 adasfdasf: I'd suggest you write some code in an existing Forth first to learn the language. My experience has been that implenting a Forth system doesn't teach you much about being an effective Forth programmer. 08:11:49 adasfdasf, what those classes and libraries allow is for morons like DGASAU to call themselves programmers when not actually developing anything at all 08:11:53 adasfdasf: no, Java is still more performant than Forth. 08:12:10 wow 08:12:15 adasfdasf: it's just that you don't count time for writing and debugging software. 08:12:23 take this lib. that lib. this other lib. put them in the easy bake oven and out pops a computer program 08:12:25 adasfdasf: count it too. 08:12:43 I440r: yes, and this is what makes Java more performant. 08:12:55 tathi: yes, I'm doing it at same time. jonesforth at morning, FORTH as language at evening 08:12:59 You don't write your own library to work with telephony systems. 08:13:17 You don't write your own web framework. 08:13:34 I did 08:13:40 I've my own web framework 08:13:51 You get readily available software and concentrate on solving your immediate problems. 08:14:09 adasfdasf: ah, good. :) Just take jonesforth with a grain of salt -- its author seems to have been a Forth newbie himself, so some things aren't all that accurate. 08:14:35 adasfdasf: did you do it in short time when you actually needed to work on something else? 08:14:40 i would still say isforth is a better forth kernel to study than jones 08:14:47 adasfdasf: or did you do it in free time for fun? 08:14:53 And I did that once worked with ruby on rails when I realized I was on a production line, like VW, just memorizing what the objects were. 08:15:40 DGASAU, go write a forth application in any forth please. prove you know your ass from a hole in the ground regarding forth 08:15:42 DGASAU: I dit it as part of paid project. 08:15:47 I440r: yeah, I'd agree with you there. 08:15:55 (isforth/jonesforth) 08:15:56 --- mode: ChanServ set +o I440r 08:16:08 --- mode: I440r set +m 08:16:18 --- mode: I440r set -v DGASAU 08:16:43 tathi i kinda broke down and converted all my 4+ to cell+ :( 08:16:47 lol 08:17:04 About time, you crazy barbarian. :P 08:17:04 i still dont like cell+ cell- etc but... i guess i was wrong :/ 08:17:08 lol 08:17:19 I like to opposing ideas. Fruitful. 08:17:28 im NOT going to implement postpone OR invert 08:17:57 I still think you're wrong about postpone 08:18:29 i need the isforth assembler more than ever now. i wrote an AVR forth and want to release it to adafruit.com but i cant till i fix the issue with isforth being heap randomized unfriendly 08:18:43 I don't have any love for invert though -- it was a "best of a bad situation" sort of decision by the standardization committee. 08:18:55 tathi [compile] foo. or... postpone postpone postpone foo 08:18:56 pick pone 08:18:57 one 08:19:06 What? 08:19:18 did i get that wrong? 08:19:34 i see postpone postpone postpone blah code all over the place in ans forth 08:19:43 Yes. Postpone directly replaces most uses of [compile] and compile. 08:19:57 which is my objection to it 08:19:59 The only thing it does is make it so that you don't have to know whether a word is immediate or not. 08:20:07 [compie] and compile do two totally different things 08:20:25 Which is good because what if you do `compile foo` and then someone replaces foo with an optimized immediate version. 08:20:30 It breaks your code. 08:20:37 If you used postpone it wouldn't matter. 08:20:39 tathi which is as my isforth comments states "relieving you of the responsibility of knowing the language you are using" 08:20:52 Yes, and I disagree with that. 08:21:00 :) 08:21:26 It relieves you from having to know implementation details which may legitimately change. 08:21:57 ok. im sure there are things in the C standard that would allow me to do X instead of doing Y. im also sure that if X were used in the lexer for gcc and i rewrite the lexter for gcc using Y instead it would break 08:22:06 it would be MY breakage, not gcc's 08:22:57 tathi: isforth seems to be a complete forth while jonesforth is just a simple tutorial. I'm learning asm in the process too. 08:23:13 if i take my application soruces which were developed for use with the "xyz" compiler and decide im going to use the "abc" compiler instead im sure im going to have some tweaking to do 08:23:33 adasfdasf, i would say jonesforth is a good starting point for that 08:23:45 not great. but good 08:24:14 adasfdasf: Yes, isforth is not a tutorial on Forth system design. But it's not as badly designed. 08:24:26 tathi im about to sue the milwaukee sherifs department. if i get 2847659246 million for it ill pay someone to write the isforht assembler lol 08:24:42 is it "Badly designed" at all? 08:25:10 Oh, bad wording, sorry. 08:25:11 its not ans compliant. is ans compliance required for "good design" ? 08:25:12 --- quit: nighty^ (Read error: Operation timed out) 08:25:14 tathi no 08:25:18 i didnt take it as an insult :) 08:25:36 and there ARE some very serious issues with isforth that i cannot yet deal with 08:25:44 like it not working if you have heap randomization enabled 08:25:55 thats a design flaw for sure. one i CAN fix when im metacompiling 08:26:10 Yeah, and does it still have that constant that depends on the size of the compiled ELF headers? That was a bit ugly. 08:26:22 right now heap randimization is an isforth killer 08:26:32 no i think that was fixed 08:26:47 it IS a constant. but its set at fsave time 08:26:58 so it depends on the system that fsaves 08:27:04 Ah. 08:27:19 my memory on this is a bit fuzzy but i think im remembering that right 08:28:22 adasfdasf, tathi is a former isforth developer till he defected to ans :P~ 08:28:28 he wrote the PPC port of it 08:28:43 so, nice 08:28:49 actually tathi defected to doing farm work instead of forth work :) 08:29:23 IIRC IsForth is practically ANS compliant -- it would only take adding a few words. 08:29:29 i know 08:29:36 the word seems to be equal 08:29:45 forth - farm 08:29:53 its those "few words" i object to 08:30:09 farm work is probably a more healthy activity 08:30:22 than twinky/coffee diet, only fingers getting exercise etc etc 08:31:06 tathi doing any coding projects at all these days? 08:31:21 your old position is still open }:) <-- evil grin (tm) 08:31:57 A little bit -- the farm sales/etc. database is mine. PHP (ugh). 08:32:16 And I still mess about with Forth now and again. 08:32:29 gforth does NOT count bleh 08:32:33 /stab 08:32:37 Heh. 08:33:01 are you putting pigs to do your PHP job? 08:33:21 i wrote an avr assembler and direct threaded forth. want to release that as free and have a sub threaded version as shareware 08:33:37 I still want to write a nice optimizing native compiler that can cross-compile transparently. I have a bunch of experiments in that direction. 08:33:45 i can write that easy but... its a dead duck as long as isforth cant cope with heap randomization 08:34:15 How do normal binaries deal with heap randomization? 08:34:26 They include relocation info in the executable? 08:34:41 well the reason isforth breaks with it is because of my +rwx on everyting from start of .text to end of .bss 08:34:55 [text][bss] i sys brk the bss out to 1 meg above start of .text 08:34:59 well with heap randomization we have 08:35:07 Oh, and .data and .bss are not necessarily adjacent to .text? 08:35:07 [txt] ..... [bss] 08:35:14 exactly 08:35:24 i cannot mprotect that ..... space between. its not mine 08:35:27 So heap randomization doesn't load the .text at a random address? 08:35:44 no. its still at the same standard process location 08:36:05 but bss is bumped up a random short distance from the end of .txt 08:36:21 Well that should be easy to fix then, shouldn't it? 08:36:30 it would be if i were metacompiling 08:36:57 i could have a boot section in .text and have the entire kernel in .bss including the extensions 08:37:26 Why can't you just call mprotect twice, once on each piece? 08:37:27 or i could write a relocator, allocate 1m at boot and MOVE isforth into the newly allocated buffer at ANY addres 08:37:42 could but fsave would be broken too 08:38:11 fsave moves (not relocates just moves) all headers down to :here" 08:38:35 Oh, I see. 08:38:46 i would have to save out .text and then append .bss 08:39:03 Anything compiled by isForth would be in .data, so would get loaded at a random address. 08:39:04 it IS a fix i was considering 08:39:17 --- join: MayDaniel (~MayDaniel@unaffiliated/maydaniel) joined #forth 08:39:17 --- mode: ChanServ set +v MayDaniel 08:39:20 So all the addresses would be wrong 08:39:22 well actually it would be in .bss which is what got sys broke out to 1 meg 08:39:27 but thas effectivly .data ya 08:39:30 Right, but you save it into .data 08:39:35 right 08:39:50 and yes. reload would break the branch targets 08:40:03 You could save it into .text and just accept the gap. 08:40:04 the only real solution is to save out the entire .text and .bss as a new .text 08:40:10 As a short-term fix 08:40:15 yes 08:40:32 allocate a new buffer. copy .text up to there. copy .bss/data up to there 08:40:45 save that entire buffer out as an elf with it all being .text 08:40:49 and live with the gap 08:40:56 Why would you do that? Just write it to the file sequentially. 08:41:11 the gap would be added to every tim you fsaved 08:41:25 tathi both would work. the former is easier to mentally visualize 08:41:46 the latter is more efficient but fsave is an implied bye so its only SLIGHTLY less efficient 08:42:03 the memory would be discarded immediately after fsave by the exit back to the os 08:42:40 Too bad there's no good way to locate things which would need to be relocated. 08:43:19 well if i stopped making headerless words i could use head spae to locate all the high level definitions CFA and reloacete the call targers that way 08:43:21 --- join: nighty^ (~nighty@static-68-179-124-161.ptr.terago.net) joined #forth 08:43:21 --- mode: ChanServ set +v nighty^ 08:43:35 no way im poluting my name space with 2856924659642598654 definitons that would just be crud 08:43:45 "head space" even 08:44:01 Right, but you don't know if literals or user data are addresses or just numbers which happen to look like addresses. 08:44:14 yup thers that too 08:44:26 That's the downside of an untyped language. 08:44:33 [ ' foo ] literal 08:44:59 or in isforth now i have ]# so i could do [ ' foo ]# 08:46:01 So I don't see that there's anything you can really do about the gap... 08:46:32 well. how often do u do ./isforth - fload then fsave the target then use that target to fload and then fsave the target 08:46:39 Right. 08:46:45 Just don't do that. :) 08:46:52 you dont really do that. 08:46:54 ya what u said 08:47:39 and i can take [.text][gap][.data] save out .txt. save out a null buffer of gap size. save out .data and call that entire 3 blocks my new .txt 08:47:49 which is basically what u were saying 08:48:09 Yes. 08:48:13 all this i have realised from the start but... if i do it this way its an exscuse to not actuallyfix it 08:48:37 but im not sure HOW to actually fix it 08:48:40 Er...wait, how would you *actually* fix it? Is there even a way to do that? 08:48:45 Oh, ok. 08:48:47 also. what if the gap is 8k 08:48:58 or 2 megs 08:49:01 or 500 megs 08:49:13 instead of just 30 odd bytes or whatever 08:49:17 bad mojo 08:49:28 there IS another fix sort of 08:49:45 you CAN ask for a specific address when you do a memory mapping 08:49:54 Ask for the gap? 08:49:56 no 08:50:05 Oh, map it in yourself? 08:50:06 compile isforth to run at a specific address 08:50:21 and have a boot loader that memory maps itself to the new address 08:50:33 can you say "KLUDGE" 08:50:53 problem is, asking for a specific address is not guaranteed to get you that address 08:51:16 if it were possible to sys brk .text i would have NO problems 08:51:41 but you cant brk only acts on bss which is why isforht HAS to have a .bss when the elf standard specifically states that bss is optional 08:52:21 Wait, I thought you only needed .data? 08:52:25 nope 08:52:33 brk only works on .bss 08:52:51 you cannot brk your .text or your .data 08:53:27 .data is +rw data. .rodata is +r data. .bss is uninitialized data 08:53:35 Huh. OK, that must be new. When we were messing with BSD originally it worked on .data. 08:53:57 no it worked on .bss 08:54:05 if you remember we had to add bss to isforths fsave 08:54:09 we created a 1 cell bss 08:54:13 4 bytes 08:55:18 svn co http://24.183.5.217/svn/isforth/trunk isforth 08:55:27 remind thyself. lol 08:55:36 OK 08:55:57 ignore the src/debug directory there thats a still broken work in progress 08:56:17 fsave has pretty much not changed since you/we wrote it (mostly you if i remember right lol :) 08:57:01 or you could just browse http://24.183.5.217:8001 08:57:09 thats svnweb or websvn i ferget which it is lol 08:57:23 stupid ppl making 2 products with the same freeking name 09:00:24 Er...that fsave has a .bss to allocate the 1 meg without brk 09:00:31 ...although the code still has the brk... 09:00:44 errr wtf 09:00:55 lol that might have been a speriment i abandoned and forgot about 09:01:05 does it work if the brk is removed? 09:01:31 It should... 09:01:41 does it tho. i think it didnt but i forget 09:03:16 --- quit: adasfdasf () 09:03:38 Hrm...doesn't work for me either way. 09:04:16 did you turn off HR? 09:04:28 echo 1 >/proc/sys/kernel/blahblah i forget 09:04:36 www.isforth.com has it on the first page 09:04:51 echo 1 >/proc/sys/kernel/randomize_va_space 09:05:41 Oh, right. 09:08:09 No, it doesn't. Hrm. 09:08:27 told u. failed speriment i forgot to clean up lpol 09:08:29 lol 09:08:33 Oh, wait, of course it doesn't. 09:08:47 The nasm code doesn't put the full size in the .bss 09:09:11 nasm doesnt or the sources dont 09:09:27 i think .bss is just 4 bytes when we fsave. i forget 09:09:32 the nasm sources have a 2 byte .bss 09:09:42 ive avoided looking at fsave lol 09:09:47 erm 4 bytes is the minimum no? 09:09:49 one cell 09:10:44 It says `resb 2` 09:11:04 wtf lol 09:11:05 k 09:11:08 thats def 2 bytes 09:11:28 So then you get a segfault because you can't mprotect it or you can't access it or something. 09:11:43 no i can mprotect bss 09:11:48 i can mprotect text 09:11:57 i cannt mprotect the gap thats injected between 09:12:11 No, I mean if you take out the .brk and you don't have a .bss, then you try to mprotect the 1M that you don't have. 09:12:28 can not have no bss 09:12:35 no 09:12:39 2-byte bss, whatever. 09:12:50 remove bss and i get what ever .text is and thats it 09:13:10 im not saving out a 1 meg file thats only got 70k used 09:13:13 The point is that if I change that `resb 2` to something big enough, then it works without the break. 09:13:32 but i stil have the gap 09:14:29 can a process allocate a new buffer, relocate itself to there and then deallocate its original buffer? 09:14:42 Dunno. I don't see why not. 09:15:19 Anyway. Your current fsave is making a .bss that allocates out to 1M 09:15:37 You should take that out or fix the .bss size in the asm source and take out the brk. 09:15:39 more kludge. run isforth. allocate new buffer. relocate to new buffer. deallocate original buffe. allocate new buffer of size 1m at original locatoon 09:15:43 relocate to original location 09:15:45 Or not...I suppose it doesn't really matter. 09:16:21 well the code to do the brk is more descriptive of what we end up with 09:16:39 a .bss thats just 1m in size and no brk HIDES that we have 1m of usable space 09:16:55 --- join: Kumul (~Kumul@67.224.230.59) joined #forth 09:16:55 --- mode: ChanServ set +v Kumul 09:20:35 Jeez, it's amazing this works at all. 09:20:41 lol 09:20:46 what snafu have u seen? 09:21:04 At the start of src/ext/fsave, you're short one 'f' on your computation of 'origin'. 09:21:16 what? 09:21:20 where show me 09:21:25 You're missing a hex digit on the mask. 09:21:31 it's only 7, not 8 09:21:57 crap 09:21:58 ya 09:22:10 lets see if putting that missing F at the front breaks things 09:22:23 no 09:22:29 Heh. It won't make any difference, because the normal address has the high nibble clear. 09:22:36 ./extend still produces a working executable 09:22:47 still a bug tho 09:22:57 not sure if its mine or yours tho :P~ 09:23:03 YOU wrote most of fsave remember :P~ 09:23:27 oh 09:23:29 no thats mine 09:23:33 thats the FIX for the constant address 09:23:35 ! 09:24:05 Yeah 09:24:58 k i fess up. thas my bug 09:29:45 brb, gotta reboot to windows temp 09:32:40 --- quit: I440r (Remote host closed the connection) 09:35:00 --- join: mark4 (~mark4@24-183-5-217.dhcp.fdul.wi.charter.com) joined #forth 09:35:00 --- mode: ChanServ set +v mark4 09:35:01 --- quit: nighty^ (Read error: Operation timed out) 09:37:33 --- join: nighty^ (~nighty@static-68-179-124-161.ptr.terago.net) joined #forth 09:37:33 --- mode: ChanServ set +v nighty^ 09:58:02 --- quit: MayDaniel (Read error: Connection reset by peer) 10:49:09 --- quit: Nisstyre (Quit: Leaving) 11:06:15 --- join: MayDaniel (~MayDaniel@unaffiliated/maydaniel) joined #forth 11:06:15 --- mode: ChanServ set +v MayDaniel 11:17:25 --- quit: mark4 (Quit: reboot back to a REAL operating system (not one from ms)) 11:21:39 --- join: I440r (~zhiming@24-183-5-217.dhcp.fdul.wi.charter.com) joined #forth 11:21:39 --- mode: ChanServ set +v I440r 11:35:04 --- join: adasfdasf (~adasfdasf@187.38.69.78) joined #forth 11:35:04 --- mode: ChanServ set +v adasfdasf 11:35:14 hi again 11:41:37 --- quit: Snoopy_1611 () 11:47:05 nice article http://www.ultratechnology.com/efzen.htm 11:59:12 I was finding by "software programming simplicity" when found this article http://www.simple-talk.com/opinion/geek-of-the-week/chuck-moore-geek-of-the-week/ 11:59:31 this is why I'm here & learning about forth 12:02:10 --- join: Snoopy_1611 (Snoopy_161@dslb-178-004-068-024.pools.arcor-ip.net) joined #forth 12:02:10 --- mode: ChanServ set +v Snoopy_1611 12:06:38 --- join: IAmHere_ (~IAmHere@c-75-70-9-151.hsd1.co.comcast.net) joined #forth 12:06:38 --- mode: ChanServ set +v IAmHere_ 12:09:20 --- quit: IAmHere (Ping timeout: 255 seconds) 12:09:20 --- nick: IAmHere_ -> IAmHere 12:22:55 devices for everything, i dont like that idea 12:31:59 is http 1.0 simpler than gopher? 12:44:20 --- quit: ivan` (Quit: ERC Version 5.3 (IRC client for Emacs)) 12:44:40 --- join: Nisstyre (~yours@c-208-90-102-250.netflash.net) joined #forth 12:44:40 --- mode: ChanServ set +v Nisstyre 12:46:24 --- join: ivan` (~ivan@unaffiliated/ivan/x-000001) joined #forth 12:46:24 --- mode: ChanServ set +v ivan` 12:49:43 --- quit: Nisstyre (Quit: Leaving) 12:51:26 --- join: ASau (~user@176.14.250.151) joined #forth 12:51:26 --- mode: ChanServ set +v ASau 12:52:11 --- join: Nisstyre (~yours@c-208-90-102-250.netflash.net) joined #forth 12:52:11 --- mode: ChanServ set +v Nisstyre 13:40:55 --- quit: adasfdasf () 13:41:40 --- quit: Nisstyre (Quit: Leaving) 13:42:21 --- join: Nisstyre (~yours@c-208-90-102-250.netflash.net) joined #forth 13:42:21 --- mode: ChanServ set +v Nisstyre 13:59:17 --- join: DocPlatypus (~skquinn@108-75-59-67.lightspeed.hstntx.sbcglobal.net) joined #forth 13:59:18 --- mode: ChanServ set +v DocPlatypus 13:59:43 long time, no chat... 14:00:09 any GNU Forth users on Ubuntu that have noticed SEE doesn't work? 14:12:25 see is broken for gforth in ubuntu? 14:12:56 i dont use gforth of course but that would be kind of supprising that see would be broken in it 14:18:34 --- quit: MayDaniel (Read error: Connection reset by peer) 14:28:45 DocPlatypus: there's a known bug on 64-bit x86 that SEE doesn't work on code words -- it uses gdb and the interface is broken or something? 14:28:49 Does that fit? 14:29:07 tathi: so it is a known bug 14:29:21 looks like some kind of syntax error from gdb 14:29:55 Yeah. I don't know that anyone is doing anything about it though. 14:30:05 you can do ' dump is discode or something 14:30:30 then it will just show a hex dump for code words, but at least it won't crash. 14:33:22 Huh. Looks like there is an x86 disassembler in Forth. Wonder why they're using gdb? 14:33:32 DocPlatypus: give `' disasm is discode` a try... 14:34:17 Oh. That's probably only for 32-bit. 14:44:56 yea looking at fsavae reminds me why i dont want to look at fsave lol 14:45:24 ugh your kidding. it doesnt have a built in disassembler it has to use gdb? 14:45:34 ugh another reason to not use gforth 14:45:55 Like you have room to talk :P 14:46:15 It looks like someone started writing an x86-64 disassembler but never got it completely working. 14:46:49 It does have assemblers/disassemblers for a number of other architectures. 14:47:24 I can hit Control-C to get a hex dump, but the terminal is left in some kind of screwed up state where half my typing no longer registers 14:48:36 --- join: ttmrichter (~ttmrichte@58.55.124.245) joined #forth 14:48:36 --- mode: ChanServ set +v ttmrichter 14:50:29 tathi i have an 8051 assembler, disassembler and simulator written for isforth. an avr assembler. will write a mips and arm assemblers next 14:50:54 CANNOT for the life of me create a 32 bit x86 assembler. been trying for years 14:51:41 so yea i got some work to do but erm. im not forking the work out to the single worst debugging tool ever devised by man 14:55:06 gforth is trying to be portable, so it's a fallback on architectures where they don't have a real one. Makes sense. 14:55:34 Looks like they have their own for arm, ppc, mips, alpha, and i386. 15:02:37 should not be that hard to write one for x86-64 starting from i386, or are they that different? 15:02:54 very 15:06:22 i have no idea how to fix fsave to accomodate heap randomization 15:06:31 and unless i can accomodate that isforth is effectivly dead 15:06:35 NOBODY will use it 15:07:23 i could make ./kernel.com on first run save one file with .txt and the other file with .headers 15:07:57 unless i can deallocate my own bss 15:08:16 then reallocate it contiguous with text 15:10:00 [ 3] .bss NOBITS 0805b95c 01395c 0ec6a4 00 WA 0 0 16 15:10:16 and i dont get that ec6a4 size on ./isforth's bss 15:10:17 wtf over? 15:10:24 bss is supposed to be 4 bytes 15:16:04 im also no longer understanding why $100000 pt_size @ - is the bss size 15:16:13 at all 15:16:57 i tried removing that line and just making bss 4 bytes. ./isforth wont even LOAD when i do that 15:19:40 Because I wrote fsave and I just declared the space in .bss instead of using the break. 15:19:50 And then I guess we didn't take that out when you incorporated it in. 15:19:56 Let me take a look at it... 15:19:59 yea im not sure that was you was it? 15:20:20 thats too far back for my wrinkly brain to remember 15:20:30 Probably was -- I remember trying to talk you out of using the brk. 15:20:51 yea i remember that now 15:21:38 i thin pd_size pd_off pt_size need to be renamed to the actual elf header variable name they are being used for 15:22:06 if im reading this right pd_size is p_filesz etc etc 15:22:17 pd_off is p_offset 15:22:38 pt_size is also p_filesz damn so no 15:22:39 scratch that 15:22:44 Grr...haven't used svn in way too long -- can't remember the command names anymore 15:23:14 svn co http://24.183.5.217/svn/isforth/trunk isforth 15:23:17 is checkout 15:23:22 No, I got that. 15:23:23 what other operation were u going to try? 15:23:32 diff? status? update? 15:23:38 I was making some changes earlier, messing around with the randomize fix. 15:23:40 you shouldnt be able to check in tho 15:23:45 svn revert> 15:23:47 Couldn't remember revert. 15:23:48 ? 15:23:55 ya 15:24:09 did u get the randomize fix working? 15:24:11 Yeah. revert is different in the DVCS systems like git and mercurial and so on. 15:24:30 i think distributed vcs is bad 15:24:34 Well, it works here because my system just seems to space the data out to the next page 15:24:49 so it's all accessible, and writing the whole block is ok. 15:24:55 beause thers no central repo (usually) that means when u check out a project you get the ENTIRE history of it 15:25:15 wtf thats not what heap randomization is 15:25:29 Yeah, I wish they would make it so you can do a lightweight checkout. 15:25:47 there should be a gap between .text and .bss that you do not own 15:25:52 thats the problem. you CANT 15:25:59 you get EVERYTHING. 15:26:11 not so bad if thers just a few thousand lines of code thats only a year or so old 15:26:35 the major critisism they have for svn getting SLOW when it gets old is something THEY are going to be subject to aswell 15:26:39 Right, but there's nothing about DVCS that makes it intrinsically impossible. It's just that none of the tool makers have bothered to support it. 15:26:58 svn doesnt store the latest version, to check out the latest version it takes the original code and applies every change one at a time before sending it to u 15:27:09 29654926549832645942 changes are going to take a long time to apply when u check out 15:27:17 Are you sure? I thought it was the other way around. 15:27:28 (store the latest, diff backwards, so the oldest rev is slow). 15:28:07 that would mean that when you check in something new on the current version it would have to rewrite the entire repository 15:28:21 it stores just a delta from previous to next 15:28:32 not a delta that would undo next to get to previous 15:28:57 Only the files that have changed. 15:29:37 Anyway, the thing I really like about distributed is that you always have a place to stash your changes. 15:30:01 err and if YOUR drive blows up 15:30:04 you have lost it all 15:30:17 with a central repository on a server you dont 15:30:24 If you care about it you send it to the central repo. 15:30:29 because everyone knows workstations are never backed up but servers are 15:30:44 a central repo defeats the entire purpose of it being D lol 15:30:53 Why? 15:30:55 that just makes it a new non distributed system 15:31:02 its no longer distributed 15:31:22 github totally destroyes the entire reason for using a distributed system 15:31:37 No it doesn't. I can be offline wherever and still have the benefit of version control. 15:31:41 but github is the ONLY way you can get your stuff known to the world 15:31:51 erm so can i with svn! 15:32:09 tho i do not like the .svn direcories poluting my entire source tree 15:32:26 You can't check stuff in to your local working copy with svn, can you? 15:32:31 yes 15:32:40 i believe i can 15:32:42 And to the server as well? 15:32:51 erm. ill have to check that tho 15:32:53 As I recall that's a major PITA 15:33:01 i mean if im offline i THINK i can do a deferred checkin 15:33:01 If it's even manageable at all. 15:33:23 Well, if you can do that...to me that's the whole point of DVCS right there. 15:33:41 let me check with the experts :) 15:33:50 I can make a bunch of checkins or whatever, branch, merge, anything, and if I want to keep it I can push it to a central server for publishing, if not I just toss it. 15:34:29 And e.g. with isforth, I don't have to have commit access to your server, I could mess around with whatever I wanted on a local branch. 15:34:52 well i COULD give u checkin access lol 15:35:00 but ya i see ur point 15:35:12 however. at the same time i see little actual purpose for that 15:35:23 other than being able to check in witha comment a small amoutn of changes 15:35:33 then do more work and more small checkins... all offline 15:35:42 then connect and bam apply all your small changes 15:36:03 i.e. dont do 6 months worth of edits and then check them all in with "i did alot of changes here" comments 15:36:44 how does BRK know the memory you are breaking is bss 15:36:59 No idea. 15:37:23 this is kind of annoying. i need to deallocate my bss from its randomized location and then reallocate it. which im not even sure is possible 15:37:34 tathi want a shell acct on an x86 machine? 15:41:03 What for? 15:41:16 This is an x86 machine 15:41:26 i thoughtn it was ppc lol 15:41:32 u not using ppc now? 15:41:36 No, I'm not using the PPC box much anymore. 15:41:41 Still have it. 15:41:41 aha 15:43:28 OK, where was I? 15:43:33 oh, fsave 15:45:14 elf0 - bss_addr cell+ ! \ and offset 15:45:14 \ $100000 pt_size @ - \ compute memory size 15:45:14 4 pt_size + 15:45:14 ( dup) pd_size cell+ ! \ and store in program header 15:45:14 4 ( pd_size @ -) bss_size ! \ compute bss size for section header 15:45:16 that works 15:45:35 OK, those names are... pd_size is Program-header Data size, pt_size is Program-header Text size 15:45:43 yes 15:46:01 and that paste was wrong 15:46:06 it should be 4 pt_size @ + 15:46:07 I was wondering 15:46:30 so that sets the memory size equal to the text size plus bss size of one cell 15:46:37 then data size is 4 15:46:40 where data IS bss 15:46:47 and headers 15:46:58 no the headers are not counted as part of the program size 15:47:05 they are counted as part of the file size 15:47:20 [ 3] .bss NOBITS 0805b95c 01395c 000004 00 WA 0 0 16 15:47:53 --- quit: ttmrichter (Quit: Leaving) 15:48:24 hhere dup bss_addr ! \ set address of bss in section header 15:48:25 elf0 - bss_addr cell+ ! \ and offset 15:48:25 4 pt_size @ + pd_size cell+ ! \ and store in program header 15:48:25 4 bss_size ! \ compute bss size for section header 15:48:30 that i THINK is right 15:49:53 it works anyway 15:49:56 Why are you using pt_size there instead of pd_size? This is the .data/.bss Program Header 15:49:59 bss is one cell then 15:50:34 text size plus bss size is the overall total size 15:51:04 why we need to store text size. bss size and "text plus bss" is beyond me 15:51:11 elf is a fucked up standard 15:51:14 way too fucking complex 15:51:31 i think THIS single file is the most cluster fucked up file in my entire source tree 15:51:41 Yeah, it needs a good refactoring. 15:51:46 and my memory manager uses my famous "begin while until else then" loops 15:51:49 OK, there are two complete sets of headers. 15:51:58 yes 15:52:05 The section headers .text, .data, .bss which are for the linker (theoretically) 15:52:18 And the program headers which tell the program loader what chunks to load into memory where. 15:52:42 There are two program headers, one loads the .text segment RX and one loads the .data (and allocates for .bss) RW 15:53:01 yes. though there can be rodata i dont use it 15:54:23 heap randomization is going to be the albatross around my neck 15:54:31 its going to be a thorn in my side 15:54:41 i NEED my .text and .bss to be contiguous 15:55:04 I think you're going to have to just live with the gap. 15:55:19 And just not fsave repeatedly... 15:55:24 i dont think i can 15:55:35 i mean. fsave is already cluster fucked up enough as it is 15:56:00 i need to be able to determin EXACTLY how large that gap is too 15:56:28 and save out a block of "Wasted space" in my fsave 15:56:46 Anyway. That pt_size @ up above should be a pd_size @. Otherwise it looks right to me. 15:57:12 its a 4 pt_size @ + pd_size cell+ ! 15:57:22 eep that should be CELL not 4 15:57:36 Right. I'm saying they should both be pD 15:58:33 Those are the size in the file and in memory of the data/bss load segment. You want the memory size to be 1 cell bigger than the file size. 15:58:43 not 1 cell bigger than the file size of the .text section. 15:59:09 well the way i had it seemed to work just fine lol 15:59:27 Yeah, because the dictionary is bigger than your name headers. 16:00:46 how do i determin the start and end address of the gap :/ 16:00:59 at run time and at fsave time 16:02:00 At the end of isforth.asm you have an _end label, that gives you the end of .text 16:02:11 yes that i know 16:02:16 Up at the beginning you should put a label that will give you the beginning of .data 16:02:18 but is .data gapped or not 16:02:22 because thats the start of .data 16:02:29 do i actually have TWO freeking gaps 16:02:35 if so this wont work at all 16:02:44 Where would the second gap be? 16:03:02 [text][gap][data][gap[bss] 16:03:14 whre data is my headers 16:03:31 or is it [text][gap][data][bss] 16:03:35 Yes. 16:03:55 I don't see any reason why there would be a second gap, they're both user-writable data. 16:04:36 AFAIK they're just trying to keep you out of the code space. 16:05:07 text + text size is not data address 16:05:16 looking at kernel.com i mean 16:05:30 text is 080480a0 and its size is 0x2d2e 16:05:46 data which is next is at address 0804b000 16:06:09 that suggests a significant gap 16:07:19 Maybe the linker going to a page boundary? 16:07:26 yes 16:07:28 I know we found we had to do that on BSD. 16:07:48 all allocations HAVE to be on a page boundry 16:08:24 im not having 1 byte shy of 4k of a gap 16:08:25 sorry 16:08:29 not acceptable 16:08:38 i have to NOT have a bss at all 16:09:08 Oh, get over it. 16:09:50 and svn does not allow deferred checkins at all it seems 16:10:01 no i need to find a solution to this 16:10:05 get over it is a copout 16:10:26 can exceve take "use this memory" ? 16:10:42 We've been over this. There is no great solution short of basically writing your own program loader. 16:11:48 It's not a significant amount of space on any desktop system, and if you're going embedded and it actually matters, presumably you'll be compiling to something that doesn't have this issue. 16:13:56 im thinking... i have [text] [gap] [data + bss] 16:14:23 i could allocate a temp buffer, move my data out, deallocate my data and bss memory 16:14:36 then reallocate it contiguous with _end? 16:14:43 _end will have to be page aligned tho 16:14:45 is it? 16:14:46 let me check 16:15:39 If you're going to do that, you might as well just put everything in .text and mmap memory at the end instead of calling brk 16:15:57 nasm wont do that 16:16:27 and i think the reason i cant brk anythig but bss is because bss is the last section 16:16:37 You can brk .data 16:16:39 try it. 16:16:39 if i deallocate data and bss maybe i CAN brk 16:16:47 not if you have a bss section after it 16:16:51 Well, no. 16:17:08 so i need to deallocate my bss. deallocate my data and THEN break my text out to 1 meg 16:17:24 Wait, data and bss are contiguous. 16:17:34 yes we think so 16:17:38 It doesn't matter whether or not you have bss 16:17:41 You can still brk 16:17:52 i tried isforht with no bss way back 16:17:58 You can not brk .text 16:17:58 i couldnt brk .data 16:18:06 then im still fucked 16:18:19 i CAN brk it if its +rw? 16:18:33 maybe thats the restriction. you can brk something thats not +w 16:18:46 Whatever. Have fun. 16:18:57 sigh. im clutching at straws here 16:19:13 i need to have [start of text ............ 1m] one contiguous 1 meg block 16:30:08 ok i just created a foo.asm with nothing but a _start: and a ret 16:30:17 assembled it wth nasm and nasm applied NO BSS to it 16:30:22 why is nasm giving isforth a bss? 16:31:48 thats saying im using unallocated data somewhere. where? 16:32:17 isforth.asm. near the top 16:32:24 with resb 2 16:33:37 i ADDED that 16:33:52 because i could not brk .data 16:34:56 So you took it out and nasm is still giving kernel.com a .bss? 16:35:26 erm no actually. i added that when i first tried to brk .data. i just took out that resb and assembled and kernel.com has no .bss 16:35:26 Because when I take it out, I get a kernel.com without. 16:35:38 right. 16:36:15 so how do i strip BSS out of the fsave... /me looks 16:36:50 crap. thats going to be non trivial 16:37:57 Nah, you should just be able to cut out everything with .bss, I think. 16:38:27 If you take out the string from the string table you'll have to update the one index in the section header... 16:39:20 --- quit: nighty^ (Ping timeout: 246 seconds) 16:39:39 Oh, and the shstrndx will need to be 3 instead of 4 16:41:36 yea something i did is b0rked 16:41:36 And you'll need to set pd_size cell+ to the same thing as pd_size 16:43:07 yes thats what i did 16:43:17 \ hhere dup bss_addr ! \ set address of bss in section header 16:43:17 \ elf0 - bss_addr cell+ ! \ and offset 16:43:17 ( 4 ) pd_size @ ( +) pd_size cell+ ! \ and store in program header 16:43:17 \ 4 bss_size ! \ compute bss size for section header 16:43:46 readelf -a ./isforth fails 16:44:01 the result of fsave is broken 16:44:47 oh, reduce the number of section headers from 5 to 4 16:45:16 yea that ws it 16:45:42 which means brk DOES work on .data so something i was doing way back was being done wrong 16:45:53 no bss on isforth now tyvm 16:46:06 Did you try on BSD? 16:46:11 That was the strict one? 16:46:14 i dont have bsd 16:46:27 Might not work w/o bss there 16:46:31 and i dont think i care if the bsd version of isforth ever works again. i know it currently does not work anyway 16:46:48 i mean. the version of isforth i had for bsd no longer runs in any up to date version of bsd 16:47:25 i cant even get a bsd installed inside a vbox vm and not build a brick vm 16:47:30 FUCK bsd lol 16:49:41 ok heres something. in my DOS (unreleased) version of isforth the first time kernel.com is run it takes all the headers and saves them out to a separate file 16:50:03 when you load it the next time or when you load the extended forth it LOADS those in from a file 16:50:18 doing that here would mean having to have an executable and a separate data file 16:50:31 but would mean the executable would be .text and nothing else 16:50:41 CAN i brk .text if there is nothing beyond it 16:51:11 My recollection is that you can do whatever you want on Linux. BSD was the problem. 16:51:53 But that was a while ago when address space randomization was really new, so it could have changed. 16:52:02 ok in nasm can i have TWO .text sections? one for code and one for headers and NOT have them being interleaved? 16:52:08 --- join: nighty^ (~nighty@static-68-179-124-161.ptr.terago.net) joined #forth 16:52:09 --- mode: ChanServ set +v nighty^ 16:52:20 i.e. i want one .text section but i want it to compirise of [code][headers] like that 16:52:28 if so...i have no problems 16:52:47 I think you can have subsections or something. 16:52:53 Check the nasm docs, I guess. 16:53:31 --- quit: nighty^ (Read error: Connection reset by peer) 17:12:37 i might be on to something here 17:12:42 its still not working tho 17:12:59 in macros.s my header macro switches to assembling into .dat 17:13:01 .data even 17:13:12 the it does a __sect__ to revert back to .text 17:13:33 well instead of [section .data] i made it [section headers=code] 17:13:43 so my headers has a progbits flag now 17:13:46 and it not .data 17:14:23 if nasm can save out ALL sections that have progbits as a single .text my problem is solved 17:30:01 nasm does not seem to have sub sections that i can find 17:35:43 seems i have to FUCK around wth linker scripts 17:35:57 and define a foo setion and a bar section and save those out as the .text section 17:36:02 i fucking HATE ld 17:48:39 btw, when did this channel go +m? 17:48:50 I've been gone... quite a while 17:49:16 i set it +m to shut someone up temporarilly 17:49:25 its not a natural state for this channel 17:49:52 asau is in here ONLY to propogate anti forth shit. 17:50:10 someone new comes in wanting to learn forth anything anyone says to help him he is doing his best to drive them away 17:55:29 ah 17:55:32 he's +v'd now? 17:56:42 no all he has to do is leave and come back and he will get a voice 17:56:48 everyone is auto voiced on entry 17:56:52 not sure who implemented that 17:57:11 my intent wasnt to perma devoice him. if i want to do that i just set him +b 17:57:27 i have always been very VERY reluctant to do taht 17:57:38 to me the channel always belonged to the people in it not me 18:06:50 ok i have a SINGLE .text section now being produced by the kernel assembly operation 18:07:16 but im still segfaulting on the mprotect after the brk. the brk MUST be happening on .text 18:07:26 so... im confused why its segfaulting on the mprotect 18:19:28 no longer have .text and .data 18:19:38 i have .text and h.text (for header .text) 18:19:42 and a linker script 18:19:46 SECTIONS { .text : { *(.text) *(h.text) } } 18:20:13 that puts all of code and headers into a single .text section 18:20:28 which im somehow still getting a segfault on the mprotect of 19:13:00 tathi you there? 19:31:37 --- quit: Kumul (Quit: gone) 19:33:58 ok ive proved the brk and mprotect work perfectly on .text 19:34:06 so the problem is within reloc.s 19:34:12 just gota find that :))) 19:34:30 well actually it could still be in isforth.asm because thats where the addresses i relocate to are calculated 19:59:40 yea tathi lol i def ned your help now 19:59:49 ./kernel.com does execute now 20:00:01 but still only if HR is turned off 20:00:11 fsave is broken for this now tho 20:00:24 ill find out why HR still makes the mprotect fail 20:04:40 hrm 20:05:22 commit it or something? 20:11:13 hi 20:11:21 k 20:12:36 try update i think i commited everything 20:13:44 kernel.com still works fine with this if HR is turned off 20:13:54 but thers a screwy null section in the executable now 20:13:58 i cant remember it being there before 20:14:11 [Nr] Name Type Addr Off Size ES Flg Lk Inf Al 20:14:11 [ 0] NULL 00000000 000000 000000 00 0 0 0 20:14:11 [ 1] .text PROGBITS 08048080 000080 0041bc 00 AX 0 0 16 20:14:11 [ 2] .shstrtab STRTAB 00000000 00423c 000011 00 0 0 1 20:14:27 and the brk FAILS if heap randomization is turned on 20:14:40 its one frreeking heap why would randomization prevent the break? 20:15:17 unless the kernel does something fucked up like [allocate application space][allocate wasted space] then pass control to application 20:15:39 i.e. heap randomization is still in effect :/ 20:16:39 The first section is required to be empty. Screwy thing with the ELF format. 20:16:52 funny i dont remember that 20:16:53 but k 20:17:21 fsave needs to be modified to relocate headers down and then fsave everything out as a single .text 20:17:32 i was working on that but my mods are an abortion lol 20:17:39 i didnt commit them 20:18:14 i should give yu write access on isforth 20:18:22 PM me a pass 20:18:49 and ur user name that ur using. im assuming its not tathi 21:19:22 --- join: ttmrichter (~ttmrichte@221.234.38.23) joined #forth 21:19:22 --- mode: ChanServ set +v ttmrichter 21:38:57 --- quit: ttmrichter (Quit: Leaving) 22:26:51 --- join: ttmrichter (~ttmrichte@61.184.206.85) joined #forth 22:26:51 --- mode: ChanServ set +v ttmrichter 23:42:58 --- quit: ttmrichter (Quit: Leaving) 23:59:59 --- log: ended forth/12.03.01