Repository navigation
Smc opt support more store - #179
Merged
luzeng87 merged 3 commits intoDec 5, 2025
Merged
Conversation
The SMC code-first optimization is enabled by default. But not all store inst are supported to be interpreted after smc. This patch supports some more store inst (stptr, fst, vxst) to be interpreted in smc strategy. To avoid abort, when the store is unsupport or sc.w/d/q, the strategy on this page will fallback to the original write-first way, which means all TB on this page will be invalidated to make this page writable and return back to execute the original store inst. A simple profiling work is performed for this fallback case. If this case occurs too much, some info will be printed to indicate futher optimization. Signed-off-by: NiuGenen <[email protected]>
The fst can not be interpreted directly since the signal context does not contains the FTOP in loongarch old world. A special glue code is used to interpret the fst inst. But it only works when the memory accress does not across host page boundary. If it across the host page boundary, fallback to original write-first strategy, which invalidates all TB on this page to make it writable and return back to the original fst inst. Since it across the host page boundary, all TB on these two host pages will be invalidated. Signed-off-by: NiuGenen <[email protected]>
avoid refering null pointer Signed-off-by: NiuGenen <[email protected]>
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
sc.w/d/q的解释执行无法保证原子性,回退到清空整个页的策略#177