Skip to content

Merge dynamic constant propagation into the constprop pass - #146

Open
amarkdotdev wants to merge 1 commit into
google:mainfrom
amarkdotdev:merge-constprop-passes
Open

Merge dynamic constant propagation into the constprop pass#146
amarkdotdev wants to merge 1 commit into
google:mainfrom
amarkdotdev:merge-constprop-passes

Conversation

@amarkdotdev

Copy link
Copy Markdown

Ordinary and dynamic constant propagation run the same rewrite; the dynamic path only loads JsirDynamicConstantPropagationAnalysis (prelude matching) first. There is no reason for two MLIR pass classes.

JsirConstantPropagationPass now handles both JsirTransformConfig kinds. PerformDynamicConstantPropagation lives next to PerformConstantPropagation, and the old dynamic pass .cc is gone. CLI names (constprop / dynconstprop) and proto fields are unchanged.

Fixes #19

Both transforms apply the same rewrite; the dynamic path only swaps in a richer analysis. One MLIR pass now covers both configs.

Fixes google#19

Signed-off-by: Aaron <amark@g.jct.ac.il>
@phisiart

Copy link
Copy Markdown
Collaborator

Thanks for the contribution! We currently only have a process to sync internal changes to github, but not the opposite direction. I'll need to manually create a matching internal change and merge your PR at just the right time :) This will take some time (maybe several days) to figure out, so please be patient in the meantime.

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.

Merge dynamic_constant_propagation and constant_propagation

2 participants