rmm icon indicating copy to clipboard operation
rmm copied to clipboard

`unused parameter` warnings for do_get_mem_info

Open fkallen opened this issue 2 years ago • 4 comments

The stream parameter in do_get_mem_info(stream) is unused for some memory resources, for example

https://github.com/rapidsai/rmm/blob/branch-22.06/include/rmm/mr/device/managed_memory_resource.hpp#L117

    cuda_stream_view stream) const override
  {
    std::size_t free_size{};
    std::size_t total_size{};
    RMM_CUDA_TRY(cudaMemGetInfo(&free_size, &total_size));
    return std::make_pair(free_size, total_size);
  }

This leads to compiler warnings.

fkallen avatar May 09 '22 14:05 fkallen

Can you share the warning? The parameter is unnamed in the line you linked specifically to avoid unused parameter warnings.

harrism avatar May 10 '22 03:05 harrism

I made a mistake. I don't know why I wrote cuda_memory_resource. In my program the warning is for managed memory resource and limiting resource adapter.

fkallen avatar May 10 '22 04:05 fkallen

This issue has been labeled inactive-30d due to no recent activity in the past 30 days. Please close this issue if no further response or action is needed. Otherwise, please respond with a comment indicating any updates or changes to the original issue and/or confirm this issue still needs to be addressed. This issue will be labeled inactive-90d if there is no activity in the next 60 days.

github-actions[bot] avatar Jun 10 '22 01:06 github-actions[bot]

This issue has been labeled inactive-90d due to no recent activity in the past 90 days. Please close this issue if no further response or action is needed. Otherwise, please respond with a comment indicating any updates or changes to the original issue and/or confirm this issue still needs to be addressed.

github-actions[bot] avatar Sep 08 '22 01:09 github-actions[bot]