cuda.core 1.3.0 Release Notes#
New features#
Added the read-only
ManagedBuffer.last_prefetch_locationproperty, which reports the destination requested by the most recent explicit prefetch across the buffer. It returns aDeviceorHost, including NUMA-specific host locations on CUDA 13, andNoneif any page has never been prefetched or the pages do not share one last-prefetch location. This reports the requested target, not current residency or completion of the asynchronous prefetch operation. (#2109)
Fixes and enhancements#
Devicemethods that create resources or synchronize now act on that device’s bound context, even when another device is current. They do not change which device is current. For example,dev1.sync()synchronizes device 1’s bound context even when device 0 is current, and no longer touches other contexts on device 1 (such as a green context).Device.set_current()now always returns aContextwith the correct device ID; passing a context created on a different device than the receiver now delegates to that device’s ownset_current()instead of raising, so a context this method returns can always be pushed back through anyDeviceobject. (#2311)Stream.wait()given a stream now works when that stream belongs to a device that is not current. The temporary ordering event is created in the waited-on stream’s context rather than the current one, whichcuEventRecordrejects when the two differ. The stream ordering applied when importing foreign arrays and tensors uses the producer stream’s context the same way. (#2311)LegacyPinnedMemoryResource.device_idnow returns-1, as documented for memory that is not bound to a device and asPinnedMemoryResourcealready does, instead of raisingRuntimeError.Buffer.device_idon such a buffer returns-1as well, which also lets a pinned buffer back a linear or pitched texture resource.