tqchen commented on PR #15058: URL: https://github.com/apache/tvm/pull/15058#issuecomment-1589467004
Thanks @srkreddy1238 . Reading the set of changes, i feel that we need something that is more lifted out from the DeviceAPI since this is getting closer to the two stage concept. - Allocator allocates physical Storage object (in this case backed by clBuffer) - The storage object then allocates the NDArray(backed by the storage object). We already have some of similar concept in [memory manager](https://github.com/apache/tvm/blob/unity/include/tvm/runtime/relax_vm/memory_manager.h), e.g. in relax, but of course the memory manager as it is does not yet reflect the need of supporting things like creating different memory scope. This would help to move some of the complexity in the texture part to a specialized allocator that creates the Storage with related behavior. The main rationale is to keep the overall DeviceAPI minimum without behavior of things like pooling and move some of the logic to Storage, NDArray separation, that can hopefully also enable direct support in VM backed runtimes like unity. Maybe we can discuss a bit on how to make that part more generalized that can be reused. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
