-
Notifications
You must be signed in to change notification settings - Fork 5.9k
[CINN]add convert to unpack mha pass #65142
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]add convert to unpack mha pass #65142
Conversation
|
你的PR提交成功,感谢你对开源项目的贡献! |
| auto& shape_analysis = | ||
| pir::ShapeAnalysisManager::Instance().Get(op->GetParentProgram()); | ||
|
|
||
| auto in_shape = |
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.
const auto&
不要用直接用auto,会引发潜在的拷贝开销。
| auto in_shape = | ||
| shape_analysis.GetShapeOrDataForValue(op->operand_source(0)); | ||
|
|
||
| auto dim1 = in_shape.shape()[1]; |
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.
int64_t,不要养成用auto的习惯。
| auto q = op->operand_source(0); | ||
| auto k = op->operand_source(1); | ||
| auto v = op->operand_source(2); |
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.
pir::Value
不要养成用auto的习惯。
|
Sorry to inform you that e424c62's CIs have passed for more than 7 days. To prevent PR conflicts, you need to re-run all CIs manually. |
… test_llama_infer_mha_pass
… test_llama_infer_mha_pass
PR Category
CINN
PR Types
Others
Description
pcard-76996
添加fa 到unpack mha的变换pass
同时升级 unplack mha kenrel,支持batch的输入