Skip to content
This repository has been archived by the owner on Mar 21, 2024. It is now read-only.

Fix CachingDeviceAllocator with debug=true #388

Merged
merged 1 commit into from
Oct 24, 2021

Conversation

gevtushenko
Copy link
Collaborator

@gevtushenko gevtushenko commented Oct 22, 2021

CachingDeviceAllocator::FreeAllCached accesses freed memory after this commit:

CachedBlocks::iterator begin = cached_blocks.begin();
cached_blocks.erase(begin);
if (debug) 
{ 
  print(begin); 
}

This leads to an exception on windows in test/test_allocator.cu. This PR contains a fix for this issue.

@alliepiper alliepiper assigned alliepiper and unassigned alliepiper Oct 22, 2021
@alliepiper alliepiper added type: bug: functional Does not work as intended. P1: should have Necessary, but not critical. labels Oct 22, 2021
@alliepiper alliepiper added this to the 1.15.0 milestone Oct 22, 2021
Copy link
Collaborator

@alliepiper alliepiper left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, go ahead and merge once tests are done.

@gevtushenko gevtushenko added the testing: gpuCI in progress Started gpuCI testing. label Oct 22, 2021
@gevtushenko
Copy link
Collaborator Author

DVS: 30566603

@gevtushenko gevtushenko added the testing: internal ci in progress Currently testing on internal NVIDIA CI (DVS). label Oct 22, 2021
@gevtushenko gevtushenko merged commit 0624264 into NVIDIA:main Oct 24, 2021
@gevtushenko gevtushenko added testing: gpuCI passed Passed gpuCI testing. testing: internal ci passed Passed internal NVIDIA CI (DVS). and removed testing: gpuCI in progress Started gpuCI testing. testing: internal ci in progress Currently testing on internal NVIDIA CI (DVS). labels Oct 24, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
P1: should have Necessary, but not critical. testing: gpuCI passed Passed gpuCI testing. testing: internal ci passed Passed internal NVIDIA CI (DVS). type: bug: functional Does not work as intended.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants