From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pl1-x631.google.com (mail-pl1-x631.google.com [IPv6:2607:f8b0:4864:20::631]) by sourceware.org (Postfix) with ESMTPS id A5D523856DC0 for ; Mon, 24 Oct 2022 15:24:56 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org A5D523856DC0 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-pl1-x631.google.com with SMTP id 4so2829447pli.0 for ; Mon, 24 Oct 2022 08:24:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=reYBa/fzyxU8YDDMxUPwEnTkboEHqKr45f+eoLrqZo0=; b=cAoEjPDvB8Wg3ydsZ2ZfK29QICM//OCmN2PWkW+nzI6XguZ9MPKG09AP+0/C4IpHeq uH/coOHv7YRr0k0PnFTSwvGOp5fhAE6E3SSS9lyyiUpGNpnNUhkunIdGlspeDePjBmEF QXU+JxzZUgcVQEH9FfHbrS8gX66wbNCIpylEYHVZJRGlxo3g7TcvDZoMhk1vf3PGcryU X/0V/aBhL9GgRDB3am4gSnWJmiBpGjGf3tGKwXn3BI6/oSlgATlYLCn3s4hjJ+R1FTvO EZp/gOqUP6bUgPhfpcw8OzNFH9sWoNgeikOYNAcS6URaAYwE19kEh0wfRzjdJiHR1//D cQwg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=reYBa/fzyxU8YDDMxUPwEnTkboEHqKr45f+eoLrqZo0=; b=MNIlTLMjLDr3TYE6aVlLIszH1LRrNeCY2adgNIQnlsYQpR+GsxDLtun3xSPDhGCWL3 roJu86+IGKby9xh5WoodnMLyz4pSLYPuqcTkG0Y9kZfziNCcosrvAhQ+enYCxvuQjJNd 5xTXs5cR/aORdqKBQFPAg/43yRABGoivl815/q1izNa719Av6Wg7PVN4iVD8szHuGeYP vKsyWTf2suKzPFb8O/yuq6fz4SMuP+hnbS2nv8SXn4nQFsiYyQ2IKvkwj9x9xpPXs+CQ 8lr5ukvdr68jnZX96jSnMQIm6//wsiPSChzAfp0bak19xq1Xw4zwOsZBTLXpE6pSlkIJ PUFQ== X-Gm-Message-State: ACrzQf16Zuw3NB+Nx/gFIV10X9W73KRiz6JztZQ5M2QWQmx5+GsHoHWf QuAN7cFpHX0v0KwtQjcK5rKSUIZGTJw= X-Google-Smtp-Source: AMsMyM61X8KgUU4GRsmdbY1k05kvrkerSd09Fdf65nHgFyKQDTxwIDL7Bxd47iClzGx1Lokj1RcdoQ== X-Received: by 2002:a17:903:200b:b0:186:892f:9f0b with SMTP id s11-20020a170903200b00b00186892f9f0bmr13264341pla.56.1666625095691; Mon, 24 Oct 2022 08:24:55 -0700 (PDT) Received: from ?IPV6:2601:681:8600:13d0::f0a? ([2601:681:8600:13d0::f0a]) by smtp.gmail.com with ESMTPSA id p184-20020a625bc1000000b005618189b0ffsm19942425pfb.104.2022.10.24.08.24.54 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 24 Oct 2022 08:24:55 -0700 (PDT) Message-ID: <28635ee5-0ff0-aeaa-0f8d-4c31d2e05159@gmail.com> Date: Mon, 24 Oct 2022 09:24:53 -0600 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.3.1 Subject: Re: [PATCH] builtins: Add __builtin_nextafterf16b builtin Content-Language: en-US To: Jakub Jelinek , "Joseph S. Myers" , Richard Biener Cc: gcc-patches@gcc.gnu.org, Jonathan Wakely References: From: Jeff Law In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,KAM_SHORT,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 10/21/22 01:23, Jakub Jelinek wrote: > Hi! > > On top of the pending > https://gcc.gnu.org/pipermail/gcc-patches/2022-October/603665.html > patch, the following patch adds another needed builtin. > The above patch adds among other things __builtin_nextafterf16 > builtin which we need in order to constexpr evaluate > std::nextafter(_Float16) overload (patch for that to be posted momentarily). > While there is inline implementation of the overload, it isn't constant > evaluation friendly, and the builtin doesn't need libm implementation > because it will be used only during constant expression evaluation. > We need the same thing also for std::nextafter(__gnu_cxx::__bfloat16_t) > though and this patch does that. > > Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk? > > 2022-10-21 Jakub Jelinek > > * builtin-types.def (BT_FN_BFLOAT16_BFLOAT16_BFLOAT16): New. > * builtins.def (BUILT_IN_NEXTAFTERF16B): New builtin. > * fold-const-call.cc (fold_const_call_sss): Handle > CFN_BUILT_IN_NEXTAFTERF16B. OK jeff