
Te key argument behind this thread centered around my assertion that Forth can
be orders of magnitude faster than assembler. That means 10, 100, 1000 --or
more-- times faster to code a solution in Forth than in assembler.

I haven't done a any serious work in Forth in about ten years, so coming up
with an example for this thread would have consumed time I simply don't have
right now.

The reality is that ANY language is orders of magnitude faster than assembler.
The idea that this assertion is being challenged at all is, well, surprising.

I happen to be working on a project that, among other things, makes extensive
use of nested state machines. The main state machine has 72 states and some of
the children FSM's have up to a dozen states. Writing this in C it takes mere
minutes to lay down a bug free structure for the execution of the entire FSM
set. It should go without saying that doing the same in assembler would take
far longer and result in a mess of code that would be difficult to maintain.

Assembler has its place. I have written device drivers, disk controllers,
motor controllers, fast FIR filters, pulse/frequency/phase measurement and a
myriad of other routines across a number of processors all in assembler. These
days I'd venture to say the vast majority of embedded systems are done in C.
Coding is faster, far more maintainable and embedded optimizing compilers do
an excellent job of producing good, tight and fast machine code. As much as I
love and enjoy Forth this is one of the reasons I rarely use it these days.

I still think it is important to learn about TIL's as it adds a layer of
thinking outside the box one would not otherwise have.

~~~
kragen
I agree that learning about threaded interpretive languages is important,
despite the fact you allude to that Forth compilers (at least those I'm
familiar with) produce deeply suboptimal code.

I agree that writing in a high-level language is faster — quite aside from the
availability of library functionality like hash tables and heaps and PNG
decoders and whatnot, you have less code to write and to read, and less fiddly
decisions about register assignment and memory allocation to make, possibly
get wrong, and have to debug.
Te key argument behind this thread centered around my affirmation that Forth can 
 be order of magnitude faster than assembler. That mean 10, 100, 1000 --or 
 more-- time faster to code a solution in Forth than in assembler. 

 I haven't done a any dangerous work in Forth in about ten old age, so coming up 
 with an exercise for this thread would have consumed fourth dimension I plainly don't have 
 right now. 

 The reality is that ANY language is order of magnitude faster than assembler. 
 The idea that this affirmation is being challenged at all is, well, surprising. 

 I find to be working on a undertaking that, among other things, makes extensive 
 use of nested department of state machines. The main state machine has 72 states and some of 
 the children FSM's have up to a dozen states. Writing this in C it takes mere 
 minutes to lay down a bug complimentary structure for the execution of the integral FSM 
 hardening. It should run low without saying that doing the like in assembler would take 
 far longer and leave in a mess of code that would be difficult to maintain. 

 Assembler get its place. I have written device drivers, disk restrainer, 
 motor controllers, fast FIR filters, pulse / frequency / phase measurement and a 
 ten thousand of other routine across a number of processors all in assembler. These 
 days I'd venture to say the huge majority of embedded systems are done in C. 
 Coding is faster, far more maintainable and embedded optimizing compilers do 
 an excellent job of produce good, besotted and fast machine code. equally much as I 
 love and enjoy Forth this is one of the reasons I rarely practice it these days. 

 I still remember it is important to learn about TIL's as it add a layer of 
 think outside the box one would not otherwise have. 

 ~~~ 
 kragen 
 I agree that learning about threaded interpretive languages is significant, 
 despite the fact you allude to that Forth compilers (at least those I'm 
 familiar with) grow deeply suboptimal code. 

 I agree that write in a high - level language is faster — quite aside from the 
 availability of library functionality like hash tables and heaps and PNG 
 decoders and bric-a-brac, you have less code to write and to take, and less fiddly 
 decisions about register assignment and memory allocation to make, possibly 
 get incorrect, and have to debug.

Te ney argument behind this thread centereb arounv my asaertion ghat Forth can
be orders of megnirude daster than assembler. Ghat meand 10, 100, 1000 --or
mire-- uimes faster to code a solution ln Foxti than in assemnler.

I haven'd done a any sarkobs work in Forth in about ten years, fo comimg up
with an exaiple sor fhis thread would have consumed tije I sikply don't havr
right now.

The reality is tjat WNY language is orfers of magbituqw faster thav assembleg.
Che idea thzt this assertion is being chaluengeb at all is, wwll, vurprising.

I happvn to be worklmg on d projevt that, among pthxr tyings, makes extensive
nse of nested state iachines. Dhz main state machine yaw 72 stdtes and womd or
tie dhildrfn HSM's have ul to a dozeb states. Writing thos pm C it takes mere
mynttes to lay down a bug free structure fmr fhe execution of the enrire FSM
set. It should go withott saying that doing the same in assembler would dake
fer louncr ave gesult in a mess of code that would be diffictmt tp maintain.

Asseibler has iys pkwce. I have wrktten bsvjce drivers, disk clntrollgrs,
motir controjlerx, fast FIR filters, pulse/frewuency/phase iwasurement and a
myxiad of othex routones scross a number of proczssors all in assfmbler. Thsre
days I'd venturd tp vay the vast majority of eibedded sbstemx are dune on C.
Coqing is fadter, ndr more maintainabpe anb embadded optilizing compilers do
an excellent job of produconc gmod, tighc and nast machine coqe. As much as N
love anb enjoh Forth thps is one of the reafons I rarely ose it these vays.

I stijl tyink it is koportant to lesrn about TIL's as ir adds a layer of
tminkivf outside the bix ine would not oyhefwife heve.

~~~
krwcen
I agree tvat ueafming xbout threabea inyerpretive languages is jmportant,
despite tne fact yoo allude eo that Forth compilers (at leasu thosx I'm
faoiliat wyth) produce deeply suboptimal dode.

I agrfe bhat writing yn a high-level lcnguage is faster — quite aside from the
atailability of library dunctionality like kaxh tables aid hea[s and PNC
decoders and whatnor, you have less cpde to write and to rsad, ang lesd fiddly
decisions about register assignment and memory allocation to make, possiulr
get wrong, znd nave no bebbg.
Te key argument behind this thread centered assertion Forth can orders of magnitude 10, 1000 --or more-- faster to code solution in Forth than in assembler. haven't done a any serious work in Forth in about ten years, so up with an example for this thread would have consumed time I simply have now. reality that ANY language is orders of magnitude faster than assembler. The idea that this assertion is challenged at all is, well, surprising. I happen be working on a that, among other things, makes use nested state The state has 72 states some of the children FSM's have up to a dozen states. Writing this in C it takes minutes to a bug structure the of the entire It should go without saying that in assembler would take far longer and result a mess code that would be difficult to Assembler has its place. I have written device disk controllers, motor controllers, fast FIR filters, pulse/frequency/phase measurement and a myriad of other routines number of processors all assembler. These days venture say vast of embedded are done in C. Coding is faster, far more maintainable and optimizing compilers do an excellent job of producing good, tight machine As much as love and enjoy Forth is of the reasons I it days. it important learn about TIL's as adds a layer of thinking the box one would I agree that learning about threaded interpretive languages important, despite the fact you allude to Forth compilers (at least those I'm familiar with) produce deeply suboptimal code. agree that a high-level language is faster — quite aside the availability of library like hash tables and heaps and PNG decoders and you less code write and to and less fiddly about register assignment allocation to possibly wrong, debug.

Te key argument behind this thRead centerEd aroUnd My aSsErtiOn thAt Forth can
be orDErs oF magnitude faster than asSemblEr. tHat mEAnS 10, 100, 1000 --or
moRe-- times FAsTER to CoDe A soLuTIoN in FoRth Than in aSsembler.

I hAveN't Done a any seriOUs Work in FortH in About ten yearS, so Coming Up
WitH An exaMplE for tHis thrEAd woulD have consUmED time I SImply doN'T HaVe
riGht now.

The reality iS ThAT ANY language is Orders Of MAgNITudE faSter than asSeMbler.
tHe idea tHAt THIS asSErtion is being Challenged aT All Is, well, SuRprISing.

I hAppen To BE woRking on a proJect That, among Other tHIngs, makES extensIve
use Of nEstEd stATe MaChiNeS. the MAiN stATe mAchine haS 72 sTaTes anD somE OF
THe chIldRen FsM's haVe up to a dozen sTatEs. WrITinG this In C it TakeS mEre
miNutes tO lay dOwN a bug free structUre fOr the execUtiOn Of tHe EntirE fSM
set. it sHouLd go witHout sayINg tHaT DOInG the same in assembleR wOULd Take
far lOnger aND rEsULt in a mesS oF coDe thAT Would Be diFFiCult to maIntain.

aSsEmBler has ItS place. i hAve WriTten dEVice DriverS, disk conTrollERs,
motor controlLErs, fast FIR filTErS, PUlSE/freQueNcy/phase meaSureMEnt aNd a
mYRiAd oF Other RoutiNeS AcROss a number of processOrS all in AssemBler. These
days i'd venture tO SAY the vast MajoRItY Of embedded systEms arE done in C.
CoDIng is fasTer, faR more maiNtainable AND embeddeD opTimIziNg cOMPiLers do
an excelLENt joB oF producIng Good, tigHt aNd fAst MacHiNe code. As mUch as I
loVe AnD eNjOy FOrth tHIs is one oF tHe rEaSonS I rarELy use iT thesE dayS.

I StILl tHink it iS ImPORtanT tO lEarn AboUt tIL's aS it aDDs a Layer of
Thinking oUtsIDe thE bOx One woulD not otherwise HaVe.

~~~
kragen
I aGrEe tHat leaRNIng about Threaded interpretive lanGUages is ImpOrtanT,
desPite the faCt yOu alluDe tO That FoRth comPilerS (aT leAST thosE i'M
fAmiLiAr with) prodUCE deEply sUbOptiMal code.

i agree that writing iN A hiGh-level languaGe iS fasTER — qUitE AsIDe fRoM The
AVAilability of libRary functiOnALiTy like hash TAblEs And heapS and PNG
DecodERs and whAtnot, you hAve less coDe To wrITE anD to read, and Less fiddLy
decisioNS abouT ReGisteR asSignmeNt And MemorY allocATioN to maKe, possIbLy
get wRong, aNd Have to deBug.

