From f1c31305df4232a9fd24aa417be777a7c3b1d618 Mon Sep 17 00:00:00 2001 From: Austin Ho Date: Fri, 17 May 2024 03:10:40 +0000 Subject: [PATCH] #0: Clean up tt_dnn op enums --- tt_eager/tt_dnn/op_library/bcast/bcast_op.hpp | 6 ++-- tt_eager/tt_dnn/op_library/bmm/bmm_op.hpp | 19 +++++----- .../tt_dnn/op_library/concat/concat_op.hpp | 2 +- tt_eager/tt_dnn/op_library/conv/conv_op.hpp | 2 +- .../op_library/conv/optimized_conv_op.hpp | 2 +- tt_eager/tt_dnn/op_library/copy/copy_op.hpp | 2 +- .../eltwise_binary/eltwise_binary_op.hpp | 36 +++++++++---------- .../eltwise_unary/eltwise_unary_op.hpp | 10 +----- .../op_library/embeddings/embeddings_op.hpp | 4 +-- tt_eager/tt_dnn/op_library/fold/fold_op.hpp | 2 +- .../moreh_softmax/moreh_softmax_op.hpp | 18 +++++----- .../moreh_softmax_backward_op.hpp | 18 +++++----- tt_eager/tt_dnn/op_library/move/move_op.hpp | 2 +- .../tt_dnn/op_library/pool/average_pool.hpp | 2 +- .../tt_dnn/op_library/reduce/reduce_op.hpp | 6 ++-- .../tt_dnn/op_library/repeat/repeat_op.hpp | 2 +- .../rotary_embedding/rotary_embedding_op.hpp | 2 +- .../op_library/rotate_half/rotate_half_op.hpp | 2 +- tt_eager/tt_dnn/op_library/scan/scan_op.hpp | 2 +- .../tt_dnn/op_library/sharded/sharded_op.hpp | 2 +- .../sharded_partial/sharded_op_partial.hpp | 2 +- .../tt_dnn/op_library/tilize/tilize_op.hpp | 4 +-- .../op_library/transpose/transpose_op.hpp | 4 +-- tt_eager/tt_dnn/op_library/unpad/unpad_op.hpp | 2 +- .../op_library/untilize/untilize_op.hpp | 4 +-- .../update_cache/update_cache_op.hpp | 4 +-- .../op_library/upsample/upsample_op.hpp | 2 +- 27 files changed, 77 insertions(+), 86 deletions(-) diff --git a/tt_eager/tt_dnn/op_library/bcast/bcast_op.hpp b/tt_eager/tt_dnn/op_library/bcast/bcast_op.hpp index 0fb876f555e..be53c3f3f58 100644 --- a/tt_eager/tt_dnn/op_library/bcast/bcast_op.hpp +++ b/tt_eager/tt_dnn/op_library/bcast/bcast_op.hpp @@ -14,12 +14,12 @@ namespace tt { namespace tt_metal { -enum class BcastOpMath { ADD = 0, SUB = 1, MUL = 2 }; +enum class BcastOpMath { ADD, SUB, MUL }; -enum class BcastOpDim { H = 0, W = 1, HW = 2 }; +enum class BcastOpDim { H, W, HW }; // TODO: Accept parallelization -enum class BcastOpParallelizationStrategy { MULTI_CORE_H = 0, MULTI_CORE_W = 1, MULTI_CORE_HW = 2, SINGLE_CORE = 3 }; +enum class BcastOpParallelizationStrategy { MULTI_CORE_H, MULTI_CORE_W, MULTI_CORE_HW, SINGLE_CORE }; operation::ProgramWithCallbacks bcast_single_core( const Tensor &input_tensor_a, diff --git a/tt_eager/tt_dnn/op_library/bmm/bmm_op.hpp b/tt_eager/tt_dnn/op_library/bmm/bmm_op.hpp index bad8eeaddfd..2c25530f90f 100644 --- a/tt_eager/tt_dnn/op_library/bmm/bmm_op.hpp +++ b/tt_eager/tt_dnn/op_library/bmm/bmm_op.hpp @@ -15,17 +15,16 @@ namespace tt { namespace tt_metal { -// TODO: Accept parallelization enum class MatmulParallelizationStrategy { - MULTI_CORE = 0, - MULTI_CORE_REUSE = 1, - MULTI_CORE_REUSE_PADDING = 2, - MULTI_CORE_REUSE_OPTIMIZED = 3, - MULTI_CORE_REUSE_MCAST_2D_OPTIMIZED = 4, - MULTI_CORE_REUSE_MCAST_2D_TRANSPOSED_OPTIMIZED = 5, - MULTI_CORE_REUSE_MCAST_1D_IN0_OPTIMIZED = 6, - MULTI_CORE_REUSE_MCAST_1D_IN1_OPTIMIZED = 7, - SINGLE_CORE = 8 + MULTI_CORE, + MULTI_CORE_REUSE, + MULTI_CORE_REUSE_PADDING, + MULTI_CORE_REUSE_OPTIMIZED, + MULTI_CORE_REUSE_MCAST_2D_OPTIMIZED, + MULTI_CORE_REUSE_MCAST_2D_TRANSPOSED_OPTIMIZED, + MULTI_CORE_REUSE_MCAST_1D_IN0_OPTIMIZED, + MULTI_CORE_REUSE_MCAST_1D_IN1_OPTIMIZED, + SINGLE_CORE }; diff --git a/tt_eager/tt_dnn/op_library/concat/concat_op.hpp b/tt_eager/tt_dnn/op_library/concat/concat_op.hpp index 3124bb5ed1a..bd44d8d8d7d 100644 --- a/tt_eager/tt_dnn/op_library/concat/concat_op.hpp +++ b/tt_eager/tt_dnn/op_library/concat/concat_op.hpp @@ -11,7 +11,7 @@ namespace tt { namespace tt_metal { -enum class ConcatOpParallelizationStrategy { SINGLE_CORE = 0, MULTI_CORE = 1, SHARDED_MULTI_CORE = 2 }; +enum class ConcatOpParallelizationStrategy { SINGLE_CORE, MULTI_CORE, SHARDED_MULTI_CORE }; struct Concat { uint32_t dim; diff --git a/tt_eager/tt_dnn/op_library/conv/conv_op.hpp b/tt_eager/tt_dnn/op_library/conv/conv_op.hpp index 908c6f6c334..961dbbf14d4 100644 --- a/tt_eager/tt_dnn/op_library/conv/conv_op.hpp +++ b/tt_eager/tt_dnn/op_library/conv/conv_op.hpp @@ -13,7 +13,7 @@ namespace tt_metal { // TODO: Accept parallelization enum class ConvOpParallelizationStrategy { - MULTI_CORE = 0, MULTI_CORE_REUSE = 1, MULTI_CORE_REUSE_MCAST = 2, SINGLE_CORE = 3 + MULTI_CORE, MULTI_CORE_REUSE, MULTI_CORE_REUSE_MCAST, SINGLE_CORE }; struct Conv { diff --git a/tt_eager/tt_dnn/op_library/conv/optimized_conv_op.hpp b/tt_eager/tt_dnn/op_library/conv/optimized_conv_op.hpp index 9b602ebf10d..0400917b38d 100644 --- a/tt_eager/tt_dnn/op_library/conv/optimized_conv_op.hpp +++ b/tt_eager/tt_dnn/op_library/conv/optimized_conv_op.hpp @@ -14,7 +14,7 @@ namespace tt_metal { // TODO: Accept parallelization enum class OptimizedConvOpParallelizationStrategy { - MULTI_CORE = 0, MULTI_CORE_REUSE = 1, MULTI_CORE_REUSE_MCAST = 2, SINGLE_CORE = 3 + MULTI_CORE, MULTI_CORE_REUSE, MULTI_CORE_REUSE_MCAST, SINGLE_CORE }; struct OptimizedConvParallelizationConfig { diff --git a/tt_eager/tt_dnn/op_library/copy/copy_op.hpp b/tt_eager/tt_dnn/op_library/copy/copy_op.hpp index 7fd0ae54db4..92f03d19e04 100644 --- a/tt_eager/tt_dnn/op_library/copy/copy_op.hpp +++ b/tt_eager/tt_dnn/op_library/copy/copy_op.hpp @@ -19,7 +19,7 @@ namespace tt { namespace tt_metal { enum class CopyOpParallelizationStrategy { - MULTI_CORE = 0, SINGLE_CORE = 1 + MULTI_CORE, SINGLE_CORE }; struct Copy { diff --git a/tt_eager/tt_dnn/op_library/eltwise_binary/eltwise_binary_op.hpp b/tt_eager/tt_dnn/op_library/eltwise_binary/eltwise_binary_op.hpp index 68f4ee08f8f..c13a3a81670 100644 --- a/tt_eager/tt_dnn/op_library/eltwise_binary/eltwise_binary_op.hpp +++ b/tt_eager/tt_dnn/op_library/eltwise_binary/eltwise_binary_op.hpp @@ -19,26 +19,26 @@ namespace tt_metal { enum class BinaryOpType { - ADD = 0, - SUB = 1, - MUL = 2, - GT = 3, - LT = 4, - LTE = 5, - GTE = 6, - EQ = 7, - NE = 8, - SQUARED_DIFFERENCE = 9, - BIAS_GELU = 10, - LOGADDEXP = 11, - LOGICAL_AND = 12, - LOGICAL_OR = 13, - LDEXP = 14, - LOGADDEXP2 = 15, - DIV_FAST = 16 + ADD, + SUB, + MUL, + GT, + LT, + LTE, + GTE, + EQ, + NE, + SQUARED_DIFFERENCE, + BIAS_GELU, + LOGADDEXP, + LOGICAL_AND, + LOGICAL_OR, + LDEXP, + LOGADDEXP2, + DIV_FAST }; -enum class BinaryOpParallelizationStrategy { MULTI_CORE = 0, SINGLE_CORE = 1 }; +enum class BinaryOpParallelizationStrategy { MULTI_CORE, SINGLE_CORE }; operation::ProgramWithCallbacks eltwise_binary_single_core( const Tensor &a, diff --git a/tt_eager/tt_dnn/op_library/eltwise_unary/eltwise_unary_op.hpp b/tt_eager/tt_dnn/op_library/eltwise_unary/eltwise_unary_op.hpp index f0ff9b15d30..80563193d13 100644 --- a/tt_eager/tt_dnn/op_library/eltwise_unary/eltwise_unary_op.hpp +++ b/tt_eager/tt_dnn/op_library/eltwise_unary/eltwise_unary_op.hpp @@ -68,10 +68,6 @@ enum class UnaryOpType { SILU, IDENTITY, NEG, - ADD_UNARY, - SUB_UNARY, - MUL_UNARY, - DIV_UNARY, ADD_UNARY_SFPU, SUB_UNARY_SFPU, MUL_UNARY_SFPU, @@ -99,10 +95,6 @@ bool is_parametrized_type(T val) { case UnaryOpType::RSUB: case UnaryOpType::RDIV: case UnaryOpType::EXP: - case UnaryOpType::ADD_UNARY: - case UnaryOpType::SUB_UNARY: - case UnaryOpType::MUL_UNARY: - case UnaryOpType::DIV_UNARY: case UnaryOpType::ADD_UNARY_SFPU: case UnaryOpType::SUB_UNARY_SFPU: case UnaryOpType::MUL_UNARY_SFPU: @@ -165,7 +157,7 @@ inline UnaryWithParam string_to_unary_with_param(const std::string& name) { TT_THROW("Unknown unary op: " + name); } -enum class UnaryOpParallelizationStrategy { SINGLE_CORE = 0, MULTI_CORE = 1, SHARDED_MULTI_CORE = 2 }; +enum class UnaryOpParallelizationStrategy { SINGLE_CORE, MULTI_CORE, SHARDED_MULTI_CORE }; struct EltwiseUnary { const std::vector op_chain; diff --git a/tt_eager/tt_dnn/op_library/embeddings/embeddings_op.hpp b/tt_eager/tt_dnn/op_library/embeddings/embeddings_op.hpp index f18f663c0d4..f9bfb4c3a06 100644 --- a/tt_eager/tt_dnn/op_library/embeddings/embeddings_op.hpp +++ b/tt_eager/tt_dnn/op_library/embeddings/embeddings_op.hpp @@ -15,8 +15,8 @@ namespace tt { namespace tt_metal { -enum class EmbeddingsType { GENERIC = 0, PADDED = 1, BINARY = 2 }; -enum class EmbeddingsIndexType { UINT32 = 0, BFP16 = 1}; +enum class EmbeddingsType { GENERIC, PADDED, BINARY }; +enum class EmbeddingsIndexType { UINT32, BFP16}; struct Embeddings { const MemoryConfig output_mem_config; diff --git a/tt_eager/tt_dnn/op_library/fold/fold_op.hpp b/tt_eager/tt_dnn/op_library/fold/fold_op.hpp index 94e97cf110c..7459345da76 100644 --- a/tt_eager/tt_dnn/op_library/fold/fold_op.hpp +++ b/tt_eager/tt_dnn/op_library/fold/fold_op.hpp @@ -11,7 +11,7 @@ namespace tt::tt_metal { -enum class FoldOpParallelizationStrategy { SINGLE_CORE = 0, SHARDED_MULTI_CORE = 1 }; +enum class FoldOpParallelizationStrategy { SINGLE_CORE, SHARDED_MULTI_CORE }; struct Fold { uint8_t stride_h; diff --git a/tt_eager/tt_dnn/op_library/moreh_softmax/moreh_softmax_op.hpp b/tt_eager/tt_dnn/op_library/moreh_softmax/moreh_softmax_op.hpp index 74d818ed1c2..2cadce0e39e 100644 --- a/tt_eager/tt_dnn/op_library/moreh_softmax/moreh_softmax_op.hpp +++ b/tt_eager/tt_dnn/op_library/moreh_softmax/moreh_softmax_op.hpp @@ -18,18 +18,18 @@ namespace primary { using namespace tt_metal; enum class MorehSoftmaxOpParallelizationStrategy { - NONE = 0, - SMALL_W = 1, - SMALL_H = 2, - LARGE_W = 3, - LARGE_H = 4, - LARGE_C = 5, + NONE, + SMALL_W, + SMALL_H, + LARGE_W, + LARGE_H, + LARGE_C, }; enum class MorehSoftmaxOp { - SOFTMAX = 0, - SOFTMIN = 1, - LOGSOFTMAX = 2, + SOFTMAX, + SOFTMIN, + LOGSOFTMAX, }; bool is_moreh_softmax_w_small_available(const Tensor &tensor); diff --git a/tt_eager/tt_dnn/op_library/moreh_softmax_backward/moreh_softmax_backward_op.hpp b/tt_eager/tt_dnn/op_library/moreh_softmax_backward/moreh_softmax_backward_op.hpp index f82f77eac15..7c61dea7e11 100644 --- a/tt_eager/tt_dnn/op_library/moreh_softmax_backward/moreh_softmax_backward_op.hpp +++ b/tt_eager/tt_dnn/op_library/moreh_softmax_backward/moreh_softmax_backward_op.hpp @@ -17,18 +17,18 @@ namespace primary { using namespace tt_metal; enum class MorehSoftmaxBackwardOpParallelizationStrategy { - NONE = 0, - SMALL_W = 1, - SMALL_H = 2, - LARGE_W = 3, - LARGE_H = 4, - LARGE_C = 5 + NONE, + SMALL_W, + SMALL_H, + LARGE_W, + LARGE_H, + LARGE_C }; enum class MorehSoftmaxBackwardOp { - SOFTMAX = 0, - SOFTMIN = 1, - LOGSOFTMAX = 2, + SOFTMAX, + SOFTMIN, + LOGSOFTMAX, }; bool is_moreh_softmax_backward_w_small_available(const Tensor &tensor); diff --git a/tt_eager/tt_dnn/op_library/move/move_op.hpp b/tt_eager/tt_dnn/op_library/move/move_op.hpp index fbff9de5c5c..7c02c1d0718 100644 --- a/tt_eager/tt_dnn/op_library/move/move_op.hpp +++ b/tt_eager/tt_dnn/op_library/move/move_op.hpp @@ -26,7 +26,7 @@ namespace tt { namespace tt_metal { enum class MoveOpParallelizationStrategy { - MULTI_CORE = 0, SINGLE_CORE = 1, MULTI_CORE_OVERLAP = 2, MULTI_CORE_SHARDED = 3 + MULTI_CORE, SINGLE_CORE, MULTI_CORE_OVERLAP, MULTI_CORE_SHARDED }; struct Move { diff --git a/tt_eager/tt_dnn/op_library/pool/average_pool.hpp b/tt_eager/tt_dnn/op_library/pool/average_pool.hpp index 8be426cece9..93edb8da22b 100644 --- a/tt_eager/tt_dnn/op_library/pool/average_pool.hpp +++ b/tt_eager/tt_dnn/op_library/pool/average_pool.hpp @@ -13,7 +13,7 @@ namespace tt { namespace tt_metal { enum class PoolType { - AVG = 0 + AVG }; Tensor average_pool_2d(const Tensor& input, const MemoryConfig& output_mem_config = operation::DEFAULT_OUTPUT_MEMORY_CONFIG, const std::optional& output_dtype = std::nullopt); diff --git a/tt_eager/tt_dnn/op_library/reduce/reduce_op.hpp b/tt_eager/tt_dnn/op_library/reduce/reduce_op.hpp index 3a237cd7df5..f7a49ae440e 100644 --- a/tt_eager/tt_dnn/op_library/reduce/reduce_op.hpp +++ b/tt_eager/tt_dnn/op_library/reduce/reduce_op.hpp @@ -13,15 +13,15 @@ namespace tt { namespace tt_metal { enum class ReduceOpMath { - SUM = 0, MAX = 1, MIN = 2 + SUM, MAX, MIN }; enum class ReduceOpDim { - H = 0, W = 1, HW = 2 + H, W, HW }; enum class ReduceOpParallelizationStrategy { - MULTI_CORE_H = 0, MULTI_CORE_W = 1, MULTI_CORE_HW = 2, SINGLE_CORE = 3 + MULTI_CORE_H, MULTI_CORE_W, MULTI_CORE_HW, SINGLE_CORE }; // TODO: Accept parallelization diff --git a/tt_eager/tt_dnn/op_library/repeat/repeat_op.hpp b/tt_eager/tt_dnn/op_library/repeat/repeat_op.hpp index 99b91b0edcb..16eff985ff5 100644 --- a/tt_eager/tt_dnn/op_library/repeat/repeat_op.hpp +++ b/tt_eager/tt_dnn/op_library/repeat/repeat_op.hpp @@ -11,7 +11,7 @@ namespace tt { namespace tt_metal { -enum class RepeatOpParallelizationStrategy { SINGLE_CORE = 0, MULTI_CORE = 1 }; +enum class RepeatOpParallelizationStrategy { SINGLE_CORE, MULTI_CORE }; struct Repeat { const uint32_t repeat_dim; diff --git a/tt_eager/tt_dnn/op_library/rotary_embedding/rotary_embedding_op.hpp b/tt_eager/tt_dnn/op_library/rotary_embedding/rotary_embedding_op.hpp index 8843a81aca7..5bef302ff0a 100644 --- a/tt_eager/tt_dnn/op_library/rotary_embedding/rotary_embedding_op.hpp +++ b/tt_eager/tt_dnn/op_library/rotary_embedding/rotary_embedding_op.hpp @@ -16,7 +16,7 @@ namespace tt { namespace tt_metal { -enum class RotaryEmbeddingOpParallelizationStrategy { MULTI_CORE = 0, SINGLE_CORE = 1 }; +enum class RotaryEmbeddingOpParallelizationStrategy { MULTI_CORE, SINGLE_CORE }; operation::ProgramWithCallbacks rotary_embedding_single_core( const Tensor &input, const Tensor &cos, const Tensor &sin, Tensor &output, std::optional token_idx, DeviceComputeKernelConfig compute_kernel_config); diff --git a/tt_eager/tt_dnn/op_library/rotate_half/rotate_half_op.hpp b/tt_eager/tt_dnn/op_library/rotate_half/rotate_half_op.hpp index 8250493bd71..6f7e4b2435f 100644 --- a/tt_eager/tt_dnn/op_library/rotate_half/rotate_half_op.hpp +++ b/tt_eager/tt_dnn/op_library/rotate_half/rotate_half_op.hpp @@ -16,7 +16,7 @@ namespace tt { namespace tt_metal { enum class RotateHalfOpParallelizationStrategy { - MULTI_CORE = 0, SINGLE_CORE = 1 + MULTI_CORE, SINGLE_CORE }; operation::ProgramWithCallbacks rotate_half_single_core(const Tensor &input_tensor, Tensor &output_tensor); diff --git a/tt_eager/tt_dnn/op_library/scan/scan_op.hpp b/tt_eager/tt_dnn/op_library/scan/scan_op.hpp index 655a4cb7c64..cd1b99970e5 100644 --- a/tt_eager/tt_dnn/op_library/scan/scan_op.hpp +++ b/tt_eager/tt_dnn/op_library/scan/scan_op.hpp @@ -11,7 +11,7 @@ namespace tt::tt_metal { -enum class ScanOpParallelizationStrategy { SHARDED_MULTI_CORE = 0 }; +enum class ScanOpParallelizationStrategy { SHARDED_MULTI_CORE }; enum class ScanOpDirection { ROWS, COLS, ROWS_REVERSED, COLS_REVERSED }; diff --git a/tt_eager/tt_dnn/op_library/sharded/sharded_op.hpp b/tt_eager/tt_dnn/op_library/sharded/sharded_op.hpp index cedb2ac34fc..766c46c5f73 100644 --- a/tt_eager/tt_dnn/op_library/sharded/sharded_op.hpp +++ b/tt_eager/tt_dnn/op_library/sharded/sharded_op.hpp @@ -15,7 +15,7 @@ namespace tt { namespace tt_metal { -enum class ShardedOpParallelizationStrategy { MULTI_CORE = 0 }; +enum class ShardedOpParallelizationStrategy { MULTI_CORE }; enum class ShardedOpType { InterleavedToSharded, ShardedToInterleaved }; diff --git a/tt_eager/tt_dnn/op_library/sharded_partial/sharded_op_partial.hpp b/tt_eager/tt_dnn/op_library/sharded_partial/sharded_op_partial.hpp index 0143fc61858..60a7f001704 100644 --- a/tt_eager/tt_dnn/op_library/sharded_partial/sharded_op_partial.hpp +++ b/tt_eager/tt_dnn/op_library/sharded_partial/sharded_op_partial.hpp @@ -17,7 +17,7 @@ namespace tt { namespace tt_metal { -enum class ShardedOpPartialParallelizationStrategy { MULTI_CORE = 0 }; +enum class ShardedOpPartialParallelizationStrategy { MULTI_CORE }; enum class ShardedOpPartialType { InterleavedToShardedPartial, ShardedToInterleavedPartial }; diff --git a/tt_eager/tt_dnn/op_library/tilize/tilize_op.hpp b/tt_eager/tt_dnn/op_library/tilize/tilize_op.hpp index 7ac9f827ee1..f8a3733a8e1 100644 --- a/tt_eager/tt_dnn/op_library/tilize/tilize_op.hpp +++ b/tt_eager/tt_dnn/op_library/tilize/tilize_op.hpp @@ -11,7 +11,7 @@ namespace tt { namespace tt_metal { -enum class TilizeOpParallelizationStrategy { MULTI_CORE = 0, SINGLE_CORE = 1 }; +enum class TilizeOpParallelizationStrategy { MULTI_CORE, SINGLE_CORE }; struct Tilize { const MemoryConfig output_mem_config; @@ -32,7 +32,7 @@ struct Tilize { } }; -enum class TilizeWithValPaddingOpParallelizationStrategy { MULTI_CORE = 0, SINGLE_CORE = 1 }; +enum class TilizeWithValPaddingOpParallelizationStrategy { MULTI_CORE, SINGLE_CORE }; struct TilizeWithValPadding { const Shape output_tensor_shape; diff --git a/tt_eager/tt_dnn/op_library/transpose/transpose_op.hpp b/tt_eager/tt_dnn/op_library/transpose/transpose_op.hpp index 78d124d152a..f07cbc9c52e 100644 --- a/tt_eager/tt_dnn/op_library/transpose/transpose_op.hpp +++ b/tt_eager/tt_dnn/op_library/transpose/transpose_op.hpp @@ -12,11 +12,11 @@ namespace tt { namespace tt_metal { enum class TransposeOpDim { - WH = 0, HC = 1, CN = 2, NH = 3, NW = 4, CW = 5 + WH, HC, CN, NH, NW, CW }; enum class TransposeOpParallelizationStrategy { - MULTI_CORE_WH = 0, MULTI_CORE_HC = 1, MULTI_CORE_CN = 2, SINGLE_CORE = 3 + MULTI_CORE_WH, MULTI_CORE_HC, MULTI_CORE_CN, SINGLE_CORE }; struct Transpose { diff --git a/tt_eager/tt_dnn/op_library/unpad/unpad_op.hpp b/tt_eager/tt_dnn/op_library/unpad/unpad_op.hpp index b1b8d8f379b..4a1de5200b3 100644 --- a/tt_eager/tt_dnn/op_library/unpad/unpad_op.hpp +++ b/tt_eager/tt_dnn/op_library/unpad/unpad_op.hpp @@ -13,7 +13,7 @@ namespace tt { namespace tt_metal { enum class UnpadOpParallelizationStrategy { - MULTI_CORE = 0, SINGLE_CORE = 1 + MULTI_CORE, SINGLE_CORE }; uint32_t get_tiled_start_offset(const Tensor &input_tensor, const Shape &output_tensor_start); diff --git a/tt_eager/tt_dnn/op_library/untilize/untilize_op.hpp b/tt_eager/tt_dnn/op_library/untilize/untilize_op.hpp index 4fe808e2c83..08170215b9f 100644 --- a/tt_eager/tt_dnn/op_library/untilize/untilize_op.hpp +++ b/tt_eager/tt_dnn/op_library/untilize/untilize_op.hpp @@ -15,7 +15,7 @@ namespace tt_metal { #define MAX_PACK_UNTILIZE_WIDTH 8 // pack untilize currently does not support > 8 width enum class UntilizeOpParallelizationStrategy { - MULTI_CORE = 0, SINGLE_CORE = 1 + MULTI_CORE, SINGLE_CORE }; struct Untilize { @@ -39,7 +39,7 @@ struct Untilize { }; enum class UntilizeWithUnpaddingOpParallelizationStrategy { - MULTI_CORE = 0, SINGLE_CORE = 1 + MULTI_CORE, SINGLE_CORE }; struct UntilizeWithUnpadding { diff --git a/tt_eager/tt_dnn/op_library/update_cache/update_cache_op.hpp b/tt_eager/tt_dnn/op_library/update_cache/update_cache_op.hpp index 79c4f26b77c..1bf023e2206 100644 --- a/tt_eager/tt_dnn/op_library/update_cache/update_cache_op.hpp +++ b/tt_eager/tt_dnn/op_library/update_cache/update_cache_op.hpp @@ -17,11 +17,11 @@ namespace tt { namespace tt_metal { enum class UpdateCacheOpParallelizationStrategy { - MULTI_CORE = 0, SINGLE_CORE = 1 + MULTI_CORE, SINGLE_CORE }; enum class UpdateCacheOpType { - FILL = 0, UPDATE = 1 + FILL, UPDATE }; operation::ProgramWithCallbacks update_cache_multi_core(const Tensor& cache_tensor, const Tensor &input_tensor, const uint32_t update_idx, const uint32_t batch_offset, DeviceComputeKernelConfig compute_kernel_config); diff --git a/tt_eager/tt_dnn/op_library/upsample/upsample_op.hpp b/tt_eager/tt_dnn/op_library/upsample/upsample_op.hpp index 5581cb38210..92b77cf8745 100644 --- a/tt_eager/tt_dnn/op_library/upsample/upsample_op.hpp +++ b/tt_eager/tt_dnn/op_library/upsample/upsample_op.hpp @@ -11,7 +11,7 @@ namespace tt { namespace tt_metal { enum class UpSampleParallelizationStrategy { - MULTI_CORE = 0, SINGLE_CORE = 1 + MULTI_CORE, SINGLE_CORE }; struct UpSample{