Changes: 25.07#
General
LEGATE_NEED_*environment variables are no longer consulted to infer what build-time features (e.g. CUDA support or networking support) are required for the current run. Legate can infer this automatically.Legate now expects to always initialize Legion during
legate::start(). If Legion is already initialized at this stage, an exception is thrown.Drop support for Python 3.10 and add support for Python 3.13.
Command line option
--spyhas been removed. The Legion spy tool is not at the right level of abstraction for end-users.
C++#
General
Add ability for users to statically declare task-wide configuration options, such as the task’s signature, constraints, and default variant options via a new
static const legate::TaskConfig TASK_CONFIGmember on task declarations.As part of this new feature, the old-style
TASK_IDmember is no longer read. Since this would otherwise be a silent breaking change, we have elected to emit a static assertion (i.e. a compiler error) in case the old-styleTASK_IDmember is found. This static assertion is only emitted in places where dynamically passing the task ID is not possible. Specifically, if the user calls the following routines:legate::LegateTask::register_variants(std::map<VariantCode, VariantOptions>)legate::LegateTask::register_variants(legate::Library, const std::map<legate::VariantCode, legate::VariantOptions>&)
Then an error will be emitted if
TASK_IDis detected. Calling theregister_variants()overload which accepts either alegate::TaskConfigorlegate::LocalTaskIDwill not emit an error.
Data
Add support for
std::vector<bool>tolegate::Scalar.Add an optional
targetparameter tolegate::LogicalArray::get_physical_array()andlegate::LogicalStore::get_physical_store(). Thetargetcontrols where the physical array/store is allocated.Add
legate::InlineAllocation::targetmember to signify which kind of memory the inline allocation holds.Add
legate::TaskLocalBuffer, a type-and-dimension-erased buffer object for use within tasks.
Mapping
Remove
legate::mapping::InstanceMappingPolicy::subsumes. This function would compare the requested layouts between two policies, to decide if an Instance allocated for one Store could be reused for another. After recent changes, two Instances created for the same requested layout can have different actual layouts, depending on the transformations of the corresponding Stores. Remove this function to avoid any confusion.
Partitioning
Tasks
Add
legate::TaskConfig.Add
legate::LegateTask::register_variants()overload which accepts alegate::TaskConfig.
Tuning
Move
legate::Scopeto a separate group (tuning) in documentation.legate/runtime/scope.his nowlegate/tuning/scope.h.Add
legate::ParallelPolicyto describe parallelization policies for a scope.legate::ParallelPolicyobjects can be used withlegate::Scope.
Types
Runtime
Utilities
Add
legate::Span::rbegin()andlegate::Span::rend()to allow reverse iteration.Add
legate::Span::front()andlegate::Span::back()to allow accessing the first and last element.
I/O
Python#
General
Data
Add an optional
targetparameter tolegate.core.LogicalArray.get_physical_array()andlegate.core.LogicalStore.get_physical_store(). Thetargetcontrols where the physical array/store is allocated.Add
legate.core.InlineAllocation.targetproperty to retrieve the type of memory held by the allocation.Add support for the PEP-3118 buffer protocol to
legate.core.InlineAllocation.Add
legate.core.PhysicalStore.create_output_buffer().Add
legate.core.PhysicalStore.bind_data().
Mapping
Partitioning
Tasks
Add
legate.core.VariantOptionsto allow describing per-variant configuration options.Add
legate.core.TaskContext.is_single_task().Add
legate.core.TaskContext.task_index.Add
legate.core.TaskContext.launch_domain.Add
legate.core.TaskContext.machine.Add
legate.core.TaskContext.provenance.Add
legate.core.TaskContext.task_stream.Add
legate.core.task.PyTask.libraryto retrieve theLibrarythat a task was registered with.Add
legate.core.TaskConfig.Change
legate.core.task.task()arguments. Replacethrows_exceptionandthrows_exceptionwithoptions, which is either alegate.core.TaskConfigorlegate.core.VariantOptions.Change
legate.core.task.PyTask.__init__(). Replacethrows_exceptionandthrows_exceptionwithoptions, which is either alegate.core.TaskConfigorlegate.core.VariantOptions.Remove
legate.core.task.PyTask.UNREGISTERED_ID.Add support for unbound stores in Python tasks.
Add
legate.core.TaskLocalBuffer.
Tuning
Move
legate.core.Scopeto a separate group (tuning) in documentation.Add
legate.core.ParallelPolicyto describe parallelization policies for a scope.legate.core.ParallelPolicyobjects can be used withlegate.core.Scope.
Types
Runtime
Add
legate.core.ResourceConfigto specify library resource configuration parameters.Add
legate.core.Runtime.find_or_create_library()to search for, or createLibraryinstances.Add
legate.core.Library.nameto access the name of the library.
Utilities
I/O