[PATCH] D109335: [NFC][InstCombine] Make check for sret in a vararg function clearer
Arthur Eubanks via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 7 11:22:32 PDT 2021
This revision was automatically updated to reflect the committed changes.
Closed by commit rGb81fc14f2da1: [NFC][InstCombine] Make check for sret in a vararg function clearer (authored by aeubanks).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D109335/new/
https://reviews.llvm.org/D109335
Files:
llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp
Index: llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp
===================================================================
--- llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp
+++ llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp
@@ -2884,7 +2884,7 @@
// that are compatible with being a vararg call argument.
unsigned SRetIdx;
if (CallerPAL.hasAttrSomewhere(Attribute::StructRet, &SRetIdx) &&
- SRetIdx > FT->getNumParams())
+ SRetIdx - AttributeList::FirstArgIndex >= FT->getNumParams())
return false;
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D109335.371132.patch
Type: text/x-patch
Size: 559 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210907/05b5ab7c/attachment.bin>
More information about the llvm-commits
mailing list