[PATCH] D20433: [ELF] - Lazy initialization of MergeInputSection class internals.
    Rui Ueyama via llvm-commits 
    llvm-commits at lists.llvm.org
       
    Mon May 23 10:28:13 PDT 2016
    
    
  
ruiu added a comment.
r270455 should make things a lot easier to support compressed sections. Now I think basically you want to write InputSection::uncompress() function and call it like this from the driver's link function.
    for (InputSectionBase<ELFT> *S : F->getSections()) {
      if (!S || S == &InputSection<ELFT>::Discarded || !S->Live)
        continue;
      if (S->Compressed)
        S->uncompress();
      if (auto *MS = dyn_cast<MergeInputSection<ELFT>>(S))
        MS->splitIntoPieces();
    }
  }
http://reviews.llvm.org/D20433
    
    
More information about the llvm-commits
mailing list