[Lldb-commits] [PATCH] D14507: Make sure we use symbol flags to detect thumbness.

Tamas Berghammer via lldb-commits lldb-commits at lists.llvm.org
Tue Nov 10 02:10:00 PST 2015


tberghammer requested changes to this revision.

================
Comment at: source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp:2191-2213
@@ -2170,25 +2190,25 @@
 
             if (arch.GetMachine() == llvm::Triple::arm)
             {
                 if (symbol_type == eSymbolTypeCode)
                 {
                     if (symbol.st_value & 1)
                     {
                         // Subtracting 1 from the address effectively unsets
                         // the low order bit, which results in the address
                         // actually pointing to the beginning of the symbol.
                         // This delta will be used below in conjunction with
                         // symbol.st_value to produce the final symbol_value
                         // that we store in the symtab.
                         symbol_value_offset = -1;
                         additional_flags = ARM_ELF_SYM_IS_THUMB;
                         m_address_class_map[symbol.st_value^1] = eAddressClassCodeAlternateISA;
                     }
                     else
                     {
                         // This address is ARM
                         m_address_class_map[symbol.st_value] = eAddressClassCode;
                     }
                 }
             }
 
----------------
The function you are looking for is already implemented here (in the way Greg suggested). If it isn't working in your case then you should try to figure out why it isn't working in the way it is intended.


http://reviews.llvm.org/D14507





More information about the lldb-commits mailing list