-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Scatter lowering #273
Scatter lowering #273
Conversation
We might want to wait until #216 is merged, since that PR is fairly heavy and close to being merged. It shouldn't be too much work to adapt this PR to the new compiler driver. |
…alyst into scatter_lowering
[sc-41325] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Still looking at it. Some small comments first.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome! Great work @rmoyard!
Description of the Change:
In the quantum dialect, I add a lowering for MHLO scatter to the MLIR tensor dialect. The reference for the implementation can be found here https://github.com/openxla/stablehlo/blob/main/docs/spec.md#scatter
Benefits:
This unlocks Jax array index with at and apply functions on it, for example:
Possible Drawbacks:
Some edge cases not properly covered.