clang: Add __builtin_elementwise_fma
authorMatt Arsenault <Matthew.Arsenault@amd.com>
Thu, 8 Dec 2022 03:49:27 +0000 (22:49 -0500)
committerMatt Arsenault <arsenm2@gmail.com>
Sat, 25 Feb 2023 01:55:08 +0000 (21:55 -0400)
commit8709bcacfb3a06847b47bb6b47e8556db43f3a43
tree4b861499828d3ce9b4225b473ed376c9254624b0
parent5cf549e6b1a572f5be5a575ffb878bb927ba81b3
clang: Add  __builtin_elementwise_fma

I didn't understand why the other builtins have promotion logic,
or how it would apply for a ternary operation. Implicit conversions
are evil to begin with,  and even more so when the purpose is to get
an exact IR intrinsic. This checks all the arguments have the same type.
clang/docs/LanguageExtensions.rst
clang/include/clang/Basic/Builtins.def
clang/include/clang/Sema/Sema.h
clang/lib/CodeGen/CGBuiltin.cpp
clang/lib/Sema/SemaChecking.cpp
clang/test/CodeGen/builtins-elementwise-math.c
clang/test/Sema/builtins-elementwise-math.c