OSDN Git Service

[InlineFunction] Set arg attrs even if there only are VarArg attrs.
authorFlorian Hahn <florian.hahn@arm.com>
Sun, 4 Feb 2018 18:27:47 +0000 (18:27 +0000)
committerFlorian Hahn <florian.hahn@arm.com>
Sun, 4 Feb 2018 18:27:47 +0000 (18:27 +0000)
commitd0f9a4c472eecbe47c0c7d17d263fd291938cfc1
tree603ae689513f004930be8ae34670424b55b086d3
parentcb6c95b202481587d74986f328a53733f509c39e
[InlineFunction] Set arg attrs even if there only are VarArg attrs.

When using the partial inliner, we might have attributes for forwarded
varargs, but the CodeExtractor does not create an empty argument
attribute set for regular arguments in that case, because it does not know
of the additional arguments. So in case we have attributes for VarArgs, we
also have to make sure we create (empty) attributes for all regular arguments.

This fixes PR36210.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@324197 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Utils/InlineFunction.cpp
test/Transforms/CodeExtractor/PartialInlineVarArg.ll