[PATCH] D88717: [obj2yaml] [yaml2obj] Add yaml support for SHT_LLVM_BB_ADDR_MAP section.
    Rahman Lavaee via Phabricator via llvm-commits 
    llvm-commits at lists.llvm.org
       
    Tue Nov  3 13:02:03 PST 2020
    
    
  
rahmanl marked an inline comment as done.
rahmanl added inline comments.
================
Comment at: llvm/tools/obj2yaml/elf2yaml.cpp:800
+
+  if (Content.empty() || !Cur) {
+    // If the section cannot be decoded, we dump it as an array of bytes.
----------------
jhenderson wrote:
> In the `empty()` case, I think it would be great to not specify `Content` or `Entries`, so that you end up with a section like this:
> ```
> Name: .llvm_bb_addr_map
> Type: SHT_LLVM_BB_ADDR_MAP
> ```
Checked for `Content.empty()` before jumping into the while loop.
Repository:
  rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D88717/new/
https://reviews.llvm.org/D88717
    
    
More information about the llvm-commits
mailing list