Jump to content
Sign in to follow this  
dougmoran

Looking for a Forth compiler or assember

Recommended Posts

dougmoran

Hey folks, does anyone happen to have code for a Forth compiler or assembler in Autoit3?

Share this post


Link to post
Share on other sites
Richard Robertson

I highly doubt it. Why do you want Au3 source to something like that?

Share this post


Link to post
Share on other sites
dougmoran

I'm using a stack processor in an FPGA design. The processor's assembly language is modeled after forth and I'm looking for a simple way to build an assembler or compiler using AutoIT because I'm most familiar with that language.

Share this post


Link to post
Share on other sites
Richard Robertson

I've never heard of any real compiler written in AutoIt. Most likely because it's not the best language for managing the kinds of things a compiler would need to manage.

Share this post


Link to post
Share on other sites
ZOTHOP

Good luck to create a compiler particulary for assembler !

Share this post


Link to post
Share on other sites
twitchyliquid64

fpga? isn't that really hard to develop logic for?

man that shit is intense.


ongoing projects:-firestorm: Largescale P2P Social NetworkCompleted Autoit Programs/Scripts: Variable Pickler | Networked Streaming Audio (in pure autoIT) | firenet p2p web messenger | Proxy Checker | Dynamic Execute() Code Generator | P2P UDF | Graph Theory Proof of Concept - Breadth First search

Share this post


Link to post
Share on other sites
Mat

FPGAs are pretty easy when you have something like LabView to do it for you :graduated:

I don't see why AutoIt can't be used as a compiler. It would be slow though as compilers usually have to manage a lot of data (in general, I've never used forth). Due to the nature of compilers, there isn't much advantage in using AutoIt. There is little need for dynamic types, and a real need for either classes or structures.

There is an example of a lexer (by Manadar) and a parser (by me) here: Turning those into a compiler is a bit more tricky, you'll have to look at my C example to output an AST from the parser rather than executing as you go. From then you'll have to look at code generation.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×