[PATCH] D24301: [ConstantFold] Teach how to fold a bitcast of a constant vector with some undef elements.

Andrea Di Biagio via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 13 02:42:54 PDT 2016


andreadb added inline comments.

================
Comment at: lib/Analysis/ConstantFolding.cpp:234-235
@@ +233,4 @@
+      // Correctly Propagate undef values.
+      for (unsigned j = 0; j != Ratio; ++j)
+        Result.push_back(UndefValue::get(DstEltTy));
+      continue;
----------------
ABataev wrote:
> ```
> Result.append(Ratio, UndefValue::get(DstEltTy));
> ```
> ?
Thanks Alexey, I am going to change it.


https://reviews.llvm.org/D24301





More information about the llvm-commits mailing list