[Lldb-commits] [lldb] 115b189 - [lldb][ARC] Fix -Wtautological-bitwise-compare warning

Fangrui Song via lldb-commits lldb-commits at lists.llvm.org
Sat Aug 13 00:18:46 PDT 2022


Author: Fangrui Song
Date: 2022-08-13T00:18:37-07:00
New Revision: 115b1899a114285981814a641587e9704c2b9eb9

URL: https://github.com/llvm/llvm-project/commit/115b1899a114285981814a641587e9704c2b9eb9
DIFF: https://github.com/llvm/llvm-project/commit/115b1899a114285981814a641587e9704c2b9eb9.diff

LOG: [lldb][ARC] Fix -Wtautological-bitwise-compare warning

Added: 
    

Modified: 
    lldb/source/Plugins/ABI/ARC/ABISysV_arc.cpp

Removed: 
    


################################################################################
diff  --git a/lldb/source/Plugins/ABI/ARC/ABISysV_arc.cpp b/lldb/source/Plugins/ABI/ARC/ABISysV_arc.cpp
index a9c7af145338e..f202d581dd5f9 100644
--- a/lldb/source/Plugins/ABI/ARC/ABISysV_arc.cpp
+++ b/lldb/source/Plugins/ABI/ARC/ABISysV_arc.cpp
@@ -151,7 +151,7 @@ bool ABISysV_arc::IsRegisterFileReduced(RegisterContext &reg_ctx) const {
                                                           /*fail_value*/ 0);
     // RF_BUILD "Number of Entries" bit.
     const uint32_t rf_entries_bit = 1U << 9U;
-    m_is_reg_file_reduced = (reg_value | rf_entries_bit) != 0;
+    m_is_reg_file_reduced = (reg_value & rf_entries_bit) != 0;
   }
 
   return m_is_reg_file_reduced.value_or(false);


        


More information about the lldb-commits mailing list