[LLVMdev] Proposal to merge SimplifyLibCalls into InstCombiner

Meador Inge meadori at codesourcery.com
Wed Nov 7 20:31:00 PST 2012


On 08/03/2012 03:15 PM, Chris Lattner wrote:

> On Aug 3, 2012, at 12:56 PM, Meador Inge <meadori at codesourcery.com> wrote:
>>>> An option for enabling/disabling library call simplification in `InstCombiner`
>>>> will be available.  For backwards compatibility perhaps it should remain
>>>> '-simplify-libcalls'.  The `NumSimplified` and `NumAnnotated` statistics shall
>>>> be added to `InstCombiner`.
>>>
>>> There is no need to preserver the -simplify-libcalls flag.  It's an internal
>>> implementation detail of the compiler, one that is better left in the past :)
>>
>> Do you think we still need some way to disable just the library call
>> simplification now that it is a part of the instruction combiner?
> 
> It should just be part of instcombine, but be gated by what TargetLibraryInfo says.
> If you want to turn off these libcall optimizations, it should be by marking the
> libcalls as off-limits in TLI.

There is also the matter of -fno-builtin, which I missed in my original
proposal.  Patch posted here:
http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20121105/155370.html.

-- 
Meador Inge
CodeSourcery / Mentor Embedded



More information about the llvm-dev mailing list