From be6d6fdab5b5f7ebdb5270e09fcc1a1e5ec0be16 Mon Sep 17 00:00:00 2001 From: Stefan Schulze Frielinghaus Date: Fri, 12 Dec 2025 20:44:45 +0100 Subject: [PATCH] s390: Warn about non-overloaded deprecated builtins Previously a warning for a deprecated builtin was only emitted for overloaded builtins. Warn about non-overloaded deprecated builtins, too. gcc/ChangeLog: * config/s390/s390.cc (s390_expand_builtin): Warn about non-overloaded deprecated builtins. --- gcc/config/s390/s390.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/gcc/config/s390/s390.cc b/gcc/config/s390/s390.cc index 359ea1c3d64..d2a7fa29978 100644 --- a/gcc/config/s390/s390.cc +++ b/gcc/config/s390/s390.cc @@ -917,6 +917,9 @@ s390_expand_builtin (tree exp, rtx target, rtx subtarget ATTRIBUTE_UNUSED, error ("Builtin %qF requires z17 or higher", fndecl); return const0_rtx; } + + if (bflags & B_DEP) + warning (0, "builtin %qF is deprecated", fndecl); } if (fcode >= S390_OVERLOADED_BUILTIN_VAR_OFFSET && fcode < S390_ALL_BUILTIN_MAX) -- 2.47.3