r/Compilers • • Jul 30 '26

I'm making a bytecode compiled language

14 Upvotes

7 comments sorted by

View all comments

Show parent comment

1

u/Longjumping-Jacket97 Jul 31 '26

Isn't this just a bytecode assembler? It doesnt seem like a whole programming language which would use a pipeline of lexing->parsing->semantics(technically optional)->compiler

1

u/Beginning-Tank-3770 Jul 31 '26

Now that I think of it

Yes it's an assembler, as it's a very direct bytecode mapper. But given that the output is bytecode and not actually machine instructions, and it does go through parsing and syntax checking, then it a mix of a bytecode assembler and a compiler

Thanks for asking!

1

u/Samuel_Bouchard Aug 01 '26

Assembler do parse and check for syntax. It is the bare minimum for any program that takes in user code to transform it into something else. That's what assemblers and compilers do. The only difference is that an assembler takes in simple opcodes (assembly language) and directly turns them into binary, while a compiler takes in higher-level language programs, applies transformations on them to optimize them, then emits assembly code.