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


##########
be/src/vec/common/memcmp_small.h:
##########
@@ -76,7 +78,7 @@
 template <typename Char>
 int memcmp_small_allow_overflow15(const Char* a, const Char* b, size_t size) {
     for (size_t offset = 0; offset < size; offset += 16) {
-        uint16_t mask = _mm_movemask_epi8(
+        uint16_t mask = (uint16_t)_mm_movemask_epi8(

Review Comment:
   warning: use auto when initializing with a cast to avoid duplicating the 
type name [modernize-use-auto]
   
   ```suggestion
           auto mask = (uint16_t)_mm_movemask_epi8(
   ```
   



##########
be/src/vec/common/memcmp_small.h:
##########
@@ -53,7 +55,7 @@ int memcmp_small_allow_overflow15(const Char* a, size_t 
a_size, const Char* b, s
     size_t min_size = std::min(a_size, b_size);
 
     for (size_t offset = 0; offset < min_size; offset += 16) {
-        uint16_t mask = _mm_movemask_epi8(
+        uint16_t mask = (uint16_t)_mm_movemask_epi8(

Review Comment:
   warning: use auto when initializing with a cast to avoid duplicating the 
type name [modernize-use-auto]
   
   ```suggestion
           auto mask = (uint16_t)_mm_movemask_epi8(
   ```
   



##########
be/src/vec/common/memcmp_small.h:
##########
@@ -100,7 +102,7 @@
     if (a_size != b_size) return false;
 
     for (size_t offset = 0; offset < a_size; offset += 16) {
-        uint16_t mask = _mm_movemask_epi8(
+        uint16_t mask = (uint16_t)_mm_movemask_epi8(

Review Comment:
   warning: use auto when initializing with a cast to avoid duplicating the 
type name [modernize-use-auto]
   
   ```suggestion
           auto mask = (uint16_t)_mm_movemask_epi8(
   ```
   



##########
be/src/vec/common/memcmp_small.h:
##########
@@ -119,7 +121,7 @@
 template <typename Char>
 int memcmp_small_multiple_of16(const Char* a, const Char* b, size_t size) {
     for (size_t offset = 0; offset < size; offset += 16) {
-        uint16_t mask = _mm_movemask_epi8(
+        uint16_t mask = (uint16_t)_mm_movemask_epi8(

Review Comment:
   warning: use auto when initializing with a cast to avoid duplicating the 
type name [modernize-use-auto]
   
   ```suggestion
           auto mask = (uint16_t)_mm_movemask_epi8(
   ```
   



##########
be/src/vec/common/memcmp_small.h:
##########
@@ -163,7 +165,7 @@
     const __m128i zero16 = _mm_setzero_si128();
 
     for (size_t offset = 0; offset < size; offset += 16) {
-        uint16_t mask = _mm_movemask_epi8(
+        uint16_t mask = (uint16_t)_mm_movemask_epi8(

Review Comment:
   warning: use auto when initializing with a cast to avoid duplicating the 
type name [modernize-use-auto]
   
   ```suggestion
           auto mask = (uint16_t)_mm_movemask_epi8(
   ```
   



##########
be/src/vec/common/memcmp_small.h:
##########
@@ -137,9 +139,9 @@
   */
 template <typename Char>
 int memcmp16(const Char* a, const Char* b) {
-    uint16_t mask =
-            
_mm_movemask_epi8(_mm_cmpeq_epi8(_mm_loadu_si128(reinterpret_cast<const 
__m128i*>(a)),
-                                             
_mm_loadu_si128(reinterpret_cast<const __m128i*>(b))));
+    uint16_t mask = (uint16_t)_mm_movemask_epi8(

Review Comment:
   warning: use auto when initializing with a cast to avoid duplicating the 
type name [modernize-use-auto]
   
   ```suggestion
       auto mask = (uint16_t)_mm_movemask_epi8(
   ```
   



-- 
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