[llvm] r216808 - Object/llvm-objdump: allow dumping of mach-o exports trie

Nick Kledzik kledzik at apple.com
Tue Sep 2 12:01:50 PDT 2014


On Sep 2, 2014, at 6:45 AM, Rafael EspĂ­ndola <rafael.espindola at gmail.com> wrote:

>>     enum {
>> +      EXPORT_SYMBOL_FLAGS_KIND_MASK           = 0x03u,
>>       EXPORT_SYMBOL_FLAGS_WEAK_DEFINITION     = 0x04u,
>>       EXPORT_SYMBOL_FLAGS_REEXPORT            = 0x08u,
>>       EXPORT_SYMBOL_FLAGS_STUB_AND_RESOLVER   = 0x10u
>>     };
>> 
>>     enum ExportSymbolKind {
>> -      EXPORT_SYMBOL_FLAGS_KIND_MASK           = 0x03u,
>>       EXPORT_SYMBOL_FLAGS_KIND_REGULAR        = 0x00u,
>>       EXPORT_SYMBOL_FLAGS_KIND_THREAD_LOCAL   = 0x01u,
>>       EXPORT_SYMBOL_FLAGS_KIND_ABSOLUTE       = 0x02u
> 
> On the previous commit you did exactly the opposite move with
> EXPORT_SYMBOL_FLAGS_KIND_MASK :-)
Yes,  At first I thought it made sense to keep the mask with the bits, but the original way works better.

The items below are fixed in r216931.  Thanks!

-Nick


> 
>> +uint64_t ExportEntry::readULEB128(const uint8_t *&p) {
> 
> P
> 
>> +  unsigned count;
> 
> Count
> 
>> +  uint64_t result = decodeULEB128(p, &count);
> 
> Result.
> 
> 
>> +      char c = *Top.Current;
> 
> C
> 
>> +      bool needComma = false;
> 
> NeedComma (mayb NeedsComma?
> 
>> +      int ordinal = entry.other() - 1;
> 
> Ordinal.
> 
>> +      Obj->getLibraryShortNameByIndex(ordinal, DylibName);
>> +      if (entry.otherName().empty())
> 
> Entry.
> 
> Cheers,
> Rafael





More information about the llvm-commits mailing list