Inliner: Non-local functions in COMDATs shouldn't be dropped
authorDavid Majnemer <david.majnemer@gmail.com>
Wed, 8 Oct 2014 19:32:32 +0000 (19:32 +0000)
committerDavid Majnemer <david.majnemer@gmail.com>
Wed, 8 Oct 2014 19:32:32 +0000 (19:32 +0000)
commitb5b306e6a9524458844b98bca275cfe834c84cb6
tree05ab2c044017d9f6976132f0c0910a46b2fb0737
parent0a5843e3b1d3ba28f3231ff60a0ab744ec0889b8
Inliner: Non-local functions in COMDATs shouldn't be dropped

A function with discardable linkage cannot be discarded if its a member
of a COMDAT group without considering all the other COMDAT members as
well.  This sort of thing is already handled by GlobalOpt/GlobalDCE.

This fixes PR21206.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@219335 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/IPO/Inliner.cpp
test/Transforms/Inline/pr21206.ll [new file with mode: 0644]