[PATCH] D79755: Implement constexpr BinaryOperator for vector types

Erich Keane via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon May 11 17:50:57 PDT 2020


erichkeane created this revision.
erichkeane added reviewers: eli.friedman, RKSimon, aaron.ballman.

These operations do member-wise versions of the all of the listed
operations.  This patch implements all of the binaryoperators for these
types. Note that the test is required to use codegen as I could not come
up with a good way to validate the values without the array-subscript
operator implemented (which is likely a much more involved change).

This is not full constexpr support for these types, but should at least 
support a large number of uses.


https://reviews.llvm.org/D79755

Files:
  clang/lib/AST/ExprConstant.cpp
  clang/test/SemaCXX/constexpr-vectors.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D79755.263317.patch
Type: text/x-patch
Size: 38267 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20200512/8f8b0273/attachment-0001.bin>


More information about the cfe-commits mailing list