2024-08-17 14:16:16 +02:00
|
|
|
# Intermediate code generation
|
|
|
|
|
2024-09-27 00:22:44 +02:00
|
|
|
- All procedure calls a generated with a single arguments. To support more
|
|
|
|
arguments they should be put onto the stack, above the stack pointer.
|
|
|
|
The stack can grow on demand and then be cleaned up (the call instruction
|
|
|
|
contains the number of arguments, so the stack size can be reduced), or the
|
|
|
|
function with most arguments can be found and the stack size allocated.
|
|
|
|
To access the arguments inside a procedure, the information about argument
|
|
|
|
names should be kept somewhere.
|
2024-09-08 22:53:07 +02:00
|
|
|
|
|
|
|
# ELF generation
|
|
|
|
|
|
|
|
- Don't ignore relocations where the symbol is not defined in the symbol table.
|
|
|
|
Report an error about an undefined symbol.
|
2024-09-20 13:32:24 +02:00
|
|
|
|
|
|
|
# Name analysis
|
|
|
|
|
|
|
|
- Format error messages.
|
2024-09-24 22:20:57 +02:00
|
|
|
- Return non-zero error code on errors.
|
|
|
|
|
|
|
|
# Built-in
|
|
|
|
|
2024-09-27 00:22:44 +02:00
|
|
|
Printi should print a sign for negative numbers.
|