[lld] r240147 - [lld] Allow LLD passes to return error codes.

Davide Italiano davide at freebsd.org
Fri Jun 19 14:37:53 PDT 2015

On Fri, Jun 19, 2015 at 2:24 PM, Lang Hames <lhames at gmail.com> wrote:
> Hi Davide,
> This was posted for review at http://reviews.llvm.org/D10552 and reviewed by
> Rui, who Ok'd it. The approach was also verbally Ok'd by Nick Kledzik.
> The phab review should have gone out to lld subscribers, but it doesn't look
> like emails were sent to llvm-commits. That's odd, but I'm still digesting
> Phabricator's interface, so I might have missed a tag somewhere. I'll try to
> check next time I post a review.

It's fine. I try to include the link to review in the commit message,
because it's also useful for record purposes.

> Is there any reason not to return std::error_code from passes? It seems
> reasonable that a pass may fail. The specific case I have in mind is TLV
> relocation processing on MachO: If the OS version min is too low we want to
> error out and report back to the user. This kind of use seems to have been
> anticipated: The PassManager already returns an error code, although it was
> always default constructed (no error), and not yet checked.
> - Lang.

OK, thanks for the explanation. It makes sense.


"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