[PATCH] D63058: [InlineCost] Fix bug 42084: return the first negative result

Yevgeny Rouban via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Jun 9 07:22:41 PDT 2019


yrouban created this revision.
yrouban added a reviewer: xbolva00.
Herald added subscribers: haicheng, hiraditya, eraman.
Herald added a project: LLVM.

Full inline cost calculation results in visiting more instructions. This may result in getting another cause of a bailout or mistakenly forget that there was a negative result where Cost > Threshold.
This patch makes //InlineCost// consistent in returning the same //InlineResult// regardless of the flag //ComputeFullInlineCost//.
This patch (particularly the part in //CallAnalyzer::analyzeBlock()//) fixes the bug https://bugs.llvm.org/show_bug.cgi?id=42084


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D63058

Files:
  llvm/lib/Analysis/InlineCost.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D63058.203737.patch
Type: text/x-patch
Size: 3973 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190609/13d22b1c/attachment.bin>


More information about the llvm-commits mailing list