Skip to content
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

Reserve allocation should be displayed when erroring due to lack of memory on startup #11282

Merged
merged 4 commits into from
Nov 4, 2024

Conversation

kuhushukla
Copy link
Collaborator

@kuhushukla kuhushukla commented Jul 31, 2024

Fixes #11168
I think using

s"${RapidsConf.RMM_ALLOC_RESERVE}: ${reserveAmount} => " +

is the right decision here but I would like for someone to correct or confirm.
I don't have a test for this. Can look into it if preferred for the review.

s"the minimum allocation of ${toMB(minAllocation)} (calculated from " +
s"${RapidsConf.RMM_ALLOC_MIN_FRACTION} (=${conf.rmmAllocMinFraction}) " +
s"and ${toMB(info.total)} MB total memory)")
s"${toMB(poolAllocation)} MiB (gpu.free: ${toMB(info.free)}," +
Copy link
Collaborator

Choose a reason for hiding this comment

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

should we rename toMB to toMiB (nit pick)

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I noticed but left it out to be conservative. Will update

s"${RapidsConf.RMM_ALLOC_FRACTION}: (=${conf.rmmAllocFraction}," +
s"${RapidsConf.RMM_ALLOC_RESERVE}: ${reserveAmount} => " +
s"(gpu.free - reserve) * allocFraction = ${toMB(poolAllocation)})" +
s"was less than allocation of ${toMB(minAllocation)} MiB (gpu.total: " +
Copy link
Collaborator

Choose a reason for hiding this comment

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

I think we can bring this message into two: the part before "was less than" and the part after. That way we can reuse it in the second case (it is almost verbatim except for this text, as far as I can tell).

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

agree

@kuhushukla
Copy link
Collaborator Author

@abellina I think this is pretty close, whenever you have a chance to take a look. Thank u!

@kuhushukla
Copy link
Collaborator Author

build

@abellina abellina changed the base branch from branch-24.10 to branch-24.12 October 9, 2024 13:29
s"less than allocation of ${toMiB(minAllocation)} MiB (gpu.total: " +
s"${toMiB(info.total)} MiB, ${RapidsConf.RMM_ALLOC_MIN_FRACTION}: " +
s"${conf.rmmAllocMinFraction} => gpu.total *" +
s"minAllocFraction = ${toMiB(minAllocation)} MiB). Please ensure that the GPU has" +
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
s"minAllocFraction = ${toMiB(minAllocation)} MiB). Please ensure that the GPU has" +
s"minAllocFraction = ${toMiB(minAllocation)} MiB). Please ensure that the GPU has " +

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

addressed

Copy link
Collaborator

@abellina abellina left a comment

Choose a reason for hiding this comment

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

Some missed spaces at the end of strings, but otherwise LGTM

revans2
revans2 previously approved these changes Oct 10, 2024
@sameerz sameerz added the bug Something isn't working label Oct 13, 2024
…emory on startup

Signed-off-by: Kuhu Shukla <kuhus@nvidia.com>
Signed-off-by: Kuhu Shukla <kuhus@nvidia.com>
Signed-off-by: Kuhu Shukla <kuhus@nvidia.com>
@kuhushukla
Copy link
Collaborator Author

build

@kuhushukla kuhushukla merged commit 4a1baa5 into NVIDIA:branch-24.12 Nov 4, 2024
46 of 47 checks passed
@kuhushukla kuhushukla deleted the issue_11168 branch November 4, 2024 15:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] reserve allocation should be displayed when erroring due to lack of memory on startup
4 participants