Change fromDLPackCapsule params memory access to ALL
Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).
View this failed invocation of the CLA check for more information.
For the most up to date status, view the checks section at the bottom of the pull request.
ahh think I found it: https://github.com/iree-org/iree/blob/9fe159d99d86f3292ae901427a159fb61898fa2c/runtime/src/iree/hal/allocator_heap.c#L269-L273
that's not quite right as here it takes the ALL which includes DISCARD and uses that to map... which then discards the existing contents as it was told to :P
I believe that should mask with allowed_access & (IREE_HAL_MEMORY_ACCESS_READ | IREE_HAL_MEMORY_ACCESS_WRITE). If you try that the change you made here should then work. I think this was only working previously because passing ANY just ignores validation and the DISCARD bit isn't set there so existing contents were not discarded.
Do we still want this PR, or can we close it and delete the branch?
Ended up landing in #20092.