[PATCH] D67280: [Mips][msa] Fix inifinite loop for mips.nori.b intrinsic

Mirko Brkusanin via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 6 08:30:20 PDT 2019


mbrkusanin created this revision.
mbrkusanin added reviewers: atanasyan, petarj, mstojanovic, sdardis.
mbrkusanin added a project: LLVM.
Herald added a subscriber: arichardson.

When value of immediate in mips.nori.b is 255 (which has all ones in binary form
as 8bit integer) DAGCombiner and Legalizer would fall in an infinite loop. 
DAGCombiner would try to simplify 'or %value, -1' by turning %value into UNDEF.
Legalizer will turn it back into Constant<0> which would then be again turned
into UNDEF by DAGCombiner. To avoid this loop we make UNDEF legal for MSA int 
types on Mips.


https://reviews.llvm.org/D67280

Files:
  lib/Target/Mips/MipsSEISelLowering.cpp
  test/CodeGen/Mips/cconv/vector.ll
  test/CodeGen/Mips/msa/2r_vector_scalar.ll
  test/CodeGen/Mips/msa/nori.b.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D67280.219114.patch
Type: text/x-patch
Size: 51976 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190906/eb2519ce/attachment.bin>


More information about the llvm-commits mailing list