kevinpt / opbasm

Open PicoBlaze Assembler
http://kevinpt.github.io/opbasm/
MIT License
60 stars 13 forks source link

did you have any plan to create a compiler for kcpsm #11

Closed buaabyl closed 8 years ago

buaabyl commented 8 years ago

I have try picoblaze porting of sdcc, but it is many bugs. Did you have any plan to create a compiler?

I have my piclblaze assembly https://github.com/buaabyl/picoblaze_utils And I still reading gcc and llvm, but it is not easy for 8-bits porting...

kevinpt commented 8 years ago

No. The PicoBlaze architecture isn't well suited for a compiled language that makes heavy use of stack. You will end up burning too much program and scratchpad memory trying to emulate a C compatible machine. The attempts in the past haven't been particularly successful. I think it's better to work at a level that maps better to the capabilities of the PicoBlaze. That is why I've built up a library of m4 macros to streamline code reuse. The macros that provide conditional and looping constructs help a lot in writing more structured code that is still readable a few months after you've written it.

buaabyl commented 8 years ago

Thanks.