[clang] [X86][Clang] VectorExprEvaluator::VisitCallExpr / InterpretBuiltin - Allow SSE/AVX FP MAX/MIN intrinsics to be used in constexpr (PR #171966)

Simon Pilgrim via cfe-commits cfe-commits at lists.llvm.org
Wed Dec 17 03:02:52 PST 2025


================
@@ -468,6 +479,9 @@ let Features = "avx", Attributes = [NoThrow, Const, RequiredVectorWidth<256>] in
   def vperm2f128_pd256 : X86Builtin<"_Vector<4, double>(_Vector<4, double>, _Vector<4, double>, _Constant int)">;
   def vperm2f128_ps256 : X86Builtin<"_Vector<8, float>(_Vector<8, float>, _Vector<8, float>, _Constant int)">;
   def vperm2f128_si256 : X86Builtin<"_Vector<8, int>(_Vector<8, int>, _Vector<8, int>, _Constant int)">;
+}
+
+let Features = "avx", Attributes = [NoThrow, Const, Constexpr, RequiredVectorWidth<256>] in {
----------------
RKSimon wrote:

move these to an existing avx 256 block - doesn't matter if you keep the foreach or just epand them

https://github.com/llvm/llvm-project/pull/171966


More information about the cfe-commits mailing list