Conversation
|
@gasche I would like this to go into 4.06. Without it you cannot use spacetime. |
|
We would need a proper review for this, which I can't give myself. (I don't understand what this change for people that do not use spacetime, which is necessary to assess the riskyness of the change.) On the negative side:
|
Yeah. I think Mark is back from vacation tomorrow, so we should be able to get a review soon. I just wanted to make sure you were aware of this PR.
Possibly some of it can be shared, but of course cpp macros aren't the easiest things to create abstractions with.
What was broken was any spacetime viewer compiled with 4.05. A spacetime viewer compiled with 4.04 could still read profiles made by programs compiled with 4.05. However, 4.06 adds to the spacetime profile format (see #1180), so a 4.04 viewer will not be able to read profiles created with 4.06 -- indeed no viewer will.
That doesn't really seem necessary. It's only a small bug in that PR, and I think ocp-memprof is using the functionality. |
|
(The CIs are failing right now.) |
|
The new variable |
3f3883a to
c1ac02a
Compare
damiendoligez
left a comment
There was a problem hiding this comment.
It looks strange to me that you are defining a configure variable that cannot be changed by the user (or anything else, for that matter). It's just a constant!
This very much looks like a cross-compilation problem and not strongly tied to spacetime: any other profiling tool will encounter the same difficulty, right?
That's the simplest way I could see to allow the value of that constant (
It's a kind of cross-compilation problem. Certainly any profiling tool needs to distinguish between the code for profiling the current program and the code for reading profiles. Unfortunately someone changed a part that was being shared between those two bits of code (ignoring a comment right next to it saying that it was shared). |
|
A possibly cleaner approach would be for profiles themsleves to include the |
e9eea75 to
6cff315
Compare
|
I'd like to see the cleaner approach. We can afford a few days. |
943cb6c to
a4ab20c
Compare
|
Ok I've written a version that's half-way to what I described as the "cleaner approach". It no longer tries to define the "spacetime_profinfo_width" in configure, I was doing that to try and define it in a single place but with the windows Makefiles it was already spread across 5 places anyway. Instead #define SPACETIME_PROFINFO_WIDTH 26In the future we could put the width into the profile itself and pass it from there through to the functions in To take account of Gabriel's comment I've also defined versions of |
|
@damiendoligez What do you think of the new version? |
damiendoligez
left a comment
There was a problem hiding this comment.
Looks quite good. Much better than the first version.
|
Merged and cherry-picked onto 4.06 (ef8844f) |
#735 broke
raw_spacetime_libwhen the compiler is not configured with spacetime -- which prevents the spacetime viewer from being used without profiling itself. This PR fixes the issue by providing aSpacetime_profinfo_hdmacro that is the same asProfinfo_hdexcept that it works when spacetime is not enabled.