Conversation
do you think everyone implementing forth on the desktop goes "ok this is going to be the ultimate forth implementation to beat all other desktop forth implementations" or am i just delusional

to be fair i intend to release it as 0bsd while also still including a decent enough spread of extensions as to be actually nice to use for desktop development (particularly gforth compatible c-interop. but using pkg-conf instead of libtool because why the fuck would i use libtool lol)
2
1
6
like thats best of both worlds material right there
0
0
2
@coolbean i think most are just people fucking around and doing whatever changes they think would be cool
1
0
0
@snacks well i think my changes are cool and like actually useful for writing programs because pforth is too plain and gforth too gnu and neither is optimising
1
0
2
@coolbean i thought gforth is optimizing but i also vaguely remember you explaining smth about that. Explaining rn makes no sense tho, my brian is just self cooking rn
1
0
0

@coolbean it def does some peephole optimizations

: foo 15 1 + * 2 pick 3 - ;

see foo \ output below
: foo  
  #4 lshift third #-3 + ; ok
1
0
1
@snacks it definitely isnt like part gcc frontend is what im saying
1
0
1
@snacks i still havent decided how im gonna handle integer types. like if n is 64bit would d be 128bit or would it be 32 and 64bit. the latter makes far more sense and match ia32 convention but then most arithmetic words on an amd64 build would take d instead of n and thatd be strange conventionally
1
0
1
@snacks + offering 128bit stuff isnt unheard of either, ipv6 addresses are 128bit integers after all
1
0
1
@snacks but 32bit desktops are still definitely around

bah
1
0
1
@snacks although, is it really that unusual to make your standard cell size d equivalent to a double? for 16bit forths its totally normal and 32bit as well where 32 becomes w

so difficult
2
0
0
@coolbean idk about 16 bit forths but afaik most stuff on avr still uses 8 bit cells. That's exacrly what all the 2* words where made for i think
1
0
1
@snacks yea thats a funny thing, most forths on 8bit platforms are still 16bit forths thats why you use 2@ and 2! as well
0
0
1
@snacks i have decided i shall follow qbe covention so n is any size of integer, and the individual sizes are b d w l
1
0
1
@snacks what a tangent, man. such bullshit
1
0
1
@coolbean i'd just gonna go with register size cells, hatever that means for the target architecture. But then my dream forth is typed anyway so it's not too concerning for me
1
0
1
@snacks i feel like itd be more relevant in that case
1
0
0
@coolbean typed language seems less married to a specific number type?
1
0
0
@coolbean int without further specification is 32 bit, idgaf
1
0
1
@snacks oh also 128bit is vl for very long in reverence to very long instruction word architectures
0
0
1
@coolbean i could go down to 16 bit but 64 is just wasteful and 8 too restrictive
2
0
1
@coolbean in untyped forth your basic number type kinda has to be pointer sized
2
0
1
@coolbean or pointers get annoying
0
0
1
@coolbean it's usually register size for perf tbh
0
0
1
@snacks gforth does 64 and while i was initially skeptical, is 512 vs 1024 words per (relatively small, theres 8 and 16KiB ones on arm/rv64) memory page actually that bad?
1
0
0
@coolbean you could also do smth like -mx32 by default
1
0
1
@coolbean who meeds more than 3.5GB
1
0
1
@snacks im not gonna do that. i can barely be bothered to accomodate 32bit at all
0
0
1