Skip to content

Commit 37dab27

Browse files
committed
fix M=1024
1 parent 3c4ab53 commit 37dab27

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

gemlite/triton_kernels/utils.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ def gpu_has_more_shared_memory(ref_gpus = ['a100', 'h100', 'h200', 'h800']):
5555

5656
#Next power of 2
5757
M_MAXVAL = 1024
58-
M_MAPPING = {M:min(2 ** int(math.ceil(math.log2(M))), M_MAXVAL) if (M > 0) else 0 for M in range(M_MAXVAL)}
58+
M_MAPPING = {M:min(2 ** int(math.ceil(math.log2(M))), M_MAXVAL) if (M > 0) else 0 for M in range(M_MAXVAL + 1)}
5959
def get_closest_m_fast_autotune(M):
6060
return M_MAPPING[M] if M <= M_MAXVAL else M_MAXVAL
6161

0 commit comments

Comments
 (0)