Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.freenet.ag!takemy.news.telefonica.de!telefonica.de!feed.news.schlund.de!schlund.de!news.online.de!not-for-mail From: Bernd Paysan Newsgroups: comp.lang.forth Subject: Re: gforth too bloated ? Date: Wed, 21 May 2014 20:54:38 +0200 Organization: 1&1 Internet AG Lines: 36 Message-ID: References: <4b4ea6f6-3b09-434a-a501-ff31190b9f4a@googlegroups.com> <2014May16.183349@mips.complang.tuwien.ac.at> <2014May18.131531@mips.complang.tuwien.ac.at> <2014May20.143604@mips.complang.tuwien.ac.at> <2014May20.174816@mips.complang.tuwien.ac.at> <2014May21.162847@mips.complang.tuwien.ac.at> NNTP-Posting-Host: p4ffb966b.dip0.t-ipconnect.de Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7Bit X-Trace: online.de 1400698479 6524 79.251.150.107 (21 May 2014 18:54:39 GMT) X-Complaints-To: abuse@einsundeins.com NNTP-Posting-Date: Wed, 21 May 2014 18:54:39 +0000 (UTC) User-Agent: KNode/4.11.5 Xref: csiph.com comp.lang.forth:30530 Andrew Haley wrote: > I didn't have to discover that a primitive generator was used, find > its documentation, figure out its syntax, or anything like that. I'm > sure that if you want to make hundreds of primitives, a primitive > generator is the way to go, but if you just want to add one... What if you tried that with Gforth? over ( w1 w2 -- w1 w2 w1 ) core + ( n1 n2 -- n ) core plus n = n1+n2; Guess: over+ ( n1 n2 -- n1 n3 ) core over_plus n3 = n1+n2; Unfortunately, the superinstruction generator is not good enough to let you simply specify over+ = over + (yeah, it's almost there ;-). What we would need to make things simpler: Automated translation of Forth names to C-compatible symbols (so that you don't have problems with over+ not being a legal C label)... The problem that it takes more than 150ms to recompile the engine is yours, Andrew, this is a GCC problem ;-). Yes, it's nice to have a Forth-in-Forth, where all these recompilations happen in the blink of an eye. -- Bernd Paysan "If you want it done right, you have to do it yourself" http://bernd-paysan.de/