| 
    SMAUG
    
   Simulating Machine Learning Applications on gem5-Aladdin 
   | 
 
  
Definition at line 11 of file smv_tiling_base.h.
Static Protected Member Functions | |
| static TilingDims | findBestTilingDims (const TensorShape &shape, int maxTileSize, const std::vector< int > &minShape) | 
| Find the best set of dimensions to tile a given tensor shape.  More... | |
| static void | enum2DTensorTilingConfigs (TensorShape shape, int maxTileSize, const std::vector< int > &minShape, const std::vector< int > &strides, std::vector< TensorShape > &configs) | 
| Enumerates all tiling configs for a two dimensional Tensor.  More... | |
| static void | enum4DTensorTilingConfigs (TensorShape shape, int maxTileSize, const std::vector< int > &minShape, const std::vector< int > &strides, std::vector< TensorShape > &configs) | 
| Enumerates all tiling configs for a four dimensional Tensor.  More... | |
      
  | 
  staticprotected | 
Enumerates all tiling configs for a two dimensional Tensor.
| shape | Tensor shape. | 
| maxTileSize | Maximum elements per tile. | 
| minShape | Minimum per-tile shape | 
| strides | Stride lengths along the N and C channels. | 
| configs | Output list of tiling configurations. | 
Definition at line 56 of file smv_tiling_base.cpp.
      
  | 
  staticprotected | 
Enumerates all tiling configs for a four dimensional Tensor.
| shape | Tensor shape. | 
| maxTileSize | Maximum elements per tile. | 
| minShape | Minimum per-tile shape | 
| strides | Stride lengths along the N and C channels. | 
| configs | Output list of tiling configurations. | 
Definition at line 78 of file smv_tiling_base.cpp.
      
  | 
  staticprotected | 
Find the best set of dimensions to tile a given tensor shape.
The goal is to divide up a tensor into tiles that each are <= maxTileSize elements. The tensor layouts can be NC, NHWC or NCHW. The minimum tile size is specified via minShape. The preferences for tiling dimensions are as follows:
1) No tiling. 2) Dim-N tiling. N is the input batch. 3) Dim-NC tiling. After tiling by N, tile channelwise. Do not tile in HW. 4) Dim-NH tiling. After tiling by N, tile rowwise. Do not tile in WC. 5) Dim-NW tiling. After tiling by N, tile columnwise. Do not tile in HC. 6) Dim-NHW tiling. After tiling by N, tile rowwise and then columnwise. Do not tile in C. 7) Dim-NCH tiling. After tiling by N and channel dimensions, tile rowwise. Do not tile in W. 8) Dim-NCW tiling. After tiling by N and channel dimensions, tile columnwise. Do not tile in H.
Except Option 1, a minimum size for each dimension can be deduced from minShape. Note that for a 2D tensor shape, only options 1-5 are viable.
Definition at line 10 of file smv_tiling_base.cpp.
 1.8.18