-
Notifications
You must be signed in to change notification settings - Fork 64
Open
Labels
Milestone
Description
Function-local liveness analysis. This is easy to do because there are no loops within a single function. It is important not to leave this to the C compiler because we manage the stack explicitly - we want to save only live variables after copy propagation. The C compiler cannot remove unnecessary saves (pushes to the stack) because it's not aware of JuvixAsm semantics.
Type info available in JuvixAsm can help remove more pushes: the variables of non-allocated types (e.g. bool, enum) do not need to be saved in Prealloc and can be considered "not live" for this purpose.
Copy propagation in JuvixReg will need to adjust the live variables.
Reactions are currently unavailable