Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor Binary Identity Simplification Macro
This commit cleans up the BINARY_IDENTITY_OP and BIANRY_IDENTITY_OR_ZERO macros and replaces them with inline equivalents by implementing a struct to replace template instantions of the functions tryAndSimplifyBinaryOp*. This change limits the number of template instantiations potential call sites have to create as well as abstracts some captured variables inside the struct to minimize the number of arguments passed to actual calls. A closure is emulated by the struct. Through escape analysis, scalar replacement and inlining, the overhead of creating this struct should be minimal on -O3 Related: #7166 Signed-off-by: James You <[email protected]>
- Loading branch information