ROCm / rocprofiler-sdk

https://rocm.docs.amd.com/projects/rocprofiler-sdk/en/latest/
MIT License
11 stars 6 forks source link

draft: remove failing assertions #6

Open jmellorcrummey opened 3 months ago

jmellorcrummey commented 3 months ago

we compiled the 'develop' versions of clr and hip as Ben recommended. the HIP and HSA assertions

ROCP_FATAL_IF(external_corr_ids.size() < (callback_contexts.size() + buffered_contexts.size()))

that I commented out out trip with each of external_corr_ids.size(), (callback_contexts.size(), and buffered_contexts.size() == 1. omitting them, our incomplete draft of rocprofiler-sdk support in hpctoolkit is being exercised as expected.

jrmadsen commented 3 months ago

Actually, I was mistaken. It appears this condition can arise if you are using both callback and buffer tracing of an API in the same context:

https://github.com/ROCm/rocprofiler-sdk/blob/2f3a8b05b3ab16a4ba9737830763681ddfa8a438/source/lib/rocprofiler-sdk/tracing/tracing.hpp#L177

https://github.com/ROCm/rocprofiler-sdk/blob/2f3a8b05b3ab16a4ba9737830763681ddfa8a438/source/lib/rocprofiler-sdk/tracing/tracing.hpp#L184

which ends up with one external correlation id map entry, one callback entry, and one buffer entry. Are you intentionally doing this?

jmellorcrummey commented 3 months ago

We are intentionally doing this at present. It should be allowed. That's why I think the assertion should be deleted.

For the future, we aim to switch to the external correlation id support rather than using the callback.