00:00:00 --- log: started forth/04.12.19 00:08:52 --- quit: Herkamire ("bed") 00:17:59 --- join: fridge (~fridge@dsl-220-253-77-81.NSW.netspace.net.au) joined #forth 00:28:21 --- join: todd (~todd@chcgil2-ar7-4-34-136-241.chcgil2.dsl-verizon.net) joined #forth 00:29:10 --- nick: todd -> SDO 00:51:26 --- quit: Sonarman ("leaving") 01:07:40 --- join: qFox (C00K13S@82-169-140-229-mx.xdsl.tiscali.nl) joined #forth 01:19:39 --- join: Topaz (jonny@spc1-horn1-6-0-cust217.cosh.broadband.ntl.com) joined #forth 01:27:37 wow, insane... the stupid FORTH i wrote ages ago still works ;) 01:35:42 --- quit: Topaz (Remote closed the connection) 02:18:52 --- quit: froop ("beware the colors of doom!") 03:40:54 --- quit: qFox (Read error: 104 (Connection reset by peer)) 04:43:35 --- join: Topaz (jonny@spc1-horn1-6-0-cust217.cosh.broadband.ntl.com) joined #forth 05:01:59 --- join: kuvos (C00K13S@82-169-140-229-mx.xdsl.tiscali.nl) joined #forth 05:02:02 --- quit: kuvos (Client Quit) 05:27:06 --- join: qFox (C00K13S@82-169-140-229-mx.xdsl.tiscali.nl) joined #forth 05:36:52 --- join: tathi (~josh@pcp02123722pcs.milfrd01.pa.comcast.net) joined #forth 05:36:53 --- quit: tathi (Client Quit) 06:24:39 --- join: saon (1000@c-24-129-90-197.se.client2.attbi.com) joined #forth 06:30:35 --- quit: crc2 ("I'll") 06:49:25 --- join: tathi (~josh@pcp02123722pcs.milfrd01.pa.comcast.net) joined #forth 06:49:58 Hi 06:52:53 hi 06:57:30 --- quit: tathi ("restarting...") 07:28:34 --- quit: SDO (Read error: 110 (Connection timed out)) 07:40:51 --- join: froop (~wossname@rn-v1w5a06.uwaterloo.ca) joined #forth 07:43:14 --- join: SDO (~todd@chcgil2-ar7-4-34-136-241.chcgil2.dsl-verizon.net) joined #forth 07:48:21 --- join: tathi (~josh@pcp02123722pcs.milfrd01.pa.comcast.net) joined #forth 07:58:51 --- quit: tathi ("booting herkforth") 09:53:24 hi all 09:53:30 Hi, crc 09:53:36 --- join: T0paz (jonny@spc1-horn1-6-0-cust217.cosh.broadband.ntl.com) joined #forth 09:53:39 what's new? 09:53:54 --- quit: T0paz (Remote closed the connection) 09:56:55 Nothing at all. 09:57:17 no progress on your optomizing forth compiler? 09:57:31 I got tired of it 09:57:34 :) 09:57:36 * robert has little patience 09:57:42 Perhaps I'll continue later 09:58:04 * crc is exploring the idea of a hybrid block editor/interactive interpreter 09:58:32 It's pretty interesting :) 09:59:11 How does that work? 09:59:58 --- join: Herkamire (~jason@h000094d30ba2.ne.client2.attbi.com) joined #forth 10:00:09 It shows the block editor at the top, and an interpreter below it 10:00:28 Ah, OK 10:00:38 Block -1 is TIB, Block -2 is PAD in this model 10:00:41 QBasic style;) 10:00:47 yup 10:01:07 The editor is line oriented right now, which plays nicely with the interpreter 10:02:44 --- join: imaginator (~George@georgeps.dsl.xmission.com) joined #forth 10:02:46 negative block numbers.... interesting 10:03:02 block 0 = start of code space + $20000 10:03:09 So negative numbers are allowed 10:03:38 hmm, i need to hack on my forth some more 10:03:53 because of my immense weeniness, the optimising colon compiler is actually written in python ;0 10:04:05 Interesting 10:04:27 * crc has removed does> in the experimental codebase 10:10:40 You don't like it? 10:10:53 Topaz: :) 10:11:34 Nope 10:11:48 Why? 10:11:53 I've never used it except once, and that was to implement constant 10:13:12 How about other high-level constructs? 10:13:22 such as? 10:13:35 Structures, OO, etc. 10:13:46 I don't do structures, OO, etc 10:13:56 I have done things like: 10:14:09 create ^Acrlf 1, 13, 10 10:14:13 I meant if others want to implement it. 10:14:18 And then accessed the elements by hand 10:14:32 ^A ? 10:14:37 ACSCII 1 10:15:02 Needed in the ACTION part of PRIVMSG (irc client implementation) 10:15:41 Ah 10:16:30 my FORTH is a bit of a joke, it compiles to AVR assembly, with a built in emulator ;) 10:17:21 Joking is what the forth community is about, Topaz! 10:18:08 can I get a retroforth binary for x86 linux? 10:18:13 hmm, where's that article on implementing FORTHs? 10:19:05 Topaz: I don't suppose you could be a little more specific? 10:19:06 http://www.retroforth.org/dev/beta_releases/rf76-beta2-linux.tar.gz 10:19:06 brb, getting food 10:19:48 thanks 10:20:16 heh, sorry, there was just a 5-section (or so) article describing the internal operation of FORTH, along the same lines as brodie's 'starting forth', but discussing the implementation 10:21:50 Build your own Forth? 10:21:54 Moving Forth? 10:22:13 ah, hight well be moving forth 10:22:15 might* 10:22:18 I got links to both on robos.org 10:22:22 If google fails 10:22:39 ah, excellent, tis 'moving forth', thanks 10:30:17 --- join: thinfu (thin@bespin.org) joined #forth 10:30:59 Hi 10:31:58 hmm, so the runtime code associated with DOES> puts the address of the cfa on the stack before running the DOES> stuff 10:32:46 er, pfa, not cfa 10:35:17 Right. 10:35:19 --- join: tathi (~josh@pcp02123722pcs.milfrd01.pa.comcast.net) joined #forth 10:36:39 so where is the actual code that does this?? 10:36:42 -? 10:37:56 * Topaz reads 10:37:59 it probably puts the address on the stack and then JUMPS to it.. that way code after DOES> is run 10:40:52 Topaz: what forth are you looking at? 10:41:18 well, i'm trying to work out how to do it in my own forth 10:41:29 (the usual case of trying to implement one before really understanding the language ;) 10:41:41 but mine is subroutine threaded, since it targets very teeny microcontrollers 10:41:49 --- quit: imaginator (".") 10:41:51 (so isn't really a proper FORTH, yadda yadda ;) 10:42:10 bah 10:43:17 it appears i'll just encode a subroutine-call in the cf, and then look back down the CPU stack to find the cfa (and thereby pushing the address of the pfa on the stack) 10:43:38 you doing does> ? 10:43:42 back 10:43:42 yeah 10:44:06 well i like STC the best of the threading models, although i don't see how targeting small microcontrollers results in choosing STC 10:44:07 i'm just not entirely sure how this pfa-address-acquiring code gets put there, does DOES> stick the same code at the beginning of every 'DO*' word, or is this done by EXECUTE? 10:44:19 thinfu: since it isn't interactive 10:44:26 (actually, ignore that) 10:44:27 pfa ? 10:44:35 pfa = parameter field address 10:44:37 parameter field address, whatever it's called 10:44:46 points to the actuall code after : blah ..... ; 10:45:01 does> puts the code inside cfa 10:45:09 and that code acts on pfa 10:45:11 afaik 10:45:19 pfa points to the data for a CREATEd word then? 10:45:23 hmm, i see your point ;) i'm doing STC because it's fastest actually, heh 10:45:54 What is the cell size? 10:46:33 16-bit addresses, but with a few 8-bit arithmetic words 10:46:41 (just to confuse matters) 10:47:02 you can't confuse us 10:47:06 we're hardened forthers 10:47:07 :P 10:47:12 so the items on my stack are variable in size... this is invariably going to bite me horribly at some point, but i'll see what happens 10:47:38 just so i can do trivial arithmetic without having to do slow 16-bit maths with the 8-bit CPU 10:48:48 (all this premature optimisation is probably bad for the health, but i'm being impatient) 10:49:40 My oldest AVR Forth was a mix between 32 and 8 bits 10:50:40 given that i usually write all my AVR stuff in straight assembly, i guess it makes sense for me to go to extreme lengths to make my FORTH fast ;) 10:50:49 (or i won't use it) 10:52:58 Make it generate video 10:59:19 --- quit: tathi ("booting herkforth") 10:59:22 lets not and say we did 11:00:19 Microsoft-style 11:02:00 you read that article kc5jta gave the url to? 11:02:55 I don't know if I got any URL from him lately 11:02:59 Which are you refering to? 11:07:55 http://www.euronet.nl/users/frankvw/rants/microsoft/IhateMS.html 11:16:17 have you read that? 11:16:53 * robert checks 11:17:32 oh boy, another very angry and hopefully humorous rant about microsoft 11:17:59 froop: nope its highly articulate 11:18:14 and makes many good succint points 11:18:37 kc5tja gave it two thumbs up.. i haven't finished reading it myself 11:18:40 i'll believe it when i read it :) 11:18:43 >~@ 11:19:30 froop LIKEZ MS 11:19:36 CUZ HE USED THERE PRODUCTZ 11:22:04 :D I LUV NOTEPAD 11:22:37 --- quit: onetom (Read error: 232 (Connection reset by peer)) 11:26:53 --- join: onetom (~tom@cab.bio.u-szeged.hu) joined #forth 11:39:53 --- quit: onetom (sterling.freenode.net irc.freenode.net) 11:40:47 --- join: onetom (~tom@cab.bio.u-szeged.hu) joined #forth 11:42:07 --- join: Raystm2 (~Ray@adsl-69-149-45-208.dsl.rcsntx.swbell.net) joined #forth 11:42:27 Hi 11:42:43 --- quit: Raystm2 (Client Quit) 11:43:10 --- join: Raystm2 (~Ray@adsl-69-149-45-208.dsl.rcsntx.swbell.net) joined #forth 11:43:24 --- quit: Raystm2 (Remote closed the connection) 12:16:03 --- join: bbls (~bbls@80.97.121.133) joined #forth 12:16:08 hello 12:16:10 anyone here? 12:16:15 Hi bbls 12:16:18 hi crc 12:16:24 i'm new to forth 12:16:28 cool 12:16:36 i've just opened a FAQ few minutes ago 12:16:40 forth is an awesome language :) 12:16:52 i'm impressed by the simplicity of the language 12:17:32 I am too, even after over six years of using it 12:17:58 anyway my main problem is trying to translate problems in postfix syntax 12:18:10 im used to normal infix of prefix 12:18:13 but not to postfix 12:18:33 that's the hardest part to learning forth 12:19:52 is there a way to implement IF-THEN-ELSE as forth words? 12:20:10 Most forths have if/then and often else 12:20:30 yes, but i mean can they be implemented/emulated as simple words? 12:20:34 1 2 = if ...do if true... else ...do if false... then 12:20:43 They can be, depending on the forth you're using 12:20:54 i'm speaking in the general case 12:20:59 how would you implement them? 12:21:11 In RetroForth, I do: 12:21:12 : <>if $063b 2, $adad 2, $74 1, here 0 1, ; 12:21:12 : =if $063b 2, $adad 2, $75 1, here 0 1, ; 12:21:12 : : >if $063b 2, $adad 2, $7d 1, here 0 1, ; 12:21:16 : ?if $72 1, here 0 1, ; 12:21:18 : then dup here swap - 1 - swap c! $90 1, ; 12:21:40 Which inlines the code for "cmp eax, [esi]" "lodsd" "lodsd" and a conditional jump 12:22:04 not asm 12:22:06 then patches the address of the jump to skip over the code if the condition isn't met 12:22:07 hmm 12:22:09 i mean in a high level way 12:22:28 ah, if and else programmed using high level constructs 12:22:32 In gforth: 12:22:33 : IF 12:22:33 (compile) ?branch >mark ; 12:22:38 yes, that's what i'm asking for 12:22:46 : ELSE 12:22:46 POSTPONE AHEAD 1 CS-ROLL POSTPONE THEN ; 12:22:47 crc no that's again low level 12:23:13 How can a conditional be implemented with no low-level code? 12:23:22 that's what i'm asking 12:23:30 for example you might insert a boolean into the stack 12:23:32 as a 0 or 1 12:23:48 before this you insert two other operands 12:24:02 and you need a word to choose between those two operands 12:24:32 At some point you have to use low-level code 12:24:39 no, without low-level 12:24:53 do you know of any languages where that's possible? 12:25:03 you need to use some conditional already implemented in order to define IF 12:25:06 let me think 12:25:10 but IF is one of the most basic conditionals.. 12:25:22 well, IF can be implemented as an AND operator in circuits 12:25:39 AND is low-level though 12:25:47 forth has and 12:25:54 hmm 12:25:59 : IF AND JNZ ; ? 12:26:04 let me think, there should be a way to do it.. 12:26:06 JNZ is low elve ltho 12:26:15 low level* 12:26:50 bbls, btw we don't do ELSE anymore 12:27:03 some people do... 12:27:05 IF foo ;; THEN bar 12:27:14 * crc doesn't and thin doesn't though 12:27:49 instead of IF foo ELSE bar THEN 12:29:12 how do i access an element in the stack? 12:29:27 what sort of element? 12:29:32 if its a number, its accessible 12:29:33 which element? 12:29:47 if its an address then you can fetch from it or store to it 12:30:10 for example something like 0 ELEMENT returning the top, 1 ELEMENT returning the one before the top, etc 12:30:21 PICK 12:30:23 Some forths have "pick" for that 12:30:40 * crc dislikes pick as it encourages bad programming habits 12:30:42 its not considered good forth programming practice to use PICK however 12:30:45 heh 12:30:49 it is possible to delete some elements from the stack (which are not in the top of the stack) 12:30:54 ? 12:31:02 1 2 nip 12:31:05 removes the 1 12:31:11 and 2? what's about 2 12:31:18 That gets left behind 12:31:26 1 2 3 4 5 12:31:28 goes onto the stack 12:31:29 nip 12:31:32 gets rid of 4 12:31:41 and how do i remove 3? 12:31:41 nip gets rid of 2nd item on stack 12:31:48 : nip swap drop ; 12:31:56 to get rid of 3 12:31:59 rot 12:32:02 drop 12:32:04 i think 12:32:11 1 2 3 4 5 rot drop 12:32:17 yup 12:32:34 1 2 3 4 5 rot = 1 2 4 5 3 12:32:39 is it possible to write a conditional swap without using IF or CASE? 12:32:50 1 2 true CSWAP 12:32:56 will result in 21 12:33:02 1 2 false CSWAP 12:33:10 should result in 1 2 12:33:16 is it possible? 12:33:20 then you could have 12:33:22 when you said 21 you meant 2 1 right? 12:33:35 : cswap 0; drop swap ; 12:33:40 (In RetroForth) 12:33:47 where 0 = false 12:33:57 : true 1 ; : false 0 ; 12:34:03 what drop does? 12:34:13 drop removes the item from the top of the stack 12:34:16 gets rid of the top element on the stack 12:34:18 ok then 12:34:22 1 constant true 12:34:26 0 constant false 12:34:52 "1 2 condition cswap drop" is equivalent to IF condition THEN return 2 ELSE return 1 12:34:54 * crc prefers that to : true 1 ; 12:35:10 hmm 12:35:11 : PSEUDO-IF cswap drop; 12:35:27 : CSWAP 0; drop swap ; 12:35:30 hmm 12:35:37 0; is defined with IF :P 12:35:40 this might work after all :) 12:35:53 As far as I know only RetroForth and HerkForth have 0; defined 12:36:22 ok, then we can use 0 for false and 1 for true 12:36:49 let me think 12:36:49 we need a portable cswap 12:37:02 : 0; 0 =if r> drop drop then ; 12:37:11 then you'd better use IF to define your cswap :P 12:37:12 should work on most forths 12:37:21 you mean 12:37:29 : 0; 0 = if r> drop drop then ; 12:37:36 yeah 12:37:43 : 0; 0 = if r> 2drop then ; 12:37:53 For forths other than RetroForth and HerkForth 12:41:30 isn't there a more "mathematical/logical" way, that is completely portable? 12:41:45 Nope 12:42:04 there is XOR and AND and OR 12:42:19 but you need JMP, JNZ JEZ CMP etc 12:42:22 Forth implementations vary too widely for any code to be truely portable 12:42:23 which are all assembler definitions 12:45:45 how does forth mixes asm with high level code? 12:46:25 That depends on the forth 12:46:49 In RetroForth, all code compiles down to assembly, so you can do things like: 12:46:55 : foo [ $ad 1, ] ; 12:47:16 Which makes foo compile a "lodsd" instruction into its definition 12:47:34 (drop is implemented like that) 12:47:51 Other Forths have a "CODE:" prefix and a complete assembler in them 12:48:09 CODE: drop lodsd, ;CODE 12:48:33 Again, it's very specific to the implementation you're using 12:48:38 bbls, perhaps you could tell us about your goals? you seem to be concerned about portability ? 12:48:57 no, i'm rather concerned about a mathematical view of forth 12:49:15 how so? 12:49:30 i'm not good on math anyway :), i do it just because i'm interested into proof of corectness 12:50:18 hmm 12:50:40 and i'm looking to see if i can use a forth-styled language as internal representation 12:50:48 a pure functional forh 12:50:51 *forth 12:50:59 yeah there are some functional forths 12:51:19 do you know any i can check? 12:52:29 there might be some listed at http://www.forthfreak.net/wiki on the ForthImplementations page 12:53:04 plus http://factor.sourceforge.net 12:54:29 factor isn't really a forth though 12:55:07 slava (the creator/developer of factor) can often be found on #concatenative 12:55:14 (he's not there right now though) 12:56:04 --- join: Sonarman (~snofs@adsl-66-124-255-101.dsl.snfc21.pacbell.net) joined #forth 12:56:30 hmm 12:56:38 but is functional forths really forth in the first place? 12:56:39 :P 12:56:55 not sure, i'm not looking to code in forth atm :) 12:57:21 i rather need a good functional internal representation for my language 12:57:30 or maybe use forth 12:57:42 but is forth an imperative programming language? 12:58:02 because 2 3 + 2 * is rather functional 12:58:09 result:= (2+3)*2 12:59:43 forth isn't an imperative programming language 13:00:00 then it must be functional :) 13:00:03 its not fully functional either.. 13:00:07 hmm 13:00:15 it falls into a unique category of its own 13:00:29 which some ppl call "concatenative" 13:00:43 i'm interested into functional programming languages because building a proof of corectness is much easier for them 13:01:13 but doesn't goedel refute all formal representations? ;) 13:01:27 who is goedel? 13:02:36 as i said, i'm not a mathematician :) i'm just a coder 13:02:52 i'm not interested into this for math purposes but for coding purposes :) 13:03:03 ok 13:03:10 so why do you need a proof of correctness? 13:03:14 i'm not sure how thats useful 13:04:07 well i want to code an OS where all programs will be proof-carrying, but for this you need a language&compiler able to produce proof of correctness :) 13:04:14 so i 13:04:26 i'm searching for a base language 13:04:32 hmm 13:04:44 unfortunatelly most languages are unsuitable 13:04:48 yeah i was interested in coding an OS and thats what led me to forth also 13:04:56 me too 13:05:12 pure functional languages are the path of minimum resistance when trying to do proof of correctness 13:05:54 Perhaps a subset of LISP would work better than Forth for proving correctness 13:06:04 the main requirement for a language in order to make it suitable for this, i think that is code size (espressed in semantic tokens not syntactical characters) 13:06:12 forth is a fairly easy language to implement other languages on top.. or to implement functionalness 13:07:02 yeah i guess might be better to go with a minimal subset of lisp 13:07:12 would be functional out of the box.. 13:07:24 that was my main direction of search 13:08:07 but i've decided to see if there are languages where programs can be written even more compact 13:08:53 well its certainly possible to code a functional forth.. 13:09:11 maybe since forth is not imperative, it might be used per se 13:15:33 hmm 13:15:42 maybe a forth without I/O would be functional 13:16:03 it would be very limited in useability though 13:16:09 where would the input come from? 13:16:16 initial non-empty stack 13:16:17 and where would the output go? 13:16:30 the output would be the remaining values in the stack 13:16:33 hmm 13:16:50 this could be used to do some CGI on HTTP servers 13:17:13 would it be able to read/write to/from memory locations though? 13:17:19 no 13:17:24 just do stack processing 13:17:29 then it'd be very limited 13:17:35 why? 13:17:38 no variables, no constants, etc 13:17:46 well, you can define words as constants 13:18:00 Only very simple ones 13:18:01 i mean constants as worsd 13:18:07 *words 13:18:11 Where does the code to define a word come from? 13:18:32 from the source code i suppose 13:18:36 hmm 13:19:00 * crc can't see a language with no access to memory outside the stack 13:19:08 the limits would be great 13:19:18 hmm 13:19:30 can you give me an example where memory access would be needed? 13:19:33 strings would be sequences of chars on the stack, and hard to manipulate in any real way 13:20:05 hmm, i tought more about using more complex objects in the stack 13:20:18 maybe arbitrary theoretical sets 13:20:27 that ventures away from forth 13:20:41 yes, i know 13:20:43 If I did: "foo" 1 + 13:20:46 what would happen? 13:20:55 Or better yet: "1" 1 + 13:21:20 if we speak about an interpreter then you would an error 13:21:33 what about a compiler/ 13:21:34 ? 13:21:48 hmm, a compiler might be impossible to write 13:22:07 hmm, unless you have a proof of correctness that would guarantee that the code is right 13:22:18 this would be slow to run I'd think 13:22:41 slava's factor language checks data types and return types to make sure the generated code does what it's supposed to 13:23:58 does it have some kind of flags for each element in the stack specifying type? 13:24:09 yes 13:26:47 sounds like what you're thinking of is a minimal forth that you launch multiple instances of etc 13:29:56 i.e. does stack stuff then returns the results.. 13:30:57 well, i have to avoid I/O completelly 13:31:09 since programs with I/O are quite hard to validate 13:31:11 I/O has to take place at some point 13:31:23 yes, but it would be done by the OS in my case 13:31:30 hmm 13:31:40 so what can an application actually do? 13:31:48 a) it can't get input interactively 13:31:57 basicly the OS would display a bunch of windows, each running a pseudo CGI program 13:31:58 b) it can't display results on it's own 13:32:18 using some form of HTML-derivated interface 13:32:29 so the system gets all input, puts it on the stack, and the program returns the results on the stack? 13:32:36 yes 13:32:38 * crc wonders what happens if all the input isn't used 13:33:33 well, some predefined value could be put there, or the HTML might have a tag specifying that all input fields must be completed. there are some other workarounds possible i think.. 13:33:59 for example a program might be made of several parts 13:34:45 as a state machine 13:35:01 the current state would be send each time as parameter 13:35:43 then you could also have a function that checks of input validity 13:36:04 so there are ways to avoid bad input data 13:36:54 I mean, you send the input to a function, and if the function(s) don't use all the input, and some gets left on the stack along with the output, what happens then? 13:37:54 oh, the function must remove any unused input 13:38:12 hmm 13:38:17 just like how a word works, it removes input and it places the output value in the stack 13:38:39 except that words can leave existing values on the stack and just add more 13:39:36 yes 13:39:46 but i think that you got the ideea 13:40:49 I do now 13:41:05 I just fail to see how it's superior to block all I/O from a program 13:41:29 i don't do that because it's superior in general :)) 13:41:42 it's beter for the proof builder 13:41:56 But worse for the programmers 13:42:02 since this is the goal, i have to cut from somewhere 13:42:21 Who can't have any variables, etc 13:43:22 Your programs would have to do a lot of stack juggling 13:43:52 hmm, yes 13:44:38 in forth, the stack isn't meant to be use like an array 13:44:45 They couldn't create structures of any sort either 13:46:53 how do I format a floppy disk (normal PC (dos?) format) under linux? 13:47:03 mkfs.msdos 13:47:05 mkfs.msdos 13:47:13 :P 13:47:18 :) 13:47:25 mkfs -t msdos 13:47:28 :)) 13:47:30 :) 13:47:40 mformat 13:47:41 :P 13:48:08 take a formatted dos disk and do: dd if=/dev/fd0 of=dosdisk 13:48:17 then do: dd if=dosdisk of=/dev/fd0 13:48:18 :) 13:48:26 * crc uses that technique 13:48:49 (The Linux distro I built has dd, but not mkfs) 13:48:58 that's unusual 13:49:07 crc not sure I have a dos formatted disk 13:49:15 I don't have mkfs.msdos 13:49:20 Hmm 13:49:24 do you have mformat? 13:49:32 download a dos disk from the net 13:49:49 no 13:49:54 hehe 13:50:34 * crc can upload a blank msdos floppy image 13:50:54 nice :) 13:51:02 also compress it :) 13:51:29 yeah, that'll save on upload time 13:51:53 heh 13:51:56 http://www.ecs.soton.ac.uk/~jb1403/dosdisk.bz2 13:51:58 i win :P 13:52:07 http://www.retroforth.org/dosdisk.bz2 13:52:14 pff 13:52:14 How big is yours topaz? 13:52:16 hehe competition 13:52:25 i don't use .bz2 because i don't like to type bz2unzip 13:52:27 really really small, heh 13:52:44 265 bytes for mine 13:53:26 264 here 13:53:27 :D 13:53:30 hmm 13:53:36 lol serious? 13:53:39 * crc wonders how you managed that? 13:53:40 methinks your volume label is longer, or something 13:53:46 bzip2 -9? 13:53:48 I didn't set a volume label 13:53:50 yup 13:54:13 gzip -9 was only 1669 bytes; too big for ftp uploads :) 13:54:43 there's a 1 byte virus hiding in crc's version of dosdisk.bz2 !! 13:54:52 man, it's been a long time since I used a floppy. how long should dd take? 13:55:01 thanks for the images! 13:55:02 absolutely ages? ;) 13:55:02 a minute or so on my box 13:55:06 no problem 13:55:11 Herkamire: like 3-4 mins 13:55:17 hmm 13:55:17 be thankful your computer hasn't slowed to a complete halt though, windows-style 13:55:19 its rawriting a whole disk.. 13:55:22 wow. 13:55:25 i still haven't worked out why it copes so badly with floppy access 13:55:26 * Herkamire goes to get a snack 13:55:46 * crc wonders if he had any files on that floppy image 13:55:50 hmm, you could have copied only first few blocks from floppy image 13:55:57 Topaz: because the floppy handler is so sensitive that if it doesn't recieve data on time it fails? 13:56:14 * crc hates floppies 13:56:21 thinfu rather bad programming, i think that winnt, win2k and linux don't have the same problem 13:56:23 hdd drivers are easier to write 13:56:36 crc definitivelly yes :) 13:56:38 ah, yeah, i remember now 13:56:48 floppy drive controllers are really really bad 13:57:04 yeah they need practicaly real-time handling of the data.. 13:58:19 My hard disk driver is ~99 lines of assembly, including comments. The floppy driver I had before giving up on *writing* to a floppy was 2,544 lines 13:58:51 crc, you using bios at all? 13:59:31 Not after the boot sector loads the kernel and switches to pmode 13:59:49 so you aren't using bios to read hdd 14:00:02 thinfu IDE interface is quite easy to program 14:00:05 it's very high level 14:00:31 IDE is nice to program for 14:00:40 Mine is all PIO-based 14:00:44 rrrr 14:00:55 and has worked flawlessly on all my boxes so far :) 14:01:01 now I'm supposed to be able to do: mount -t msdos /dev/floppy/0 floppy 14:01:11 throw a -o loop in there? 14:01:14 oh 14:01:15 sorry 14:01:16 ;) 14:01:35 is the "-t msdos" bit correct? 14:01:36 i'm assembly-mode, heh 14:01:38 yes 14:01:39 yup 14:01:45 reading stuff from right-to-left 14:01:48 bugger 14:03:22 bbls, have you looked at the Joy language? 14:03:31 It's said to be similar to Forth, but functional 14:03:48 no i haven't 14:03:54 i'll look right now 14:04:23 * thinfu wonders if a joy implmentation is small at all? doesn't think so 14:04:26 haven't looked 14:04:42 ahh well... I'll have to rebuild my kernel after all 14:05:17 can't you just build the msdos filesystem module? 14:07:48 I'm not big on modules 14:08:41 :( 14:08:47 Err, :) 14:08:52 * crc is tired 14:09:01 I dislike modules myself 14:09:20 i wonder why don't they try to add windows-like driver management to linux 14:10:27 why would they do that? 14:10:38 it's much better than module based drivers i think 14:10:46 (althrought modules are more flexible) 14:11:21 I don't have to reboot linux when changing modules 14:11:45 * crc had to reboot windows for all drivers except for the network card one 14:12:28 In RetroForth/Native, most drivers are forth programs which I can edit on the fly and recompile/test without rebooting 14:12:38 except for those stupid kernel drivers.. argh!! :P 14:12:48 (not that booting RetroForth/Native was slow...) 14:12:57 --- join: ows (~ows@83.132.99.46) joined #forth 14:21:28 crc do you do most of your rf coding while booted into rf? 14:22:30 I do most of my coding under Linux right now 14:22:47 Once I fix some boot sector bugs, I hope to change that 14:22:56 :) 14:23:09 (I do keep a copy booted under Bochs most of the time though) 14:23:31 cool 14:23:48 right now I'm experimenting with some interface ideas 14:23:59 (a hybrid editor/interpreter) 14:24:12 very cool? 14:24:20 heh, that didn't come out right 14:24:25 very cool! 14:24:35 tell me more 14:24:37 it has an editor view on the top, the interpreter is below it 14:25:13 Interactive output displays at the top of the screen 14:25:17 how do you specify which you'd like your typing to go to? 14:25:29 The editor is line oriented 14:25:37 " : foo ... ;" 0 i 14:25:49 Puts the text into line 0 of the editor view 14:25:57 oh, I see 14:25:59 (Blocks are 512 bytes; 8 lines) 14:26:04 so everything goes to the interpreter 14:26:07 Yes 14:26:15 It actually works better than I'd hoped 14:26:22 hehe :) 14:26:32 Once I get the TOB working, things will be more fun 14:26:53 TOB? 14:27:05 text output buffer 14:27:11 ah 14:27:13 hmm 14:27:14 to go along with TIB, the text input buffer 14:27:17 tob = block 0 14:27:17 you could avoid typing the quotes, and do: 0 i : foo ... ; 14:27:20 tib = block -1 14:27:29 pad = block -2 14:27:32 why don't add a TAB word completion (like in bash)? 14:27:44 that's too complex for my liking 14:27:47 this would be a nice feature 14:27:56 bbls: I plan to do that 14:28:02 ok :) 14:28:10 * crc is more of a minimalist than most are 14:28:28 if you keep your names real short, I don't think it's much use 14:28:51 * thinfu is a snob^H^H^H^Hminimalist 14:29:11 my longest word name is .version 14:29:20 heh 14:29:20 ridiculous 14:29:44 in RetroForth 8.0 the longest word name will be "execute" 14:29:45 I have some 15..16 char names 14:29:55 yay 14:29:59 you have more words than me too :) 14:30:10 pff 14:30:15 Names longer than two characters prove your naming scheme is inefficient. 14:30:16 i was writing words like 14:30:18 comparestring 14:30:20 and comparechar 14:30:22 $=$ 14:30:23 yeah, some of the length is usually a prefix 14:30:23 c=c 14:30:24 and crc converts that into those 14:30:26 :) 14:30:26 yeah 14:30:27 :) 14:30:38 crc knows how to make short word names 14:31:12 for me it doesn't make sense to make the name short if that makes it cryptic 14:31:34 I have a nice big monitor, and I'm OK with using a bunch of it 14:32:07 But what if someone steals your monitor and leaves you with an 8x8 LED display? 14:32:14 Real Forthers consider such situaitions 14:32:17 lol 14:32:18 situations* 14:32:20 robert: lol 14:32:21 colorforth's word naming is a little cryptic, but when he tells me the full name of the word in the shadow block, that makes it alot easier to understand 14:32:55 then I'd hook up another monitor 14:33:10 hmm.. 8x8 led display, i guess that shows 2 characters? 14:33:18 or 4? 14:33:21 thinfu: 1 14:33:26 :) 14:34:00 4x4 fonts 4-ever. 14:34:21 that doesn't work well if you have bad eyesight like me 14:34:37 pff.. all i need is 5 pixels per character 14:34:43 it wouldn't display a pictograph 14:34:54 i'd just use the 5 pixels to represent a number from 0 to 31 14:34:56 you could go binary :) 14:35:13 and then i'd figure out what alphabet character its refering to 14:35:16 like 25 would be Z 14:35:17 or use just two pixels and use a serial comm protocol :) 14:35:20 0 would be A 14:35:35 or just one pixel, doing morse :) 14:35:43 hmm 14:35:44 a-z = 26, characters 14:35:51 i'll leave the morse shit to robert 14:35:51 0-9 = 10 characters 14:36:06 Plus other symbols 14:36:09 bah 14:36:19 but i can do 14:36:21 TEN 14:36:22 instead of 10 14:36:23 :P 14:36:31 How would you do @ 14:36:36 Or separate words? 14:36:36 F E T C H 14:36:40 ick 14:36:42 ? 14:36:43 heh 14:36:50 * crc will stick with 8x8 or larger fonts 14:36:56 all symbols and numbers can be represented by the alphabet :P 14:37:07 yeah 14:37:08 be back soon 14:37:13 we probably should unroll it all out 14:37:42 i.e. go the other way.. 14:38:10 I don't think it's a very minimalist approach to write something that can parse something like "three hundred thirty seven" 14:40:12 Heh 14:40:36 yeah thats why i started thinking we should go the otherway 14:41:39 break out all the phonemes and assign a symbological meaning to each 14:41:45 how many phonemes are there? 14:41:49 or homophones 14:41:52 or whatever they are called 14:42:00 i imagine a hundred or so.. 14:42:09 imagine a hundred "words" 14:42:16 each represented by a phoneme 14:42:42 so by even saying an english word with like 10 phonemes in it 14:42:45 thats like 10 words.. 14:49:12 hmm 14:51:29 --- join: [Ren] (ren@user-11fale0.dsl.mindspring.com) joined #forth 15:05:53 robert 15:05:57 Yes? 15:06:07 you had me at HELO 15:06:25 heh.. you say hi all the time 15:06:32 Hi 15:06:32 so i thought of you went i saw that SMTP joke 15:07:02 Heh 15:25:40 from wikipedia: 15:25:45 In a Forth programming class, ten users have been supported on an 8MHz PDP-11, with each user operating out of less than 4K of RAM and sharing a single floppy disk 15:25:47 :) 15:25:56 :D 15:26:07 Let's beat that. 15:26:34 the problem is with user sharing, i suppose that we don't have around the hardware 15:26:37 We'll arrange a Forth meeting, and the 50 of us can share one 4-bit CPU running at 100kHz. 2kB of memory each 15:26:44 :) 15:26:59 Actually, that could be done over the Internet. 15:27:54 would be quite fun to make a 4-bit CPU, synthesize hundreds of them on a modern FPGA and watch them go at tens of gigahertz 15:28:02 wouldn't be a lot of use for anything, but would be fun to watch 15:28:12 :) 15:28:18 is a 4 bit cpu useful? 15:28:23 Of course. 15:28:24 what's the size of the internal register? 15:28:32 4 bits, I assume. 15:28:33 well, if you've got 16 spare LEDs that need controlling ;) 15:28:42 :)) 15:28:58 I can't let the idea go, to build a 4-bit computer. 15:29:05 Wondering if I should use ICs or transistors. 15:29:25 with transistors it would be considerably large 15:29:39 Yes. 15:29:46 And thus - very, very sexy. 15:29:47 but i suppose that you will have to use a fpga not to synthetize it 15:30:12 you could have leds showing the flow of each bit :) 15:30:22 Exactly. That would be SO cool. 15:30:34 But for a start, I guess I could build the processor from ICs. 15:30:35 you could make a big ol' double sided PCB, and solder on loads of SMT mosfets and LEDs 15:30:42 maybe you should use a fixed array of transistors, then just put wires between :) 15:30:44 Got some 4-bit ALUs, counters, etc. 15:30:47 and stick it in a picture frame, and let it calculate PI... 15:30:50 Microprocessors...modern crap. 15:31:13 use mosfets as opposed to bipolar ones... then you don't need any resistors :) 15:31:55 Cheater. 15:32:11 Perhaps using diode logic for as much as possible is a good idea. 15:32:24 And high voltages! 15:32:29 haha 15:32:48 i saw a truly stunning circuit for a really old HP binary counter 15:32:50 I mean, if your transistors can do 50V, why run them on 5V? 15:32:54 before the days of logic chips 15:33:10 it used neon lights and photocells as memory 15:33:22 and some really clever decoders using lightpipes and things 15:33:28 and ran on 150V ;) 15:34:15 Heh 15:34:36 Let's use that for IP! 15:34:44 robert: will this 4-bit computer be stack-based or register based? 15:34:51 why go electronic? you could go mechanical :) 15:35:28 thinfu: Probably register based. 15:35:31 i think a 4-bit computer as register-based would be quite a bit bigger than a stack-based one 15:35:37 Why? 15:35:40 i wanted to make a stack based proc for the novelty of using a hardware stack 15:35:44 more complexity 15:35:50 thinfu: I don't think so. 15:35:55 I'm going to cheat a bit and use IC memory. 15:36:14 a forth machine built using cog wheels would be nice :) 15:36:15 i was talking about doing it w/ transistors only 15:37:04 how many commands would your 4-bit computer have? would it be RISC or MISC or what 15:38:03 if you were cunning you could probably design the instruction set to avoid any decoding 15:38:16 although 4 bits don't really allow that much more than a BF* implementation ;) 15:38:18 Very minimalistic. 15:38:28 Check the Manchester Baby computer instruction set. 15:38:29 hmm BFchip 15:38:40 I think it had instructions for moving data and subtraction. 15:38:48 Oh, and jumps. 15:38:53 a bfchip with bf as the assembly lang.. 15:39:09 Yeah 15:39:12 That one is cool 15:39:21 what 15:39:22 no 15:39:27 i'm talking about making a bfchip 15:40:00 would be really amusing to make a stupidly simple chip (like a BF chip) which can address a lot of RAM 15:40:17 then make a C compiler target it (somehow! :D) 15:40:21 then compile bochs on it 15:40:24 then run windoze on it :D 15:40:33 although i can see some issues with I/O devices here, heh 15:40:37 (DMA anyone?) 15:40:57 that being said, bochs could probably be persuaded to operate totally out of RAM, and maybe a memory mapped keyboard and framebuffer 15:41:13 and have windows running off 1000 transistors (plus a *lot* of RAM) 15:41:20 though maybe i'm pushing it ;) 15:41:39 since if the chip is turing complete, and has enough RAM, it should theoretically be able to run anything :) 15:42:06 it might take a few months to boot, but that'd be half the fun 15:42:12 turn it into a bit of a centerpiece 15:42:51 :D 15:43:18 I think it would be even cooler if you wrote some small software that made it USEFUL. 15:43:29 bah :P 15:43:36 what? booting windows isn't useful? 15:43:45 i wonder how much POSIX bochs needs 15:44:30 actually, you'd have a lot more luck running a NES or something 15:45:00 Well, if you have some memory for it you could use it for a database of some sort. 15:45:05 though NESes are CISC, which is ugly 15:45:18 "Oh, this is my homebuilt CPU. I use it to store information about political enemies" 15:45:24 haha 15:45:26 Now THAT will make you sound a bit odd 15:45:36 you could blatantly write a simple cruise missile controller for it 15:45:54 y'know, read in a bit of rs232 from a GPS, twiddle the ailerons a bit 15:46:17 * Topaz thinks 15:46:24 :D 15:46:34 theoretically a turing machine could run a NES emulator 15:46:47 though i can see some N-squareds emerging here somewhere :/ 15:46:51 Well, it would be boring to play SMB with 0.000001 FPS 15:46:52 --- quit: [Ren] () 15:47:16 you never know, you might be able to clock it at several 100 mhz if you've got fast enough mosfets 15:48:06 --- quit: qFox ("this quit is sponsored by somebody!") 15:48:36 actually, i dread to think how many states a modern computer has... 15:49:26 High speeds are dangerous. 15:49:41 I refuse to use processors clocked above 100kHz 15:49:47 yeah, you might get cancer or something 15:50:22 i wonder what the best compromise of simplicity and turing completeness would be 15:50:53 a turing machine would be ridiculously easy to implement, but would require several gigs of RAM just to hold the states 15:51:17 hmm william tanksley built a stack machine in college 15:51:48 Topaz: I think a simple machine with one or two registers would be the best compromise. 15:58:38 i guess addresses would be the limiting factor 15:59:00 but if you had a ridiculously massive PC, and a several-part index register, you could probably get away with it 16:07:38 computers suck 16:08:50 i like to think that computers are just a distraction from reality, but i realise that the one thing that keeps me going is my random hackery on my linux laptop... 16:09:27 and no useful innovations ever came from tinkerers 16:09:47 weird huh? 16:10:01 one would think that innovation comes from tinkerers 16:10:09 but it doesn't 16:11:36 so you cannot excuse your tinkering as actually being something useful 16:11:41 as actually being productive achievement 16:11:52 perhaps as a learning experience 16:12:12 well, i guess *some* innovation must have come from tinkerers at some point 16:12:19 i'm just trying to think of examples ;) 16:14:33 --- quit: bbls (Read error: 110 (Connection timed out)) 16:15:53 just dead end innovations 16:15:55 afaict 16:16:18 but i'm looking for the chapter in this book that mentioned innovation doesn't come from tinkerers 16:17:00 or are you making distinctions between tinkerers, and people that actually do stuff? ;) 16:30:48 yes 16:31:12 i can't find what i was looking for in the book (its pretty big heh) 16:32:00 but basically it said something about pursuing failure, raw innovation, is the way to introduce innovation to the world 16:32:05 not tinkering on old stuff 16:32:14 anyways 16:33:19 i just wonder what anyone tinkers for.. it doesn't have any excuses as far as i can tell.. innovation? nope.. understanding? not really.. 16:33:22 robert: what do you think 16:38:41 --- quit: Topaz (Remote closed the connection) 16:45:48 --- quit: SDO (Read error: 104 (Connection reset by peer)) 16:49:23 back 16:49:31 hey crc 16:49:36 was rambling about tinkering 16:49:50 whaddya think about what i said? 16:50:51 not bad 16:50:57 * crc likes tinkering himself 16:51:16 I learned a lot by tinkering :) 16:51:37 well i find that i'm into some retro things 16:51:50 hehe, oddly enough I am too 16:51:55 like forth.. and oldskool import rwd sports cars 16:52:08 but i wonder if thats sort of not a good thing.. 16:52:18 as less growth perhaps.. 16:52:21 And the more I pursue simpler things, the more I realize that a lot of people are pursuing things from the wrong perspective 16:52:37 hmm 16:53:04 Why do I need a complex OS to edit text? Or use IRC? 16:53:16 Why are protocols so complex overall? 16:55:01 If Unix had remained small (and even early versions written in C were small), would more people be using it today? 16:55:22 * crc has written everything he needs for daily use, except a decent kernel 16:55:35 Perhaps tcn and I will even pull that off one day :) 16:57:41 My Linux system was ~64k of binaries (te, sh, cp, mv, rm, ls, mkdir, rmdir, mount, umount, retroforth, basic, and a bunch of other things too) 16:57:52 * crc has a disk with that floating around here somewhere 16:58:18 hmm 16:58:27 I could redo all of that in RetroForth now 16:58:30 i need internet access tho 16:58:54 I was planning to write a PPPoE driver 16:59:26 But tcn went off and started using Python, and I went off on the path that lead RetroForth to its present state 16:59:50 One day I might complete the kernel tcn and I had started 16:59:57 (It was nice) 17:01:09 Multitasking, interrupts, Unix-inspired device model (open/close/read/write) in ~4k 17:01:32 It used some C conventions internally, which I dislike 17:01:56 * crc should try to complete it one day, assuming that tcn doesn't resume work on it first 17:02:22 personally i don't understand tcn 17:02:25 i used to argue with him 17:03:02 about what? 17:03:44 dunno, probably forth & minimalism 17:03:45 not sure 17:03:54 oh 17:03:57 about C i think 17:04:05 He never fully left C, which was why he struggled to *use* Forth 17:04:08 hehe 17:04:13 He still likes C 17:05:07 exactly 17:05:20 he would complain about stack juggling i think? 17:05:36 yup 17:05:44 i tried to explain how thats a non issue in forth.. 17:05:54 He never learned to think in terms of stack-oriented programming 17:06:08 variables were one of his two downfalls 17:06:16 (data types were the other) 17:06:21 oh yeah i think i argued about variables with him too 17:06:21 heh 17:06:32 hmm 17:06:35 I use variables, but sparingly 17:06:42 i thought it was cool how he left computers completely for like a year or something 17:06:58 I did too 17:07:13 everyone should do that now and then :) 17:07:18 I agree 17:07:28 One day, I'll take a break from programming again 17:07:39 and possibly the 'net and such too 17:07:46 yeah 17:07:58 (Not for quite a while though) 17:08:06 maybe i'll do something like going travelling or something 17:08:09 brb, running to store to get something to drink 17:11:54 --- topic: set to 'SIB. Small Is Beautiful.' by thinfu 17:19:21 back 17:19:56 I like the new topic 17:20:07 :) 17:20:57 --- join: slava (~slava@CPE00096ba44261-CM000e5cdfda14.cpe.net.cable.rogers.com) joined #forth 17:21:03 hi slava 17:21:14 hi 17:22:13 how do you like the title of the channel today? 17:22:33 its good :) 17:23:24 --- mode: crc set +t 17:23:39 are you using your irc client? 17:23:43 Not at the moment 17:23:48 why not? :) 17:24:09 * crc is rewriting the view portion to use the hybrid interface I'm experimenting with 17:24:28 what kind of hybrid interface? 17:24:49 block editor on topic, interpreter below 17:24:54 (editor is line oriented) 17:25:10 like a split screen? 17:25:13 Actually it shows two blocks at a time (512 bytes/block) 17:25:14 yes 17:25:21 cool 17:25:36 tib is block -1, pad is block -2, tob is block 0 17:25:45 i'm writing an app that makes random changes in the code, then runs unit tests. if they pass, you've got a word that is not tested well. 17:25:48 what is tob? 17:25:50 text output? 17:25:53 yes 17:26:07 I'm not using the normal output words as much 17:26:13 one just writes to the block? 17:26:17 Yes 17:26:22 doesn't herkforth ahve a similar system? 17:26:39 Yes, but no interactive interpreter AFAICT 17:27:04 In RetroForth 8.0, you can still do things interactively if you want to 17:27:06 yeah 17:27:11 * crc no longer feels a need for that now 17:27:18 will it be removed? 17:27:30 Probably not, as it's useful at times 17:27:37 irc bot, etc i guess 17:27:45 * slava wants to move beyond source files at some stage. 17:27:49 yeah 17:28:06 Or for those who want to run older RetroForth code 17:28:15 will all source be in blocks? 17:28:19 No 17:28:30 would be cool if itwas, like pygmy 17:28:33 The initial source used to build the binary follows the existing approach 17:28:40 * crc isn't metacompiling yet 17:28:44 perhaps one day... 17:28:46 will 8.0 be metacompiling? 17:28:50 Perhaps 17:28:57 what else is new in 8.0, other than does> removal? 17:29:06 It depends on when I finally implement a metacompiler that I like 17:29:14 um, the hybrid interface is new 17:29:26 you can load/save a block file too :) 17:29:42 how many rows/cols in a block? 17:29:43 60x8? 17:29:46 64x8 17:29:49 right 17:29:59 figure out a way to use the other 16 columns :) 17:30:10 I could put debugging info there :) 17:30:15 Or "applets" 17:30:20 heh 17:30:30 * crc wants to use RetroForth as his primary OS one day 17:30:35 would these 'applets' use all available ram and show empty gray boxes? :) 17:30:40 Nope 17:30:58 They'd use a couple bytes each, and be updated by a timer of sorts 17:31:06 (or when you press ENTER) 17:31:28 will this new interface work in a terminal, or only native retro? 17:31:32 in RetroForth 5, I had a "panel" with "applets" (applets being words that implemented visual functionality) 17:31:39 I'm developing it under Linux 17:31:53 it'll work on Linux, FreeBSD, Native, at least 17:32:05 Maybe even under Windows (assuming I keep windows support in 8.0) 17:32:20 how do you output terminal escape codes ? 17:32:36 With ." 17:32:43 Or " ..." type 17:32:46 i mean on win32 17:32:48 I don't 17:32:57 Win32 doesn't support ANS escape codes :( 17:33:02 (Neither does BeOS) 17:33:10 * crc hates that 17:33:24 yeah 17:33:48 there's a guy working on win32 terminal support for factor, and he has to call a win32 api to change console attributes 17:34:06 I don't want to have to do that 17:34:27 Nothing above Win95 supports ANSI.SYS though (at least the NT line doesn't) 17:34:30 heheh 17:34:33 retroapplets 17:34:34 on the side 17:34:40 It'd be doable 17:34:57 * crc isn't going to write any, at least until he has RetroForth 8.0 as an OS 17:35:17 btw, i'm wondering if does> can be replaced by something else? 17:35:24 like what? 17:35:34 like it is useful to plug code into the cfa or is that pfa? 17:35:36 i've never felt a need for does> 17:35:38 It basically inlines code when used with create 17:35:39 but its still useful to do that.. 17:35:56 How often do you *need* to do that? 17:35:57 colon definitions are about as fancy as it gets for me 17:36:06 * crc would rather write macros to inline code 17:36:43 I only used does> when implementing "constant" 17:36:55 i think constant is kind of redundant 17:36:59 And not even that now, so I have no use for that 17:37:01 why have 5 constant foo when you can just write : foo 5 ; 17:37:08 does the former have any benefit? 17:37:09 readability 17:37:14 hmm 17:37:21 In RetroForth, they become the same 17:37:23 : foo 5 ; seems fine to me, and consistent with everything 17:38:09 technically though, if I change the code to handle constants to be more efficient, constant would be superior 17:38:27 would it make that much of a different? 17:38:38 Perhaps 17:38:45 Right now constants take 10 bytes 17:38:48 call dolit 17:38:51 ret 17:38:52 dd value 17:39:21 Suppose I change them later, to an inlined "dup mov eax, value" sequence 17:39:25 they'd become faster then 17:39:29 and maybe smaller overall 17:40:37 probably bigger, but quite a bit faster 17:45:04 your top of stack is eax? 17:45:17 yes 17:45:27 esi is the pointer to the data stack 17:45:31 do forths with a TOS cache implement stack underflow checking in any way? 17:45:36 (i know yours doesn't) 17:45:38 I don't 17:46:44 well most forths seem to check for underflow 17:46:57 and at least one probably caches the TOS.. 17:47:04 i just don't understand how its possible 17:47:26 how come? 17:48:07 well, can you explain it to me? 17:48:14 how do you represent an empty stack? 17:48:28 you just compare the stack pointer to the starting position 17:48:49 if it's below that, you reset to the starting position, and show an underflow error 17:48:55 same basic idea with overflow 17:48:56 :) 17:48:59 but how does one tell the difference between an empty stack, and a one element stack in eax? 17:49:08 wont the stack pointer be the same? 17:49:31 Let's say that esi is my stack pointer 17:49:39 I set eax = 0x20000 17:49:45 err, esi even 17:49:58 [esi] is the second element on the data stack 17:50:05 there's a 0 in eax at startup 17:50:18 drop would subtract 4 from esi 17:50:29 and also MOV EAX,[ESI]? 17:50:29 or add, depending on the implementation 17:50:41 Yeah 17:51:10 basically the contents of esi change, so I can say: 17:51:16 cmp esi, 0x20000 17:51:24 jl .underflow 17:51:55 in whatever handles checking the stack depth 17:52:23 In RetroForth, I just give ~500 stack entries above and below the starting point. 17:52:49 I haven't had any trouble not checking for over/underflow since doing that :) 17:53:33 actually, it's 400 entries above/below the starting point in 7.5 and 7.6; 200 entries in 8.0 17:54:14 why not a 30 deep circular stack? :P 17:54:34 have you tried *implementing* a circular stack on x86? 17:54:40 it's not easy or clean 17:54:46 in hardware though... 17:55:21 a circular stack strikes me as limiting 17:55:26 wouldn't it be just to check to see if you're at the 30th entry yet and then just jump back to 0 ? 17:55:36 thinfu, you'd need to use MOD or a branch, which is expensive 17:55:48 or you could use AND 17:55:53 when should I do the check? 17:56:01 In >number ? 17:56:04 In dup ? 17:56:15 hmm 17:56:28 (keeping in mind that some words modify the stack without going through the standard words) 17:56:45 I'd have to make "interpret" call a "check stack" function 17:57:10 and that'd be ugly, especially since it'd be called every time something was typed 17:57:40 yeah sounds ugly 17:57:58 simple implementations = ugly hacks to make them non-simple :P 17:58:22 I tried a circular stack, that's how I know it's ugly on x86 17:59:45 haha 18:06:00 * crc sighs 18:06:20 * crc is getting tired and will be going to bed in about an hour 18:14:13 --- quit: ows (Excess Flood) 18:14:39 --- join: ows (~ows@83.132.99.46) joined #forth 18:19:32 hi ows 18:19:54 dang 18:20:28 what? 18:21:27 ows' channel list #ai #robotics #swig #hpc #lisp #forth #haskell #C++ #latex #swhack #uml #MachineLearning #tomcat 18:22:04 --- join: I440r_ (~mark4@216-110-82-59.gen.twtelecom.net) joined #forth 18:23:00 wow 18:58:39 goodnight 19:01:32 --- join: tathi (~josh@pcp02123722pcs.milfrd01.pa.comcast.net) joined #forth 19:01:34 back 19:03:36 --- join: Sonarman_ (~snofs@ppp-66-124-254-172.dsl.snfc21.pacbell.net) joined #forth 19:04:17 what's this about herkforth and an interractive interpreter? 19:05:38 herkforth's "interpreter" is only interractive 19:06:08 there is no interpreter that works on files 19:15:46 --- quit: ows (Excess Flood) 19:15:49 --- quit: Sonarman (Read error: 110 (Connection timed out)) 19:16:10 --- join: ows (~ows@83.132.99.46) joined #forth 19:17:48 --- quit: saon (Remote closed the connection) 19:23:07 --- part: thinfu left #forth 19:28:39 --- join: saon (1000@c-24-129-90-197.se.client2.attbi.com) joined #forth 19:32:10 heh, pnmtopng is not happy with my 5120x4096 image 19:41:59 scanning something? 19:55:28 --- quit: tathi ("booting herkforth") 19:55:57 --- quit: slava ("Leaving") 19:56:26 no. Jenny just tried the digital photo printer thing at CVS and it came out nice, I'm going to try printing some of my koch fractals, and I'm bringing some different resolutions to see how high I need to go before it doesn't make a difference 20:04:17 --- join: paf (~paf@ip68-2-83-174.ph.ph.cox.net) joined #forth 20:16:52 --- quit: ows (Excess Flood) 20:17:36 --- join: ows (~ows@83.132.99.46) joined #forth 21:09:37 --- join: Sonarman (~snofs@adsl-64-169-93-25.dsl.snfc21.pacbell.net) joined #forth 21:25:35 --- quit: Sonarman_ (Read error: 110 (Connection timed out)) 21:52:40 --- join: gNoam (37373636@Orleans-ppp42601.sympatico.ca) joined #forth 21:52:43 --- part: gNoam left #forth 22:15:13 --- nick: Obakeneko -> yumehito 22:16:58 --- quit: ows ("Client Exiting") 22:22:19 --- join: Sonarman_ (~snofs@adsl-64-169-93-215.dsl.snfc21.pacbell.net) joined #forth 22:30:48 --- quit: onetom (Read error: 104 (Connection reset by peer)) 22:33:03 --- quit: Sonarman (Read error: 110 (Connection timed out)) 22:33:13 --- join: onetom (~tom@cab.bio.u-szeged.hu) joined #forth 22:34:37 --- quit: Herkamire ("bed") 23:25:43 --- quit: paf ("Leaving") 23:35:04 --- quit: Sonarman_ (Read error: 110 (Connection timed out)) 23:41:36 --- quit: I440r_ ("Leaving") 23:49:55 --- join: bbls (~bbls@80.97.121.133) joined #forth 23:59:59 --- log: ended forth/04.12.19