From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1725) id A26963839802; Fri, 25 Jun 2021 16:18:57 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A26963839802 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: William Schmidt To: gcc-cvs@gcc.gnu.org Subject: [gcc(refs/users/wschmidt/heads/builtins10)] rs6000: Update rs6000_builtin_decl X-Act-Checkin: gcc X-Git-Author: Bill Schmidt X-Git-Refname: refs/users/wschmidt/heads/builtins10 X-Git-Oldrev: 743ac5ef9741fbd8028f5e78ecef1c6a55496181 X-Git-Newrev: f059b4268ef24b85ddba070ec037d352693937f8 Message-Id: <20210625161857.A26963839802@sourceware.org> Date: Fri, 25 Jun 2021 16:18:57 +0000 (GMT) X-BeenThere: gcc-cvs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jun 2021 16:18:57 -0000 https://gcc.gnu.org/g:f059b4268ef24b85ddba070ec037d352693937f8 commit f059b4268ef24b85ddba070ec037d352693937f8 Author: Bill Schmidt Date: Fri Mar 5 16:05:50 2021 -0600 rs6000: Update rs6000_builtin_decl 2021-03-05 Bill Schmidt gcc/ * config/rs6000/rs6000-call.c (rs6000_new_builtin_decl): New function. (rs6000_builtin_decl): Call it. Diff: --- gcc/config/rs6000/rs6000-call.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/gcc/config/rs6000/rs6000-call.c b/gcc/config/rs6000/rs6000-call.c index 6b60f0852ef..54cf014ed23 100644 --- a/gcc/config/rs6000/rs6000-call.c +++ b/gcc/config/rs6000/rs6000-call.c @@ -16258,11 +16258,31 @@ rs6000_init_builtins (void) } } +static tree +rs6000_new_builtin_decl (unsigned code, bool initialize_p ATTRIBUTE_UNUSED) +{ + rs6000_gen_builtins fcode = (rs6000_gen_builtins) code; + + if (fcode >= RS6000_OVLD_MAX) + return error_mark_node; + + if (!rs6000_new_builtin_is_supported_p (fcode)) + { + rs6000_invalid_new_builtin (fcode); + return error_mark_node; + } + + return rs6000_builtin_decls_x[code]; +} + /* Returns the rs6000 builtin decl for CODE. */ tree rs6000_builtin_decl (unsigned code, bool initialize_p ATTRIBUTE_UNUSED) { + if (new_builtins_are_live) + return rs6000_new_builtin_decl (code, initialize_p); + HOST_WIDE_INT fnmask; if (code >= RS6000_BUILTIN_COUNT)