[lld] r230157 - [ELF] Teach GNU Driver about --stats.

Davide Italiano davide at freebsd.org
Tue Feb 24 19:13:48 PST 2015


On Mon, Feb 23, 2015 at 4:43 AM, Joerg Sonnenberger
<joerg at britannica.bec.de> wrote:
> I don't think there is any point in compatiblity for debugging options,
> especially as we want to commit to the output format for them. As I
> mentioned on IRC, if anything, we should try to be consistent with clang
> or other llvm tools.
>
> Joerg
>

tl;dr I'm not in favor of breaking, but I can be in favor of
extending, if possible/needed.

I think that the whole point of having a GNU compatible driver is that
of being fully compatible with the existing behaviour. I'm not sure
why you're considering debugging options as second class citizen. If
this is the general opinion I'll change them, but not until then. If I
had an awk(1) script taking the output of --stats and parsing that I
would expect the output to be the same on GNU ld and on lld --flavour
gnu.
If we want to have a better kind of statistics for lld that can be
used by the GNU ld driver, we can introduce something like
--stats-comprehensive or some other option that doesn't overlap with
the ones already available, and document it. If, instead, we really
want to follow your path, then every option for which we don't keep
compatibility must be documented. That said, I would like to stick
with GNU ld as much as we can for -flavour gnu, unless there's a very
good reason to not to. We had a related discussion about
--export-dynamic VS -export-dynamic and what you proposed was to
convince all the consumers to switch to the "right" format. I don't
think this is a reasonable request. Your mileage may vary.

-- 
Davide

"There are no solved problems; there are only problems that are more
or less solved" -- Henri Poincare



More information about the llvm-commits mailing list