-
Notifications
You must be signed in to change notification settings - Fork 124
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
Revisit the necessity the various control knobs in L0 adapter #1528
Comments
This will not be so simple. Those env variables are applicable to higher level than UMF memory pool (they allow to control pooling per memory-type, etc.). There has been some work to create a better abstractions for managing different memory types through a pool manager:
Unless we implement this usm pool manager in UMF (which we could do I think), I think those variables will have to stay in UR. |
I think env variables needs to be moved to single file and be added via wrapper, here is sample how it is done in compute-runtime:
Sample Declaring env variables basically means:
|
For deprecation, I would start with those that have high complexity impact, one that strives out quickly is It does conditional execution in many places, in hot submit path as well. |
That's the idea behind #1454.
Yes, but I was unsure whether this is a feature anyone cares about. It seems odd to have a memory-safety related feature behind an env variable, so my tentative plan was to redesign this so that deferred deallocations are integrated in the normal memory management flow, without introducing any overheads. Should be doable. |
Well if it is not used today by default then I question whether it is really needed and it adds heavy complexity to the code. void sycl::free(void* ptr, const context& syclContext) Frees an allocation. The memory pointed to by ptr must have been allocated using one of the USM allocation routines. syclContext must be the same context that was used to allocate the memory. The memory is freed without waiting for commands operating on it to be completed. If commands that use this memory are in-progress or are enqueued the behavior is undefined. |
As mentioned in #1454, L0 adapter uses a lot of environment variables to control its behavior. This results in the codebase having a lot of conditional execution flows, making it hard to follow at times. It also makes it difficult for the user to understand which variables need to be set for best performance on their systems.
Ideally, the number of knobs controllable through env variables would be reduced to a minimum set where there are unavoidable trade-offs related to the platform and the environment. As a first step towards that, we need to revisit the existing L0 adapter variables to see which ones can be deprecated or removed entirely.
List of existing variables:
The text was updated successfully, but these errors were encountered: