From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from relay4-d.mail.gandi.net (relay4-d.mail.gandi.net [IPv6:2001:4b98:dc4:8::224]) by sourceware.org (Postfix) with ESMTPS id CA7783858423 for ; Fri, 21 Jan 2022 18:51:28 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org CA7783858423 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=bec.de Authentication-Results: sourceware.org; spf=none smtp.mailfrom=bec.de Received: (Authenticated sender: joerg@bec.de) by mail.gandi.net (Postfix) with ESMTPSA id 09442E0003; Fri, 21 Jan 2022 18:51:25 +0000 (UTC) Date: Fri, 21 Jan 2022 19:51:22 +0100 From: Joerg Sonnenberger To: libc-coord@lists.openwall.com Cc: GNU C Library , Richard Biener via Gcc Subject: Re: [libc-coord] Add new ABIs '__strcmpeq', '__strncmpeq', '__wcscmpeq' and '__wcsncmpeq' to libc Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-0.9 required=5.0 tests=BAYES_00, KAM_DMARC_STATUS, KAM_LAZY_DOMAIN_SECURITY, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=no autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gcc@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Jan 2022 18:51:30 -0000 On Thu, Jan 20, 2022 at 04:56:59PM -0600, Noah Goldstein wrote: > The goal is that the new interfaces will be usable as an optimization > by compilers if a program uses the return value of the non "eq" > variant as a boolean. So I'm curious, but can you demonstrate that it can be implemented notacibly faster than regular strcmp? Unlike for memcmp, I don't see an obvious way to save any operations. Joerg