-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
[TIR][Analysis] Add SuggestIndexMap for layout rewriting #10732
Conversation
Co-authored-by: Siyuan Feng <[email protected]> Co-authored-by: Bohan Hou <[email protected]> Co-authored-by: Hongyi Jin <[email protected]> Co-authored-by: Ruihang Lai <[email protected]> Co-authored-by: Junru Shao <[email protected]> Co-authored-by: Xiyou Zhou <[email protected]>
Co-authored-by: Junru Shao <[email protected]>
Array<arith::IterSumExpr> iter_sum_exprs = arith::DetectIterMap( | ||
{analyzer->Simplify(index)}, input_iters, predicate, require_bijective, analyzer, diag_ctx); |
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.
I found it less convincing to couple frontend features (DiagnosticContext
) with purely arithmetic analysis. we ideally should remove this argument in DetectIterMap @wrongtest
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.
@junrushao1994 Hi, any suggestion for the dbg info in DetectIterMap
? We may remove them or change to logging if the diag ctx is not preferred.
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.
Generally speaking, DiagnosticContext
is a frontend feature, while arithmetic analysis is considered as a backend utility, which could be used with or without a particular frontend. Therefore, I would prefer moving error reporting to more frontend places instead of mixing them together in the backend
This PR added an analysis function `SuggestIndexMap` to analyze buffer access pattern and suggest index map for layout transformations. Co-authored-by: Siyuan Feng <[email protected]> Co-authored-by: Bohan Hou <[email protected]> Co-authored-by: Hongyi Jin <[email protected]> Co-authored-by: Ruihang Lai <[email protected]> Co-authored-by: Junru Shao <[email protected]> Co-authored-by: Xiyou Zhou <[email protected]>
This PR added an analysis function
SuggestIndexMap
to analyze buffer access pattern and suggest index map for layout transformations.Co-authored-by: Siyuan Feng [email protected]
Co-authored-by: Bohan Hou [email protected]
Co-authored-by: Hongyi Jin [email protected]
Co-authored-by: Ruihang Lai [email protected]
Co-authored-by: Junru Shao [email protected]
Co-authored-by: Xiyou Zhou [email protected]
cc @junrushao1994 @jinhongyii @masahi