[PATCH] D94560: [ELF] report section sizes when output file too large

Bob Haarman via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 13 13:28:51 PST 2021


inglorion added a comment.

In D94560#2494674 <https://reviews.llvm.org/D94560#2494674>, @MaskRay wrote:

> My feeling is similar to D94141 <https://reviews.llvm.org/D94141>: use either `-M` or `--noinhibit-exec` to get an output.

Thank you for reviewing. Quoting from D94141 <https://reviews.llvm.org/D94141>:

> We accept new features very cautiously. Adding an option has maintenance costs and recognition cost if some options have overlapping features. You can dig up the history for previous options. They need to show values to the community. For this one, I don't think it provides any additional benefit and can just confuse users as it duplicates --print-map/-M. If you want the output, add --noinhibit-exec and inspect the output with readelf -S.

I do want to point out that the intent of the present change is to aid LLD maintenance.  Note that it does not add any additional command-line options; it just provides a more informative error message in a specific failure scenario. In that sense, it's similar in spirit to printing backtraces on crashes or providing "referenced by" information for undefined symbols, both of which we do. It helps us in cases where something in LLVM changes and pushes us over the size limit, by saving the requirement to reproduce the failure just to get information that the linker already had when it failed.

Does that change the calculus?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D94560/new/

https://reviews.llvm.org/D94560



More information about the llvm-commits mailing list