FLOPs for a single matmul C[M,N] = A[M,K] @ B[K,N].
(M: int, N: int, K: int)
| 53 | |
| 54 | |
| 55 | def _matmul_flops(M: int, N: int, K: int) -> int: |
| 56 | """FLOPs for a single matmul C[M,N] = A[M,K] @ B[K,N].""" |
| 57 | return 2 * M * N * K |
| 58 | |
| 59 | |
| 60 | def _benchmark_fn(fn, *args, warmup: int = _WARMUP_ITERS, iters: int = _BENCH_ITERS): |
no outgoing calls
no test coverage detected