File tree Expand file tree Collapse file tree 1 file changed +2
-0
lines changed Expand file tree Collapse file tree 1 file changed +2
-0
lines changed Original file line number Diff line number Diff line change @@ -75,6 +75,7 @@ DeviceGlobalMapEntry::getOrAllocateDeviceGlobalUSM(queue_impl &QueueImpl) {
7575 assert (NewAllocIt.second &&
7676 " USM allocation for device and context already happened." );
7777 DeviceGlobalUSMMem &NewAlloc = NewAllocIt.first ->second ;
78+ NewAlloc.MAllocatingContext = CtxImpl.shared_from_this ();
7879
7980 // Initialize here and save the event.
8081 {
@@ -132,6 +133,7 @@ DeviceGlobalMapEntry::getOrAllocateDeviceGlobalUSM(const context &Context) {
132133 assert (NewAllocIt.second &&
133134 " USM allocation for device and context already happened." );
134135 DeviceGlobalUSMMem &NewAlloc = NewAllocIt.first ->second ;
136+ NewAlloc.MAllocatingContext = CtxImpl.shared_from_this ();
135137
136138 if (MDeviceGlobalPtr) {
137139 // C++ guarantees members appear in memory in the order they are declared,
You can’t perform that action at this time.
0 commit comments