-
Notifications
You must be signed in to change notification settings - Fork 200
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
[Hot Cold Splitting] Fix R2RDump to support dumping hot-cold parts together #1908
Comments
All code reference in the comment comes from my private branch here. Note that the branch is updated from time to time, make sure you are referring to the latest one. FunctionalityWhen you look at the R2RDump for CoreLab, you will see this info:
That means there are two methods: Then we look further down and found this:
First of all, we knew that the hot runtime function 0 at Second, we would like to be able to see all runtime functions of a method together. The block for This concludes, from the functionality point of view, what we needed. DesignThe entry point for the R2RDump tool is here. You can use the same technique as in here to make it possible to debug R2RDump. The method Inside Potential solutionTo begin with, we need to have the Scratch map handy. One way of doing it is to keep it in a form that is easy to query, such as a dictionary from the hot runtime function index to the associated cold runtime function indices (Maybe a range?). Here is some example code showing how we can obtain the scratch map data in raw form. Then when we run Then we compute the lengths (in terms of number of runtime functions) for the hot block and the cold block. After computing the values, we need to store them somewhere. Right now, a The If you have implemented the functionality correctly, you should find yourselves only need to change these files:
|
Right now, R2RDump will dump all the cold blocks as part of the last hot function, that is just wrong.
The text was updated successfully, but these errors were encountered: