26 std::string offload_value_;
28 size_t min_async_bytes_;
46 std::string offload_value,
50 : lane_width_(
lane_width), offload_value_(std::move(offload_value)),
55 if (sched.
value() == offload_value_) {
92 return sched.
value() == offload_value_;
120 return implementation_type_;
124 return min_async_bytes_;
static symbolic::Integer lanes(const structured_control_flow::ScheduleType &schedule)
Lanes that jointly execute each iteration (1 = one thread per iteration; the warp size = one wave per...
Definition gpu_offload_schedule_type.h:170
static void parallel_size(structured_control_flow::ScheduleType &schedule, const symbolic::Integer parallel_size)
Set the parallel size for a schedule.
Definition gpu_offload_schedule_type.h:150
static bool nested_sync(const structured_control_flow::ScheduleType &schedule)
Check if nested synchronization is enabled.
Definition gpu_offload_schedule_type.h:203
Represents a schedule type for Map nodes.
Definition structured_loop.h:31
const std::string & value() const
Get the schedule type identifier.
Definition structured_loop.h:45
Target-neutral cooperation facts derived from one loop's schedule.
Definition tile.h:42
data_flow::ImplementationType implementation_type() const override
The implementation selector this target stamps onto its tile codegen library nodes (cp....
Definition gpu_tile_target.h:119
size_t min_async_bytes() const override
The narrowest per-lane async (CpAsync) transfer in bytes; narrower copies stay synchronous.
Definition gpu_tile_target.h:123
bool supports_cooperative_staging(const structured_control_flow::ScheduleType &sched) const override
Whether sched can host a block-cooperative shared-memory staging copy driven by its own parallel thre...
Definition gpu_tile_target.h:89
GPUTileTarget(unsigned lane_width, std::string offload_value, data_flow::ImplementationType implementation_type, size_t min_async_bytes=4)
Definition gpu_tile_target.h:44
Space space(Level level) const override
The GPU scratchpad hierarchy: Device->Global, Group->Shared, Subgroup->Register.
Definition gpu_tile_target.h:77
unsigned lane_width() const override
The SIMD lane / subgroup width, used only to keep a subgroup's cooperative stores bank-conflict-free ...
Definition gpu_tile_target.h:107
std::optional< AxisSchedule > classify(const structured_control_flow::ScheduleType &sched) const override
Classify one loop's sched into target-neutral cooperation facts (AxisSchedule: level,...
Definition gpu_tile_target.h:54
types::StorageType storage_type(Space space) const override
The concrete buffer that realizes an abstract cooperation Space on this target: e....
Definition gpu_tile_target.h:95
std::optional< tiles::BankModel > bank_model(tiles::Space space) const override
Shared memory (NVIDIA and CDNA LDS): 32 banks of 4 bytes.
Definition gpu_tile_target.h:112
Definition tile_target.h:39
bool has_scratchpad() const
Whether this target exposes any on-chip cooperative tier below global memory (a scratchpad hierarchy)...
Definition tile_target.h:61
Represents the storage location and management characteristics of data.
Definition type.h:64
static StorageType CPU_Stack()
Creates a CPU stack storage type.
Definition type.h:270
static StorageType NV_Shared()
Creates an NVIDIA shared memory storage type.
Definition type.h:308
static StorageType NV_Global()
Creates an NVIDIA global memory storage type.
Definition type.h:303
StringEnum ImplementationType
Implementation type identifier for library nodes.
Definition library_node.h:75
TargetLevel
Definition gpu_offload_schedule_type.h:13
@ Z_BLOCK
Definition gpu_offload_schedule_type.h:19
@ Y_BLOCK
Definition gpu_offload_schedule_type.h:18
@ Y_GRID
Definition gpu_offload_schedule_type.h:15
@ Z_GRID
Definition gpu_offload_schedule_type.h:16
TargetLevel gpu_target_level(const structured_control_flow::ScheduleType &schedule)
Get the GPU target level from any GPU schedule type.
Definition gpu_offload_schedule_type.h:282
bool is_grid_level(TargetLevel target_level)
symbolic::Integer gpu_block_size(const structured_control_flow::ScheduleType &schedule)
Get the block size from any GPU schedule type Returns default values if not explicitly set:
Definition gpu_schedule_type.h:129
bool is_block_level(TargetLevel target_level)
Definition gpu_tile_target.h:13
Space
Memory that backs cooperation at a level: Device/CPU -> Global (atomics/heap), Group -> Shared,...
Definition tile.h:36
@ Register
Definition tile.h:36
@ Global
Definition tile.h:36
@ Shared
Definition tile.h:36
Level
Cooperation scope of a parallel axis, coarsest to finest — target-neutral tiers (OpenCL/SYCL vocabula...
Definition tile.h:32
@ Group
Definition tile.h:32
@ Subgroup
Definition tile.h:32
@ Device
Definition tile.h:32
A banked on-chip memory: banks banks of bank_bytes each, every bank serving one word per cycle.
Definition bank_conflicts.h:16
The complete target-specific contract of the tile algebra.