-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
[CINN / PIR] Cinn trivalop fuse #62088
[CINN / PIR] Cinn trivalop fuse #62088
Conversation
你的PR提交成功,感谢你对开源项目的贡献! |
5a325f5
to
dfb0f89
Compare
export less methods in StmtFusionHelper
…ddle into cinn-trivalop-fuse
implement FuseFilteredStmtPatterns
…ddle into cinn-trivalop-fuse
Cinn trivalop fuse
fix compiler complaints
rename StmtIter to StmtPtr
declare group_pattern.InferShardableAxes
move group_pattern.InferShardableAxes to group_pattern_util.InferShar…
implement group_pattern_util.InferShardableAxes
add group_pattern_util.InferShardableAxesFromSink
extern ExprSetFinder Identity; | ||
|
||
extern ExprSetFinder Store2Value; | ||
|
||
extern ExprSetFinder Realizer2ScheduleBlock; | ||
|
||
extern ExprSetFinder ScheduleBlock2Body; | ||
|
||
extern ExprSetFinder ScheduleBlockRealizeNotRoot; | ||
|
||
extern ExprSetFinder ScheduleBlockRealizeIsNotInit; | ||
|
||
extern ExprSetFinder ScheduleBlockRealizeIsInit; | ||
|
||
extern ExprSetFinder IsFor; |
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.
这些地方最好弄成函数,不依赖extern。
const ExprSetFinder& GetIdentityExprSetFinder();
在对应的cc文件里弄一个函数内部的static变量来存放数据。
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.
后续提一个PR来修复这个问题。
ir::Expr func_body; | ||
}; | ||
|
||
using FusibleOp = std::variant<ReduceOp, TrivialOp>; |
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.
这些定义与前端是割裂的。
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.
后续会处理一下,将表达同构
* implement FuseFilteredStmtPatterns * update * split trivial op into a single file. * fix compiler complaints * rename StmtIter to StmtPtr * declare group_pattern.InferShardableAxes * refine signature of group_pattern.InferShardableAxes * move group_pattern.InferShardableAxes to group_pattern_util.InferShardableAxes * implement group_pattern_util.InferShardableAxes * add group_pattern_util.InferShardableAxesFromSink * ReversedInferShardableAxes support sinks * update op lower * support multiple sinks in group_pattern_util.InferShardableAxes * update * fix link error * update * remove FusionOp to OpList * update * update * update * update * declare group_pattern_util.h * fix compiler complains * declare group_pattern_util.ClusteringHelper * refine signature of group_pattern_util.ClusterIntoGroupPatternsFromOpList * update op lowr * add todo * minor refine by group_pattern_util.OpSet * update * update * update (PaddlePaddle#57) * update * update * Cinn trivalop fuse (PaddlePaddle#58) * fix * refactor StmtFusionHelper by OpTopo * Complete: CreateReduceExpr function. * update * recursive done. * update * Cinn trivalop fuse (PaddlePaddle#59) * clean all the TODO. * update * fix cluster * remove unused OpTopo.downstream_disconnected_ops * Cinn trivalop fuse (PaddlePaddle#60) * fix compile rror * update * Cinn trivalop fuse (PaddlePaddle#61) * add R + T skeleon * add search utils. * update * Cinn trivalop fuse (PaddlePaddle#62) * push * update * fix * fix transformer * fix * Implement iterator vars fetching in ReduceOp * small fix * add GetOuterIterVars API * fix * fix compile complain * modify GetOutputIters of TrivialOp * remove dumplicate code in visit * implement ClusterIntoGroupPatternsFromOpList * Fix most error in trivial_op.cc. * CreateReduceExpr is OK! * fix * add CheckIterEq * implement group_pattern_util.ClusteringEngine and groupp_pattern_util.ClusteringPolicy * SinkTrivialTransform OK! * update * fix init_tensor name problem. * update * fix compiler complains * refactor ShardableAxesSignature by group_pattern.SoleOutputShardableAxes * split trivial_op.cc * update * implement group_pattern_util.MakeShardableAxesSignature4ReduceOp * update * implement group_pattern_util.MakeEmptyShardableAxesSignature * add helper class group_pattern_util.ShardableAxesProvider * implement group_pattern_util.MakeShardableAxesSignature4BroadcastOp * update * update * fix softmax error.! * fix * update * merge * fix * Implement new OpMergeWithOp and add a relevant flag * update * update * fix reduce_load error. add splitReduceTransform * fix conflict * update * update * update * disable horizontal fusion * fix * Add some VLOG * Fix group cluster bug (PaddlePaddle#71) * fix * fix dyshape * fix * init split cluster files * update * update * update * spliting * update * spliting * spliting * pattern utils * update * update * clean cmake * update * update * update * fix clustering_engine * fix fusion_helper * update * fix * update * update * update * update * fix * fix some erros * update * update * fix split with num problem * update * fix * fix static issues * fix * init split cluster files (PaddlePaddle#72) * update * update * update * update * update * update * update * update * update * split shardable axes provider (PaddlePaddle#73) * update * update * fix broadcast (PaddlePaddle#75) * update * update * fix * fix code format * fix code format * remove unittest * update * update (PaddlePaddle#77) * update * update * update --------- Co-authored-by: tc20042008 <156998525+tc20042008@users.noreply.github.com> Co-authored-by: feifei-111 <2364819892@qq.com> Co-authored-by: jiahy0825 <jiahongyu@baidu.com> Co-authored-by: zhangbaizhou <zhangbaizhou@baidu.com> Co-authored-by: Baizhou Zhang <eddiezhang@pku.edu.cn>
PR types
Others
PR changes
Others
Description
Cinn trivalop fuse.
PCard-74042