[TODO-List-Cleanup] Delete obsolete code from gtSetMultiOpOrder#70216
[TODO-List-Cleanup] Delete obsolete code from gtSetMultiOpOrder#70216BruceForstall merged 1 commit intodotnet:mainfrom
gtSetMultiOpOrder#70216Conversation
|
Tagging subscribers to this area: @JulieLeeMSFT, @jakobbotsch Issue DetailsRemove references to preserving previous behavior. Use the generalized Sethi-Ullman algorithm for computing the "level" of multi-operand nodes. What's the explanation for the algorithm?The problem being solved is that of how many registers does an N-ary node need in order to be evaluated. First, we observe the numbers for the simplest case of a binary operator: The N-ary case can be reduced down to a series of binary ones, for example, for a 4-ary node we would have: Thus, to find the number of registers we would walk this tree in post-order, evaluating each binary node with the formula derived above. Such a post-order walk is equivalent to the reversed linear loop over the operands implemented in this change. Closes #6622.
|
[TODO-List-Cleanup] Remove obsolete code from gtSetMultiOpOrdergtSetMultiOpOrder
|
Will assume the @dotnet/jit-contrib |
Remove references to preserving previous behavior. Use a better algorithm for calculating the "level" of MultiOp nodes.
3a9ae10 to
8481206
Compare
Remove references to preserving previous behavior.
Use the generalized Sethi-Ullman algorithm for computing the "level" of multi-operand nodes.
What's the explanation for the algorithm?
The problem being solved is that of how many registers does an N-ary node need in order to be evaluated.
First, we observe the numbers for the simplest case of a binary operator:
The N-ary case can be reduced down to a series of binary ones, for example, for a 4-ary node we would have:
Thus, to find the number of registers we would walk this tree in post-order, evaluating each binary node with the formula derived above.
Such a post-order walk is equivalent to the reversed linear loop over the operands implemented in this change.
Closes #6622. Addresses the last
TODO-List-Cleanup.A small number of positive diffs.