Skip to content

Commit

Permalink
50cents readibility improvement to allocgroups on GPU schedules.
Browse files Browse the repository at this point in the history
  • Loading branch information
mcourteaux committed Oct 6, 2023
1 parent 24a64f8 commit 92339f2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/FuseGPUThreadLoops.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -802,14 +802,14 @@ class ExtractSharedAndHeapAllocations : public IRMutator {
Type widest_type;
for (const auto &alloc : cluster) {
if (name.empty()) {
name = alloc.name;
name = "allocgroup";
widest_type = alloc.widest_type;
} else {
name += "__" + alloc.name;
if (alloc.widest_type.bytes() > widest_type.bytes()) {
widest_type = alloc.widest_type;
}
}
name += "__" + alloc.name;
int ratio = alloc.widest_type.bytes() / alloc_type.bytes();
internal_assert(ratio != 0)
<< "alloc_type should have been at most as wide as the widest type in group\n";
Expand Down

0 comments on commit 92339f2

Please sign in to comment.