[cfe-dev] questions about expansion of builtins.

Eli Friedman eli.friedman at gmail.com
Fri Sep 20 15:58:26 PDT 2013


On Fri, Sep 20, 2013 at 2:50 PM, Iain Sandoe <iain at codesourcery.com> wrote:

> Hello Eric,
>
> On 20 Sep 2013, at 22:17, Eric Christopher wrote:
>
> > I'd probably expect to lower builtins to multiple basic blocks in the
> > backend if they needed to do so…
>
> Perhaps, then,  I'm missing an alternate solution,
> we wanted to expand in the FE to expose operands to opportunities for
> scalarisation etc.
> (that, in particular, is an important optimisation for the target)
>
> - so am I attempting something unsupported?
>
>
You should be able to generate basically anything from CGBuiltin.cpp, using
code similar to what you've written.  Your code probably just has a bug
somewhere.

In particular, your usage of getGlobalContext() looks suspect.

-Eli
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20130920/d94f9c0a/attachment.html>


More information about the cfe-dev mailing list