You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
graph TB
A[dy2st] --> B[legacy static APi branch]
B --> C[legacy IR]
C --> D[legacy IR executor]
E[PIR dy2st] --> F[PIR static API branch]
F --> G[PIR]
G --> H[PIR executor]
C -->|ProaramTranslator| G
Loading
目标
从背景可以看出我们目前需要支持的单测有三种 IR 工作模式, 以及两种 dy2st 模式。
这样组合之后我们就能得到新机制需要运行的单测组合: 2*3=6 (如下图)
graph TB
A[SOT] --> B[legacy IR]
A --> C[PIR EXE]
A --> D[PIR API]
E[AST] --> B
E[AST] --> C
E[AST] --> D
Loading
修改
模式修改
原有机制会对ToStaticMode.PIR_AST 和 IrMode.LEGACY_IR 进行组合, 这明显不合理, 我们不可能在一个执行器中跑两套 IR 模式
所以首先对组合模式进行了修改,将ToStaticMode.PIR_AST 模式下沉至 IrMode.PIR_EXE, 这样我们就能对不同动转静模式和 IR 模式进行组合测试
PIR_EXE对应的就是走的ProaramTranslator达到运行PIR executor模式。 PIR_API对应的就是走的全 PIR 模式, 也就是我们的最终态。
你的PR提交成功,感谢你对开源项目的贡献!
请关注后续CI自动化测试结果,详情请参考Paddle-CI手册。
Your PR has been submitted. Thanks for your contribution!
Please wait for the result of CI firstly. See Paddle CI Manual for details.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR types
Others
PR changes
Others
Description
背景
从流程图的
dy2st
开始垂直向下为早期legacy IR
形成的动转静模式。在现阶段如果想要执行
PIR executor
需要经过一层ProaramTranslator
转写。我们的目标就是让他使用一套完整的
PIR dy2st
, 我们也称之为最终态(理想态), 也就是右侧PIR dy2st
垂直向下的部分。目标
从背景可以看出我们目前需要支持的单测有三种 IR 工作模式, 以及两种 dy2st 模式。
这样组合之后我们就能得到新机制需要运行的单测组合: 2*3=6 (如下图)
修改
原有机制会对
ToStaticMode.PIR_AST
和IrMode.LEGACY_IR
进行组合, 这明显不合理, 我们不可能在一个执行器中跑两套 IR 模式所以首先对组合模式进行了修改,将
ToStaticMode.PIR_AST
模式下沉至IrMode.PIR_EXE
, 这样我们就能对不同动转静模式和 IR 模式进行组合测试PIR_EXE
对应的就是走的ProaramTranslator
达到运行PIR executor
模式。PIR_API
对应的就是走的全 PIR 模式, 也就是我们的最终态。test_legacy_and_pir_api
和test_legacy_and_pir_api_and_pir_exe
装饰器任务列表: #58633