[LLVMdev] _Znwm is not a builtin

Chris Lattner clattner at apple.com
Wed May 15 21:25:49 PDT 2013


On May 15, 2013, at 8:59 PM, Chandler Carruth <chandlerc at google.com> wrote:

> 
> On Wed, May 15, 2013 at 9:46 PM, Chris Lattner <clattner at apple.com> wrote:
> It's not clear to me that "builtin" is the right way to model this, but it definitely sounds like this should be an attribute on a call site (as opposed to on the function itself).  What specific kinds of optimizations are we interested in doing to _Znwm calls?
> 
> You can see the paper to the C++ committee, but my primary goals.
> 
> 1) run SROA over heap memory
> 2) pool together heap allocations on the same CFG trace
> 3) promote (sufficiently small and lifetime bounded) heap allocations to stack allocations

Ok, presumably also 4) know it returns non-aliased memory, and maybe other stuff in the future.  Are you "happy" to special case operator new and new[], or should we design something more extravagant to handle other cases?

-Chris
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20130515/ff6b33c8/attachment.html>


More information about the llvm-dev mailing list