- 
                Notifications
    You must be signed in to change notification settings 
- Fork 248
[CK_TILE] B matrix 2D block scale gemm #3074
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
          
     Open
      
      
            samremes
  wants to merge
  23
  commits into
  develop
  
    
      
        
          
  
    
      Choose a base branch
      
     
    
      
        
      
      
        
          
          
        
        
          
            
              
              
              
  
           
        
        
          
            
              
              
           
        
       
     
  
        
          
            
          
            
          
        
       
    
      
from
samremes/bmatrix_2d_blockscale
  
      
      
   
  
    
  
  
  
 
  
      
    base: develop
Could not load branches
            
              
  
    Branch not found: {{ refName }}
  
            
                
      Loading
              
            Could not load tags
            
            
              Nothing to show
            
              
  
            
                
      Loading
              
            Are you sure you want to change the base?
            Some commits from the old base branch may be removed from the timeline,
            and old review comments may become outdated.
          
          
      
        
          +311
        
        
          −219
        
        
          
        
      
    
  
  
     Open
                    Changes from all commits
      Commits
    
    
            Show all changes
          
          
            23 commits
          
        
        Select commit
          Hold shift + click to select a range
      
      8bb5255
              
                Refactor quant group size to be configurable for M/N/K, not just K
              
              
                samremes 98365f5
              
                add some asserts for configurations not implemented
              
              
                samremes f6b07dc
              
                start setting of group size for N dimension
              
              
                samremes 22362f2
              
                enable 2d for reference quant gemm
              
              
                samremes 9988a46
              
                WIP: trying to figure out tile dstr and/or indexing for scale matrix
              
              
                samremes 36b88c6
              
                WIP
              
              
                samremes bb52cd9
              
                Fix handling of n dim blocks in tile windows etc
              
              
                samremes f179a8a
              
                remove commented code and enable all tests again
              
              
                samremes d100ab6
              
                fix formatting
              
              
                samremes 37738e4
              
                Add more specialized tile distributions
              
              
                samremes 98deefa
              
                Enable NWarps replication for bquant tile dstr
              
              
                samremes 2d86cd0
              
                fix formatting
              
              
                samremes 470d6e4
              
                Merge remote-tracking branch 'origin/develop' into samremes/bmatrix_2…
              
              
                samremes 1f13003
              
                fix format
              
              
                samremes a449728
              
                Merge remote-tracking branch 'origin/develop' into samremes/bmatrix_2…
              
              
                samremes e12ab56
              
                Fix some issues from the merge
              
              
                samremes 7c93551
              
                fix formatting
              
              
                samremes e1475d4
              
                one more fix to tile dstr, and revert debug initialization
              
              
                samremes 5e0a356
              
                Remove commented code
              
              
                samremes 1290b1b
              
                simplify conditions that are needed for tile distributions
              
              
                samremes 306e25a
              
                only enable the working group sizes in tests
              
              
                samremes 68e41da
              
                fix formatting
              
              
                samremes bcccafe
              
                Update tile distribution for 2D bquant
              
              
                CongMa13 File filter
Filter by extension
Conversations
          Failed to load comments.   
        
        
          
      Loading
        
  Jump to
        
          Jump to file
        
      
      
          Failed to load files.   
        
        
          
      Loading
        
  Diff view
Diff view
There are no files selected for viewing
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              | Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|  | @@ -10,7 +10,7 @@ namespace ck_tile { | |||||
|  | ||||||
| // A is block window on shared memory | ||||||
| // BQ (scale tensor) is block distributed tensor. | ||||||
| // Consecutive kQuantGroupSize elements of B are quantized with a separate scale. | ||||||
| // Consecutive QuantGroupSize elements of B are quantized with a separate scale. | ||||||
| // B is block window on block distributed tensor. | ||||||
| // C is block distributed tensor | ||||||
| template <typename Problem_, typename BlockPolicy_> | ||||||
|  | @@ -24,6 +24,10 @@ struct BlockGemmWeightPreshuffleBQuantARegBRegCReg | |||||
| using CDataType = remove_cvref_t<typename Problem::CDataType>; | ||||||
| using ComputeDataType = remove_cvref_t<typename Problem::ComputeDataType>; | ||||||
| using BlockGemmShape = remove_cvref_t<typename Problem::BlockGemmShape>; // TileFlatmmShape | ||||||
| using QuantGroupSize = remove_cvref_t<typename Problem::QuantGroupSize>; | ||||||
|  | ||||||
| static_assert(QuantGroupSize::kM == 1, "only N/K blocks for BQuant preshuffle kernel!"); | ||||||
| static_assert(QuantGroupSize::kN == 1, "no block for N supported yet!"); | ||||||
| 
     | ||||||
| static_assert(QuantGroupSize::kN == 1, "no block for N supported yet!"); | |
| // static_assert(QuantGroupSize::kN == 1, "no block for N supported yet!"); | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
      
      Oops, something went wrong.
        
    
  
  Add this suggestion to a batch that can be applied as a single commit.
  This suggestion is invalid because no changes were made to the code.
  Suggestions cannot be applied while the pull request is closed.
  Suggestions cannot be applied while viewing a subset of changes.
  Only one suggestion per line can be applied in a batch.
  Add this suggestion to a batch that can be applied as a single commit.
  Applying suggestions on deleted lines is not supported.
  You must change the existing code in this line in order to create a valid suggestion.
  Outdated suggestions cannot be applied.
  This suggestion has been applied or marked resolved.
  Suggestions cannot be applied from pending reviews.
  Suggestions cannot be applied on multi-line comments.
  Suggestions cannot be applied while the pull request is queued to merge.
  Suggestion cannot be applied right now. Please check back later.
  
    
  
    
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could we make the Quant Group Size as an interface? Currently, we need to manually put the quant dim size.