]> granicus.if.org Git - llvm/commit
Fix the bug of samplepgo indirect call promption when type casting of the return...
authorDehao Chen <dehao@google.com>
Mon, 6 Feb 2017 18:10:36 +0000 (18:10 +0000)
committerDehao Chen <dehao@google.com>
Mon, 6 Feb 2017 18:10:36 +0000 (18:10 +0000)
commitd2d041f452b0d892a80611e8848eada1f7ecbaf3
tree64a54a054e3187e55356cf00f5069fbeb67be2e2
parent2a4edb648f933a0e7134e4d4f4783bec39606595
Fix the bug of samplepgo indirect call promption when type casting of the return value is needed.

Summary: When type casting of the return value is needed, promoteIndirectCall will return the type casting instruction instead of the direct call. This patch changed to return the direct call instruction instead.

Reviewers: davidxl

Reviewed By: davidxl

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D29569

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@294205 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/IPO/SampleProfile.cpp
test/Transforms/SampleProfile/indirect-call.ll