[llvm] DAG: Use sincos vector libcalls through RuntimeLibcalls (PR #166984)
Simon Pilgrim via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 11 00:53:34 PST 2025
================
@@ -425,6 +425,24 @@ RTLIB::Libcall RTLIB::getCOS(EVT RetVT) {
}
RTLIB::Libcall RTLIB::getSINCOS(EVT RetVT) {
+ // TODO: Tablegen should generate this function
+ if (RetVT.isVector()) {
+ if (!RetVT.isSimple())
+ return RTLIB::UNKNOWN_LIBCALL;
+ switch (RetVT.getSimpleVT().SimpleTy) {
+ case MVT::v4f32:
+ return RTLIB::SINCOS_V4F32;
+ case MVT::v2f64:
+ return RTLIB::SINCOS_V2F64;
+ case MVT::nxv4f32:
+ return RTLIB::SINCOS_NXV4F32;
+ case MVT::nxv2f64:
+ return RTLIB::SINCOS_NXV2F64;
+ default:
----------------
RKSimon wrote:
@Andarwinux please raise an issue if you can find AMDLIBM methods llvm doesn't currently handle
https://github.com/llvm/llvm-project/pull/166984
More information about the llvm-commits
mailing list