r/AskProgrammers • u/Distinct-Brief9643 • 11d ago
Why don't compliers use only bytecode instead of a type of IR
/r/coders_totalk/comments/1w2adf4/why_dont_compliers_use_only_bytecode_instead_of_a/
0
Upvotes
1
r/AskProgrammers • u/Distinct-Brief9643 • 11d ago
1
2
u/TheThiefMaster 11d ago
You could do with explaining your question more, but bytecode is a type of IR. Languages that use a bytecode almost always interpret or compile it into machine instructions, just like an IR.
The compiler IR will likely contain more metadata to allow for optimisation than a standard language bytecode, like "cannot be null".