Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Include stack effects of uops when computing maximum stack depth
UOPs may want to pass values on the stack. This is currently only guaranteed to be possible if the net stack effect of the instruction is greater than the number of values that need to be passed. To ensure there is sufficient space on the stack for values passed between uops, we: 1. Compute the set of stack effects for each instruction by computing the stack effect after each uop in the instruction. 2. Collect the set of stack effects for all instructions in a family. 3. Generate a function that computes the maximum stack effect for each instruction. The maximum stack effect for a generic instruction is the maximum of all instructions in the family. 4. Use the maximum stack effect when computing the maximum stack depth of a function.
- Loading branch information