rjmccall added a comment.

I'm somewhat surprised LLVM doesn't already canonicalize this, but ok.

Should we also do this when building a constant struct?



================
Comment at: lib/CodeGen/CGExprConstant.cpp:873
       Elts.push_back(C);
+      if (!C->isNullValue())
+        AllNullValues = false;
----------------
Please short-circuit this if AllNullValues is already false.


https://reviews.llvm.org/D42549



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to