@@ -52,8 +52,9 @@ using ElementOutput = float;
5252
5353using ProblemShape = Shape<int , int , int , int >;
5454
55- #if 1
55+ #if 0
5656using TileShape = Shape<_256, _256, _32>;
57+ //using TileShape = Shape<_128, _128, _32>;
5758//using TileShape = Shape<_128, _256, _32>;
5859using TiledMma =
5960 typename TiledMMAHelper<MMA_Atom<XE_8x16x16_F32BF16BF16F32_TT>, Layout<TileShape>,
@@ -90,7 +91,7 @@ static constexpr auto SG_QNT_WIDTH = Int<SG_N>{};
9091static constexpr uint32_t MaxThreadsPerBlock = size(TiledMma{}); // 8*4*1*16=512 //1*2*1*16=32
9192
9293// Define Mainloop dispatch policy
93- constexpr int PipelineStages = 2 ;
94+ constexpr int PipelineStages = 4 ;
9495using DispatchPolicy = cutlass::gemm::MainloopIntelPVCMixedPrecision<PipelineStages>;
9596static constexpr int SubgroupSize = DispatchPolicy::SubgroupSize; // 16
9697
@@ -129,7 +130,8 @@ using ClusterShape = typename DispatchPolicy::ClusterShape;
129130using CopyThreadShape = Shape<_1, Int<SubgroupSize>>;
130131using CopyThreadShapeRev = decltype (cute::reverse(CopyThreadShape{}));
131132
132- using GmemTiledCopyA = XE_2D_U16x32x32_LD_N; // XE_2D_U16x16x32_LD_N;
133+ // using GmemTiledCopyA = XE_2D_U16x32x32_LD_N;
134+ using GmemTiledCopyA = XE_2D_U16x16x32_LD_N;
133135using StrideA = cutlass::gemm::TagToStrideA_t<cutlass::layout::RowMajor>;
134136using traits_load_A = Copy_Traits<GmemTiledCopyA, StrideA>;
135137using atom_load_A = Copy_Atom<traits_load_A, ElementA>;
@@ -367,7 +369,7 @@ class gemm_4bit_cutlass_kernel {
367369 }();
368370
369371#if 0
370- if (thread_idx==0 && n_coord == 0 && l_coord==0) {
372+ if (cute::thread0()){ // thread_idx==0 && n_coord == 0 && l_coord==0) {
371373 print("\n\n======================= A: \n");
372374 print(" gA : "); print(gA); print("\n");
373375 print(" tCgA : "); print(tCgA); print("\n");
@@ -428,7 +430,6 @@ class gemm_4bit_cutlass_kernel {
428430 }
429431
430432 for (int k_tile = k_start_idx, k_s = 0 ; k_tile < k_tile_count + k_start_idx; k_tile++, prefetch_k++, k_s++) {
431-
432433 copy (tiled_copy_a, tAgA (_,_,_,k_tile), frag_copy_A);
433434 copy (tiled_copy_b, tBgB (_,_,_,k_tile), frag_copy_B);
434435
@@ -457,7 +458,7 @@ class gemm_4bit_cutlass_kernel {
457458 tiled_mma,
458459 thread_idx
459460 );
460- }
461+ }
461462};
462463
463464template <typename T, int BITS >
0 commit comments