For an architecture * that does not have a stack or memory allocation *, what is the most expressive programming language?

I am working on a proprietary sequencer that has several bytes of free memory; several hundred bytes statically distributed; 8 registers, including PC; lack of indirection (in C, "pointer"); no stack.

There is no instruction MOV: to move Min K, you have to write CLX A; ORX M; STX K, which greatly complicates the resolution of dependencies, or at least the optimization. Many operations work only with certain registers: for example, a 32-bit right shift is used Kin the upper word and Min the lower word.

Thus, the obvious choice of C for embedded applications is not possible, since no pointers or function calls are possible. Most higher-level programming languages ​​have arithmetic expressions, so this does not help narrow our choices.

Most important is the absolute minimum code size, so optimization is key.

My tendency is to compile Lisp expressions as a form of macro assembler, as a programmer can optimize their own higher-level operations, for example, write an instruction XOR.

I am sure this is not the first project ever to have such limitations; How was this decided in the past?

+5
source share

No one has answered this question yet.


All Articles