[PATCH] D20272: [ELF] - Support of compressed input sections implemented.

George Rimar via llvm-commits llvm-commits at lists.llvm.org
Mon May 16 07:27:24 PDT 2016


grimar added a comment.

In http://reviews.llvm.org/D20272#430837, @ruiu wrote:

> OK, but compressed sections shouldn't be uncompressed until they need to be. At the symbol resolution phase, we don't need any section contents (and at the phase and gc phase, a lot of sections are eliminated.)


Right now the first major place I am looking how to avoid is:

  >template <class ELFT> void Writer<ELFT>::run() {
  >  copyLocalSymbols();
  >> includeInSymtab()
  ....

    if (auto *S = dyn_cast<MergeInputSection<ELFT>>(D->Section))
      if (S->getRangeAndSize(D->Value).first->second ==
          MergeInputSection<ELFT>::PieceDead)
        return false;
  }

  I probably do not want to comment it because still investigating it, I just have a guess that we can avoid uncompression here and just check if whole section is dead or not instead of if checking if PieceDead. I am not ready to continue that thoughts now, still looking at, I am not familar with that code yet :)


http://reviews.llvm.org/D20272





More information about the llvm-commits mailing list