Skip to content

Conversation

@Seanst98
Copy link
Contributor

@Seanst98 Seanst98 commented Apr 4, 2025

Warn users over setting the memory pool maximum size property instead of error.

This should aid CI which is affected by the memory_pool.cpp e2e test which expects to be able to set this property despite DPC++ being built with a CUDA version that is too old.

See this CI error: #17757 (comment)

This PR relies on #17095 to be merged for the printing of the warning to be enabled.

Warn users over setting the memory pool maximum size property instead
of error.

This should aid CI which is affected by the memory_pool.cpp e2e test
which expects to be able to set this property despite DPC++ being built
with a CUDA version that is too old.
@jchlanda
Copy link
Contributor

jchlanda commented Apr 7, 2025

The change looks reasonable. I wonder thought if it's a safe thing to do. What would happen if the max size is set on an unsupported arch, should the user expect their application to run correctly (if so warning is OK, otherwise a better approach would be to address the CI issue)?

@Seanst98
Copy link
Contributor Author

Seanst98 commented Apr 7, 2025

The change looks reasonable. I wonder thought if it's a safe thing to do. What would happen if the max size is set on an unsupported arch, should the user expect their application to run correctly (if so warning is OK, otherwise a better approach would be to address the CI issue)?

In those cases, CUDA will set the maximum size "to a system dependent value" (See here). Effectively, this will be a very high limit, and my guess is that in all cases this system value will be greater than whatever the application may want to set. Whether their application runs correctly depends on if it absolutely relies on having a maximum size that is smaller than this system dependent value. However, I think the warning would be sufficient in that case.

@Seanst98
Copy link
Contributor Author

Seanst98 commented Apr 7, 2025

Since the failure that this PR addresses in CI is holding up the PR, #17095, which this relies on for printing to be enabled, we can merge this now to quickly address the failure in CI. When #17095 is merged, the warnings will be printed.

@intel/llvm-gatekeepers can we merge this please? Thanks!

@kbenzie kbenzie merged commit 64c60c5 into intel:sycl Apr 7, 2025
44 of 46 checks passed
@Seanst98 Seanst98 deleted the sean/async-alloc-warn-maxsize branch April 7, 2025 14:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants