Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.forth > #13906
| Date | 2012-07-12 19:58 +0200 |
|---|---|
| From | Fanzo <cristianof6@gmail.com> |
| Newsgroups | comp.lang.forth |
| Subject | Re: colon colon |
| References | <4ffc6c61$0$1375$4fafbaef@reader2.news.tin.it> <jtjbpa$udi$1@speranza.aioe.org> <4ffdcf39$0$1378$4fafbaef@reader2.news.tin.it> <jtm4g7$dr9$1@speranza.aioe.org> |
| Message-ID | <4fff0f8a$0$1390$4fafbaef@reader2.news.tin.it> (permalink) |
| Organization | TIN.IT (http://www.tin.it) |
Rod Pemberton wrote: > For DTC or ITC, the CFA field tells whether to execute or interpret the > word. So, the first word of xt's is interpreted and the second word with > OPCODEs is executed. It's called a primitive or low-level word. The first > word has it's CFA set to ENTER. ENTER is an address interpreter. > Basically, ENTER calls the xt's. The second word has it's CFA set to the > address of the routine. I know ITC, my first version of my forth was ITC in C, but then i changed (no interest in speed comparison). I see the STC more simple for me. And also less structure at the beginning to change it later. My variables are routine themself. > > DROP can be an unused POP. Do you have a spare register? > The assembler is a virtual machine of 24 opcodes (POP is one of them that just put TOS in the bin) > DROP might be implementable in others ways, e.g.: > > 0 AND OR > > >R RDROP > > A! \ store into variable > I used my custom word "now" to compile "POP RET" and execute it when needed. But this routine get compiled in a transient buffer of 30 CELLs. There, every opcode needed can be put afterward to execute something on the fly. Goodbye
Back to comp.lang.forth | Previous | Next — Previous in thread | Find similar
colon colon Fanzo <cristianof6@gmail.com> - 2012-07-10 19:58 +0200
Re: colon colon "Rod Pemberton" <do_not_have@notemailnot.cmm> - 2012-07-11 04:01 -0400
Re: colon colon Mark Wills <markrobertwills@yahoo.co.uk> - 2012-07-11 02:01 -0700
Re: colon colon Fanzo <cristianof6@gmail.com> - 2012-07-11 21:11 +0200
Re: colon colon "Rod Pemberton" <do_not_have@notemailnot.cmm> - 2012-07-12 05:15 -0400
Re: colon colon Fanzo <cristianof6@gmail.com> - 2012-07-12 19:58 +0200
csiph-web