Skip to content

Commit 5031657

Browse files
authored
[LLVMGPU] Fix coding standards / style issues in config utils (#22454)
Honestly, too many issues to list in the PR description. Not an NFC because some things like the wrong accumulator type in `std::reduce` might be actual bugs that we haven't hit yet. ci-extra: windows_x64_msvc
1 parent 1a47465 commit 5031657

File tree

2 files changed

+114
-122
lines changed

2 files changed

+114
-122
lines changed

compiler/src/iree/compiler/Codegen/Common/GPU/GPUHeuristics.h

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,11 @@ struct GPUIntrinsicType : public GPUMatmulShapeType {
5454
/// Struct containing seed tile sizes for GPU MMA heuristics deduction logic.
5555
struct GPUMMAHeuristicSeeds {
5656
// The best number of subgroups to use per workgroup
57-
int64_t bestSubgroupCountPerWorkgroup;
57+
int64_t bestSubgroupCountPerWorkgroup = 0;
5858
// The best number of total tiles along M*N dimensions per subgroup
59-
int64_t bestMNTileCountPerSubgroup;
59+
int64_t bestMNTileCountPerSubgroup = 0;
6060
// The best number of tiles along K dimension per subgroup
61-
int64_t bestKTileCountPerSubgroup;
61+
int64_t bestKTileCountPerSubgroup = 0;
6262
// The best number of elements along K dimension per subgroup. This is
6363
// equivalent to `bestKTileCountPerSubgroup * bestIntrinsic.kSize`, for
6464
// some chosen intrinsic `bestIntrinsic`.
@@ -68,9 +68,12 @@ struct GPUMMAHeuristicSeeds {
6868
struct GPUMMASchedule {
6969
// The MMA intrinsic kind to use for this schedule.
7070
IREE::Codegen::InnerTileDescAttrInterface mmaKind;
71-
int64_t mSize; // Native MMA intrinsic size along M dimension for a subgroup.
72-
int64_t nSize; // Native MMA intrinsic size along N dimension for a subgroup.
73-
int64_t kSize; // Native MMA intrinsic size along K dimension for a subgroup.
71+
// Native MMA intrinsic size along M dimension for a subgroup.
72+
int64_t mSize = 0;
73+
// Native MMA intrinsic size along N dimension for a subgroup.
74+
int64_t nSize = 0;
75+
// Native MMA intrinsic size along K dimension for a subgroup.
76+
int64_t kSize = 0;
7477

7578
// Number of subgroups along each M and N dimension.
7679
SmallVector<int64_t> mSubgroupCounts;

0 commit comments

Comments
 (0)