[PATCH] D12935: [InstCombine] Improve Vector Demanded Bits Through Bitcasts

Sanjay Patel via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 25 08:17:29 PDT 2015


spatel added inline comments.

================
Comment at: lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp:1094
@@ -1096,2 +1093,3 @@
+    } else if ((VWidth % InVWidth) == 0) {
       // If there are more elements in the result than there are in the source,
       // then an input element is live if any of the corresponding output
----------------
It would be better if this comment matched the code. Ie, "more elements" is just ">" which is a case we don't currently handle.

"If the number of elements in the result is a multiple of the number of elements in the source..." ?

Same change for the other comments below.

================
Comment at: test/Transforms/InstCombine/x86-vector-shifts.ll:841
@@ -840,1 +840,3 @@
 
+define <8 x i16> @sse2_psra_w_var_bc(<8 x i16> %v, <2 x i64> %a) nounwind readnone uwtable {
+; CHECK-LABEL: @sse2_psra_w_var_bc
----------------
I see that the function attributes ("nounwind readnone uwtable") are endemic in this file; are any of those needed? If not, you could remove them all (as a separate commit either before or after this one).


Repository:
  rL LLVM

http://reviews.llvm.org/D12935





More information about the llvm-commits mailing list