Skip to content

Conversation

@copybara-service
Copy link

[opt] Update StrengthReductionPass to expand select sinking.

The pass now sinks operations into a Select not only when non-select operands are constant, but also when the operation would simplify due to the select_val being a critical operand (e.g., array index, slice start, shift amount, or selector).

Also replaces LazyTernaryQueryEngine with PartialInfoQueryEngine in StrengthReductionPass.

The pass now sinks operations into a `Select` not only when non-select operands are constant, but also when the operation would simplify due to the `select_val` being a critical operand (e.g., array index, slice start, shift amount, or selector).

Also replaces `LazyTernaryQueryEngine` with `PartialInfoQueryEngine` in `StrengthReductionPass`.

PiperOrigin-RevId: 822621831
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant