[PATCH] D25671: [SLP] Fix for PR30626: Compiler crash inside SLP Vectorizer.

Alexey Bataev via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 17 05:56:01 PDT 2016


ABataev created this revision.
ABataev added reviewers: mkuper, hfinkel, mzolotukhin.
ABataev added subscribers: RKSimon, spatel, llvm-commits.

After successfull horizontal reduction vectorization attempt for PHI node vectorizer tries to update root binary op by combining vectorized tree and the ReductionPHI node. But during vectorization this ReductionPHI can be vectorized itself and replaced by the `undef` value, while the instruction itself is marked for deletion. This 'marked for deletion' PHI node then can be used in new binary operation, causing "Use still stuck around after Def is destroyed" crash upon PHI node deletion.

Also the test is fixed to make it perform actual testing.


https://reviews.llvm.org/D25671

Files:
  lib/Transforms/Vectorize/SLPVectorizer.cpp
  test/Transforms/SLPVectorizer/X86/horizontal.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D25671.74832.patch
Type: text/x-patch
Size: 7528 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20161017/1aa2425f/attachment.bin>


More information about the llvm-commits mailing list