If I create a new programming language, should I compile assembly or C?

I am making a language based on a different mathematical model than is commonly used. If I use C, I’m not sure I can, because the model is so different from C. But then, if I use assembly code, it is not portable, is it? Is there a common assembly language that can be abstracted across all architectures, perhaps that I don’t know about? Or am I missing something? I believe that if C is Turing complete, then I should be able to compile it if my language is complete in Turing ... Is the assembly more powerful than C? If I need a compiled language, what are the compilation benefits for building and what are the compilation benefits for C?

+4
source share
1 answer

I would say that C. This will save you a lot of time compiling compilers for each platform, when you can write them, and let the C compiler do the dirty work for you. C was used as an intermediate language for many higher-level languages ​​with a design different from C, for example C ++.

In addition, there is no assembly language, which is a cross-platform without massive modification.

+1
source

Source: https://habr.com/ru/post/1435683/


All Articles