[llvm-commits] [PATCH] Add malloc call utility functions

Dan Gohman gohman at apple.com
Fri Sep 11 10:22:08 PDT 2009


Hi Victor,

If MallocHelper is going to replace MallocInst, how will it support
-fno-builtins?  With MallocInst, one at least had the option of
omitting the RaiseAllocations pass (though it seems llvm-gcc and
clang don't actually do this, which is a bug). With MallocHelper,
how can -fno-builtins be implemented?

Dan

On Aug 11, 2009, at 7:31 PM, Victor Hernandez wrote:


> I am working on fixing the MallocInst/i64 alloca bug:
> http://llvm.org/bugs/show_bug.cgi?id=715
>
> Here is the first of a series of patches that will result in tearing  
> out MallocInst.  Before I can tear it out, I need to update all of  
> the optimization passes and transforms that operate on MallocInst to  
> operate on malloc CallInst instead.
>
> This patch consists of a set of utility functions that create IR for  
> malloc calls and identify that IR.  It also rewrites  
> LowerAllocations to use the new utility function,  
> CallInst::CreateMalloc().
>
>
> <mallocUtils.diff>
>
>
> Victor
>
> ---
> Victor Hernandez          vhernandez at apple.com
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>





More information about the llvm-commits mailing list