Skip to content

Conversation

@j2kun
Copy link
Collaborator

@j2kun j2kun commented Sep 10, 2025

  • Add rns.extract_slice op as a helper to partition RNS limbs, including a type inference hook
  • Fixes the lowering to partition RNS limbs instead of polynomial coefficients (a showcase of my ignorance!)
  • Adds tests with the dialect conversion config option to allow us to test the partial lowering

module attributes {
ckks.schemeParam = #ckks.scheme_param<
logN = 14,
Q = [36028797019389953, 35184372121601, 35184372744193, 35184373006337, 35184373989377, 35184374874113],
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I should update these primes to match the rns_full defined above.

Copy link
Collaborator

@AlexanderViand AlexanderViand left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry for the late review!

This commit adds a build-materializations option to
polynomial-to-mod-arith, which will be deleted after the keyswitch
lowering is done. This allows us to properly run lit tests of the
partial lowering implementation.
@j2kun j2kun force-pushed the fix-keyswitch-inner branch from 4b492c6 to 2b8bfdb Compare September 17, 2025 16:24
@j2kun j2kun added the pull_ready Indicates whether a PR is ready to pull. The copybara worker will import for internal testing label Sep 17, 2025
@copybara-service copybara-service bot merged commit 1c8f640 into google:main Sep 17, 2025
9 of 10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pull_ready Indicates whether a PR is ready to pull. The copybara worker will import for internal testing

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants