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
你的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
the old start_compile api can not consider, fix it and speed up
说明:
使用原 opcode 的前半段替换 resume_fn 中的 compile_fn,在这种情况下会将原 opcode 的后半段放在构造好的 resume_fn 的末尾 (这是为了防止出现意外跳转的保险措施,尽管这种跳转应该不可能出现)
处理 NullVariable。必须要保证 origin code (resume_fn 本身也应该是 origin code)load NullVariable,而 new code load 真正的 null。原本只有 fallback 才会执行 origin code,现在 break 也有可能了,所以需要对返回的 new_code 进行一次处理(但是构造 resume fn还是需要 NullVariable)
break 之后被 skip
假如有 func 触发了 break,构造了 new_func_code 其中 call resume_0 ,且 resume_0 没有子图。如果触发了 resume_0 的eval_frame,就会导致错误(执行 resume_0 的origin code时,其中有一个 load NullVariable)。
但是 new_func_code 既然走了本 PR 的分支,那么 resume_0 没有子图等价于 new_func_code 没有子图,它也不会执行 new_func_code,而是执行func 的 origin code,也就不会 call resume_0,最终这里的 NullVariable 也不会导致错误
PCard-66972