Skip to content

Make rotation analysis more robust for loops with if statements - #2788

Merged
copybara-service[bot] merged 1 commit into
mainfrom
test_885851705
Mar 20, 2026
Merged

Make rotation analysis more robust for loops with if statements#2788
copybara-service[bot] merged 1 commit into
mainfrom
test_885851705

Conversation

@copybara-service

Copy link
Copy Markdown
Contributor

Make rotation analysis more robust for loops with if statements

Here the problem was that, for more complicated looped kernels,
the rotation analysis was not evaluating the loop correctly.
The previous implementation was trying to skip various intermediate
operations on tensors/ciphertexts, but this causes the DAG to be disconnected
and so the loop's yield may not end up being visited, so that it doesn't
proceed to the next iteration and truncates the rotations at the first
one found (without these changes, the if_else.mlir test will only annotate with
the index 512).

@copybara-service
copybara-service Bot force-pushed the test_885851705 branch 6 times, most recently from 4424d31 to fc7fe8e Compare March 20, 2026 00:20
Here the problem was that, for more complicated looped kernels,
the rotation analysis was not evaluating the loop correctly.
The previous implementation was trying to skip various intermediate
operations on tensors/ciphertexts, but this causes the DAG to be disconnected
and so the loop's yield may not end up being visited, so that it doesn't
proceed to the next iteration and truncates the rotations at the first
one found (without these changes, the if_else.mlir test will only annotate with
the index 512).

PiperOrigin-RevId: 886472605
@copybara-service
copybara-service Bot merged commit a471a80 into main Mar 20, 2026
@copybara-service
copybara-service Bot deleted the test_885851705 branch March 20, 2026 01:02
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