[PATCH] D33772: [LLD][ELF] SHF_LINK_ORDER should sort based on InputSectionDescriptions

Rafael Avila de Espindola via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 1 16:56:45 PDT 2017


Peter Smith via Phabricator <reviews at reviews.llvm.org> writes:

> Index: ELF/Writer.cpp
> ===================================================================
> --- ELF/Writer.cpp
> +++ ELF/Writer.cpp
> @@ -257,12 +257,6 @@
>    if (ErrorCount)
>      return;
>  
> -  if (!Script->Opt.HasSections) {
> -    if (!Config->Relocatable)
> -      fixSectionAlignments();
> -    Script->fabricateDefaultCommands();
> -  }
> -

On trunk we now have

  if (!Script->Opt.HasSections) {
    if (!Config->Relocatable)
      fixSectionAlignments();
    Script->fabricateDefaultCommands();
  } else {
    Script->synchronize();
  }

Would it be possible to move this block together? That would avoid the
need to change synchronize as it would now be earlier too.

Cheers,
Rafael


More information about the llvm-commits mailing list