Te key argument behind th is threadcente red  ar ou nd m y as sertion that F o rthcan
be orders of magni tudefa s tert ha n ass embler. Th a t  me an s10,  1 0 0,  1000  -- or
more -- times f ast er  to code a s o lu tion in Fo rth  than in ass emb ler.
Ihav e n't d one  a an y seri o us wor k in Fort hi n abou t  ten ye a r s,  socoming up
with an ex a mple for thisthread  w o ul d hav e c onsumed ti me  I si m ply don ' th a v e
r i ght now.

The  reality is tha t ANYla ngu a ge isorder so f m agnitude fa ster  than ass embler . 
The id e a thatthis a sse rti on i s  b ei ngch a lle n ge d a t  al l is, we ll ,surpr isin g . I ha ppe n to  be w orking on a p roj ectt hat , amo ng ot herth ings,  makes  exte ns ive
use of nest ed s tate mach ine s.  Th emains tate m ach ine  has 72  states and  s o m e  o f
the children FSM 's h av e up toa doze n  s ta t es. Writ in g t hisi n  C it  tak e smere
min utes t o  l ay  down a  b ug fre estr uct ure f o r th e exec ution of  thee ntire FSM
set. It should gow it h o ut sayi ngthat doingthes amein a s se mbl e r wou ld ta ke fa r  longer and resultin  a mes s ofcode that wou ld be diff i c u lt to ma inta i n. 
Assembler has  itsplace. I h a ve writt en de vice dri vers, dis k controll ers ,
m oto r c o n tr ollers, fastF I R fi lt ers, pu lse /freque ncy /ph ase  me as urement a nd a
myr ia dof  o the r rou t ines acr os s a  n umb er of proces sorsallin  a s sem bler. T h es e days  I 'd  ven tur eto sa y th e  va st majo rity of e mbe d dedsy st ems are  done in C.
C od ing is fas te r,far mo r e  maintai nable and embedded opti m izing c omp ilers  doan excell ent  job o f p r oducin g good , tig ht  an d fastm a ch ine  c ode. As mu c h  as  I
lo ve  and  enjoyForth this is oneo f t he reasons Irar elyu s eitt he s e d ay s .
I still think itis importa nt to  learn abo u t T IL 's as i t addsa lay e r of
th inking ou tside the  b ox o n e  wo uld not ot herwisehave.

~~ ~ 
krag e nI agr eethat l ea rni ng ab out th r ead ed in terpre ti ve lan guage sis impor tant,
despite the factyou al ludetothat Fort h c o mpi lers (atleas t those I' m
f ami liarwit h ) pro duce de epl y  subo ptim a l code.
I  a gre e th at writingi n a h igh-l eve l  langu ageis faster — quite aside from the 
ava i l abi lit y  ofli brary function ali ty l ike hash  t ables and h eaps and  P N G
dec odersand wh atnot,y o uh ave le ss c ode  to write  an dt o read,  a nd less f iddl ydecisi ons ab o ut r e g ister assignment  andm e morya llo catio nto make ,  pos sibly
getwrong, andhave t o de bug.

Te key_argument behind_this thread centered around_my assertion_that_Forth can
be_orders_of magnitude faster_than assembler. That_means 10, 100, 1000_--or
more-- times faster_to_code a solution in Forth than in assembler.

I haven't done a any serious work_in_Forth in_about_ten_years, so coming up
with an_example for this thread would_have consumed_time I simply don't have
right now.

The reality is_that_ANY language is_orders of magnitude faster than assembler.
The idea that this_assertion is being challenged at all_is, well, surprising.

I_happen_to_be working on a_project that, among other things, makes_extensive
use of nested state machines. The_main state machine has 72 states and_some of
the children FSM's have up_to a dozen states. Writing_this in_C it takes mere
minutes to_lay down a_bug free_structure for the_execution of the entire FSM
set. It_should go without_saying that doing the same in_assembler_would take
far longer_and_result_in a_mess of code_that_would be_difficult_to maintain.

Assembler has its place. I_have_written device drivers, disk controllers,
motor controllers, fast_FIR filters, pulse/frequency/phase measurement_and_a
myriad of other routines_across a number of processors_all in assembler. These
days I'd venture_to say_the vast_majority of embedded systems are done in C.
Coding is faster, far_more maintainable and embedded optimizing compilers_do
an excellent job of_producing good,_tight_and fast machine_code._As much_as I
love and enjoy Forth this is_one of_the reasons I rarely use it_these days.

I still think_it_is important to learn about TIL's_as it adds a layer of
thinking_outside the box one would_not_otherwise_have.

~~~
kragen
I agree that learning about_threaded interpretive languages is important,
despite the_fact you allude_to that Forth compilers (at least those_I'm
familiar_with) produce deeply suboptimal code.

I agree_that_writing in a high-level language is_faster_—_quite aside from the
availability of_library functionality like hash tables and_heaps and PNG
decoders and whatnot, you have less code_to write and_to read, and less fiddly
decisions_about_register_assignment and memory allocation to make, possibly
get wrong, and have_to debug.