[llvm] r255691 - [LoopVectorizer] Refine loop vectorizer's register usage calculator by ignoring specific instructions.

Dimitry Andric via llvm-commits llvm-commits at lists.llvm.org
Mon Feb 15 12:28:45 PST 2016


On 15 Dec 2015, at 23:45, Cong Hou via llvm-commits <llvm-commits at lists.llvm.org> wrote:
> 
> Author: conghou
> Date: Tue Dec 15 16:45:09 2015
> New Revision: 255691
> 
> URL: http://llvm.org/viewvc/llvm-project?rev=255691&view=rev
> Log:
> [LoopVectorizer] Refine loop vectorizer's register usage calculator by ignoring specific instructions.
> 
> (This is the third attempt to check in this patch, and the first two are r255454
> and r255460. The once failed test file reg-usage.ll is now moved to
> test/Transform/LoopVectorize/X86 directory with target datalayout and target
> triple indicated.)
> 
> LoopVectorizationCostModel::calculateRegisterUsage() is used to estimate the
> register usage for specific VFs. However, it takes into account many
> instructions that won't be vectorized, such as induction variables,
> GetElementPtr instruction, etc.. This makes the loop vectorizer too conservative
> when choosing VF. In this patch, the induction variables that won't be
> vectorized plus GetElementPtr instruction will be added to ValuesToIgnore set
> so that their register usage won't be considered any more.
> 
> 
> Differential revision: http://reviews.llvm.org/D15177

This appears to have introduced a use-after-free, see https://llvm.org/bugs/show_bug.cgi?id=26509 for the details and a valgrind log.  Is there any way we can fix this one before 3.8 release, or revert it otherwise?

-Dimitry

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 194 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160215/feda6a81/attachment.sig>


More information about the llvm-commits mailing list