Skip to content

Commit 51655d7

Browse files
committed
[refactor] update variable declaration for clarity in gemm_layouts and gemm_sp
1 parent fecadc8 commit 51655d7

File tree

2 files changed

+1
-3
lines changed

2 files changed

+1
-3
lines changed

src/layout/gemm_layouts.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -672,7 +672,7 @@ Layout makeTensorOpMultiplicand(int mat_stride, int mat_continuous,
672672
kElementsPerAccess +
673673
FloorMod(j, kElementsPerAccess);
674674

675-
PrimExpr element_strided = vec_strided_idx;
675+
const PrimExpr &element_strided = vec_strided_idx;
676676

677677
const int stride = mat_continuous;
678678

src/op/gemm_sp.cc

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,14 +40,12 @@ std::pair<int, int> GemmSPWarpPolicyNode::ComputeWarpPartition(int M, int N,
4040
int warp_shape_n = N / n_warp;
4141
if (warp_shape_m % m_atom_size) { // GemmWarpPolicy::kFullRow
4242
m_warp = M / m_atom_size;
43-
warp_shape_m = m_atom_size;
4443
ICHECK(m_warp > 0) << err_msg;
4544
n_warp = num_warps / m_warp;
4645
warp_shape_n = N / n_warp;
4746
ICHECK(warp_shape_n % n_atom_size == 0) << err_msg;
4847
} else if (warp_shape_n % n_atom_size != 0) { // GemmWarpPolicy::kFullColumn
4948
n_warp = N / n_atom_size;
50-
warp_shape_n = n_atom_size;
5149
ICHECK(n_warp > 0) << err_msg;
5250
m_warp = num_warps / n_warp;
5351
warp_shape_m = M / m_warp;

0 commit comments

Comments
 (0)