Changes: 25.05#
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
--spy
has 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_CONFIG
member on task declarations.As part of this new feature, the old-style
TASK_ID
member 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_ID
member 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_ID
is detected. Calling theregister_variants()
overload which accepts either alegate::TaskConfig
orlegate::LocalTaskID
will not emit an error.
Data
Add support for
std::vector<bool>
tolegate::Scalar
.Add an optional
target
parameter tolegate::LogicalArray::get_physical_array()
andlegate::LogicalStore::get_physical_store()
. Thetarget
controls where the physical array/store is allocated.Add
legate::InlineAllocation::target
member 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::Scope
to a separate group (tuning
) in documentation.legate/runtime/scope.h
is nowlegate/tuning/scope.h
.Add
legate::ParallelPolicy
to describe parallelization policies for a scope.legate::ParallelPolicy
objects 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
target
parameter tolegate.core.LogicalArray.get_physical_array()
andlegate.core.LogicalStore.get_physical_store()
. Thetarget
controls where the physical array/store is allocated.Add
legate.core.InlineAllocation.target
property 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.VariantOptions
to 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.library
to retrieve theLibrary
that a task was registered with.Add
legate.core.TaskConfig
.Change
legate.core.task.task()
arguments. Replacethrows_exception
andthrows_exception
withoptions
, which is either alegate.core.TaskConfig
orlegate.core.VariantOptions
.Change
legate.core.task.PyTask.__init__()
. Replacethrows_exception
andthrows_exception
withoptions
, which is either alegate.core.TaskConfig
orlegate.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.Scope
to a separate group (tuning
) in documentation.Add
legate.core.ParallelPolicy
to describe parallelization policies for a scope.legate.core.ParallelPolicy
objects can be used withlegate.core.Scope
.
Types
Runtime
Add
legate.core.ResourceConfig
to specify library resource configuration parameters.Add
legate.core.Runtime.find_or_create_library()
to search for, or createLibrary
instances.Add
legate.core.Library.name
to access the name of the library.
Utilities
I/O