[llvm-commits] [llvm] r132797 - in /llvm/trunk: include/llvm/Analysis/CallGraph.h lib/Analysis/IPA/CallGraph.cpp lib/Analysis/IPA/CallGraphSCCPass.cpp lib/Transforms/Utils/InlineFunction.cpp

John McCall rjmccall at apple.com
Fri Jun 10 09:11:17 PDT 2011


On Jun 9, 2011, at 9:13 PM, Nick Lewycky wrote:
> John McCall wrote:
>> Author: rjmccall
>> Date: Thu Jun  9 14:46:27 2011
>> New Revision: 132797
>> 
>> URL: http://llvm.org/viewvc/llvm-project?rev=132797&view=rev
>> Log:
>> Teach the CallGraph to ignore calls to intrinsics.
> 
> Why?

I was hacking on the inliner and found it annoying to have to update
the call graph when inserting and removing eh.exception and
eh.selector calls.  We were already opting the debug info intrinsics
out of the call graph, or at least not making it reliable for them, so
I was considering just widening that to include a few more intrinsics,
but decided that it just doesn't make any sense to have intrinsics in
the call graph at all.  The call graph exists to serve interprocedural
optimizations, which will never trigger for intrinsics because they're
always declarations.  Meanwhile, it's expensive to make edges for
all these intrinsics, which can be pretty dense in the IR, and which
are very frequently added and removed by generic optimizations.

On Jun 9, 2011, at 9:15 PM, Cameron Zwarich wrote:
> I think this needs a test case.

Uh, sure, I'll see what I can do.

John.



More information about the llvm-commits mailing list