github-actions[bot] commented on code in PR #27784:
URL: https://github.com/apache/doris/pull/27784#discussion_r1410154813


##########
be/src/vec/columns/column_vector.cpp:
##########
@@ -202,6 +202,41 @@ void ColumnVector<T>::update_crcs_with_value(uint32_t* 
__restrict hashes, Primit
     }
 }
 
+template <typename T>
+void ColumnVector<T>::update_murmurs_with_value(uint32_t* __restrict hashes, 
PrimitiveType type,

Review Comment:
   warning: function 'update_murmurs_with_value' has cognitive complexity of 53 
(threshold 50) [readability-function-cognitive-complexity]
   ```cpp
   void ColumnVector<T>::update_murmurs_with_value(uint32_t* __restrict hashes, 
PrimitiveType type,
                         ^
   ```
   <details>
   <summary>Additional context</summary>
   
   **be/src/vec/columns/column_vector.cpp:211:** +1, including nesting penalty 
of 0, nesting level increased to 1
   ```cpp
       if constexpr (!std::is_same_v<T, Int64>) {
       ^
   ```
   **be/src/vec/columns/column_vector.cpp:212:** +2, including nesting penalty 
of 1, nesting level increased to 2
   ```cpp
           DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL(HashUtil::SPARK_MURMUR_32_SEED)
           ^
   ```
   **be/src/vec/columns/column.h:74:** expanded from macro 
'DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL'
   ```cpp
       if (null_data == nullptr) {                                              
     \
       ^
   ```
   **be/src/vec/columns/column_vector.cpp:212:** +3, including nesting penalty 
of 2, nesting level increased to 3
   ```cpp
           DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL(HashUtil::SPARK_MURMUR_32_SEED)
           ^
   ```
   **be/src/vec/columns/column.h:75:** expanded from macro 
'DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL'
   ```cpp
           for (size_t i = 0; i < s; i++) {                                     
     \
           ^
   ```
   **be/src/vec/columns/column_vector.cpp:212:** +1, nesting level increased to 
2
   ```cpp
           DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL(HashUtil::SPARK_MURMUR_32_SEED)
           ^
   ```
   **be/src/vec/columns/column.h:78:** expanded from macro 
'DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL'
   ```cpp
       } else {                                                                 
     \
         ^
   ```
   **be/src/vec/columns/column_vector.cpp:212:** +3, including nesting penalty 
of 2, nesting level increased to 3
   ```cpp
           DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL(HashUtil::SPARK_MURMUR_32_SEED)
           ^
   ```
   **be/src/vec/columns/column.h:79:** expanded from macro 
'DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL'
   ```cpp
           for (size_t i = 0; i < s; i++) {                                     
     \
           ^
   ```
   **be/src/vec/columns/column_vector.cpp:212:** +4, including nesting penalty 
of 3, nesting level increased to 4
   ```cpp
           DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL(HashUtil::SPARK_MURMUR_32_SEED)
           ^
   ```
   **be/src/vec/columns/column.h:80:** expanded from macro 
'DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL'
   ```cpp
               if (null_data[i] == 0) {                                         
     \
               ^
   ```
   **be/src/vec/columns/column_vector.cpp:213:** +1, nesting level increased to 
1
   ```cpp
       } else {
         ^
   ```
   **be/src/vec/columns/column_vector.cpp:214:** +2, including nesting penalty 
of 1, nesting level increased to 2
   ```cpp
           if (type == TYPE_DATE || type == TYPE_DATETIME) {
           ^
   ```
   **be/src/vec/columns/column_vector.cpp:214:** +1
   ```cpp
           if (type == TYPE_DATE || type == TYPE_DATETIME) {
                                 ^
   ```
   **be/src/vec/columns/column_vector.cpp:216:** nesting level increased to 3
   ```cpp
               auto date_convert_do_crc = [&](size_t i) {
                                          ^
   ```
   **be/src/vec/columns/column_vector.cpp:222:** +3, including nesting penalty 
of 2, nesting level increased to 3
   ```cpp
               if (null_data == nullptr) {
               ^
   ```
   **be/src/vec/columns/column_vector.cpp:223:** +4, including nesting penalty 
of 3, nesting level increased to 4
   ```cpp
                   for (size_t i = 0; i < s; i++) {
                   ^
   ```
   **be/src/vec/columns/column_vector.cpp:226:** +1, nesting level increased to 
3
   ```cpp
               } else {
                 ^
   ```
   **be/src/vec/columns/column_vector.cpp:227:** +4, including nesting penalty 
of 3, nesting level increased to 4
   ```cpp
                   for (size_t i = 0; i < s; i++) {
                   ^
   ```
   **be/src/vec/columns/column_vector.cpp:228:** +5, including nesting penalty 
of 4, nesting level increased to 5
   ```cpp
                       if (null_data[i] == 0) {
                       ^
   ```
   **be/src/vec/columns/column_vector.cpp:233:** +1, nesting level increased to 
2
   ```cpp
           } else {
             ^
   ```
   **be/src/vec/columns/column_vector.cpp:234:** +3, including nesting penalty 
of 2, nesting level increased to 3
   ```cpp
               
DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL(HashUtil::SPARK_MURMUR_32_SEED)
               ^
   ```
   **be/src/vec/columns/column.h:74:** expanded from macro 
'DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL'
   ```cpp
       if (null_data == nullptr) {                                              
     \
       ^
   ```
   **be/src/vec/columns/column_vector.cpp:234:** +4, including nesting penalty 
of 3, nesting level increased to 4
   ```cpp
               
DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL(HashUtil::SPARK_MURMUR_32_SEED)
               ^
   ```
   **be/src/vec/columns/column.h:75:** expanded from macro 
'DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL'
   ```cpp
           for (size_t i = 0; i < s; i++) {                                     
     \
           ^
   ```
   **be/src/vec/columns/column_vector.cpp:234:** +1, nesting level increased to 
3
   ```cpp
               
DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL(HashUtil::SPARK_MURMUR_32_SEED)
               ^
   ```
   **be/src/vec/columns/column.h:78:** expanded from macro 
'DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL'
   ```cpp
       } else {                                                                 
     \
         ^
   ```
   **be/src/vec/columns/column_vector.cpp:234:** +4, including nesting penalty 
of 3, nesting level increased to 4
   ```cpp
               
DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL(HashUtil::SPARK_MURMUR_32_SEED)
               ^
   ```
   **be/src/vec/columns/column.h:79:** expanded from macro 
'DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL'
   ```cpp
           for (size_t i = 0; i < s; i++) {                                     
     \
           ^
   ```
   **be/src/vec/columns/column_vector.cpp:234:** +5, including nesting penalty 
of 4, nesting level increased to 5
   ```cpp
               
DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL(HashUtil::SPARK_MURMUR_32_SEED)
               ^
   ```
   **be/src/vec/columns/column.h:80:** expanded from macro 
'DO_MURMUR_HASHES_FUNCTION_COLUMN_IMPL'
   ```cpp
               if (null_data[i] == 0) {                                         
     \
               ^
   ```
   
   </details>
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to