[PATCH] D9509: [cuda] Driver changes to build and stitch together host and device-side CUDA code.

Eric Christopher echristo at gmail.com
Tue Jul 7 13:58:03 PDT 2015


On Tue, Jul 7, 2015 at 1:27 PM Artem Belevich <tra at google.com> wrote:

> In http://reviews.llvm.org/D9509#200597, @echristo wrote:
>
> > Couple of inline comments, and I'm still not a huge fan of the
> getTargetToolChain bits. It seems like we should be able to have a single
> interface to getting a target toolchain that works for both cases. Maybe
> compute the triple up front for use in the rest of the driver for the host?
>
>
> Existing code commingles two independent things -- figuring out target
> triple value and retrieving corresponding ToolChain for a given Triple. My
> change just refactored out Triple->ToolChain mapping.
>
>
Right. That's a good start for sure. Let's also see if we can refactor out
BindArchAction to be a Triple (or stringref of triple) instead of passing
DarwinArchName around and just use the triple.


> ----------------
> echristo wrote:
> > Can you rearrange the code so that it doesn't need the forward
> declaration?
> Nope. PrintActions1 and PrintActionList call each other recursively. At
> least one of them must have forward declaration.
>

Hrm.

-eric
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20150707/54deccaf/attachment.html>


More information about the cfe-commits mailing list