From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS17314 8.43.84.0/22 X-Spam-Status: No, score=-3.7 required=3.0 tests=AWL,BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, PDS_RDNS_DYNAMIC_FP,RCVD_IN_DNSWL_MED,RDNS_DYNAMIC,SPF_HELO_PASS, SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from sourceware.org (ip-8-43-85-97.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id 6A78A1F953 for ; Wed, 27 Oct 2021 12:43:25 +0000 (UTC) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id EDC2D385803F for ; Wed, 27 Oct 2021 12:43:23 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org EDC2D385803F DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1635338604; bh=//sxJfyYchOWmrRpVuJ9xFnzg+hNUFfUctVp3fAMKSQ=; h=References:In-Reply-To:Date:Subject:To:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=m9I9JeiZvfUC6My5q8WwI2/5jk1SOEFE0TtDNo5zTjl1GYrgsgSw1a4aYtubKSQXw QuP6+LS9iCmmWiVIA8eFu0FsEYers9IXhVe6dgSfaWFj1szMpDavZZZz2+6KXtskJ9 tqg42an6vP2vnDeXvYFwT3xsaxiZccOvdtP4bU5k= Received: from mail-pf1-x436.google.com (mail-pf1-x436.google.com [IPv6:2607:f8b0:4864:20::436]) by sourceware.org (Postfix) with ESMTPS id 377E8385840D for ; Wed, 27 Oct 2021 12:43:04 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 377E8385840D Received: by mail-pf1-x436.google.com with SMTP id t184so2675749pfd.0 for ; Wed, 27 Oct 2021 05:43:04 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=//sxJfyYchOWmrRpVuJ9xFnzg+hNUFfUctVp3fAMKSQ=; b=Xw48M5OwCyc5xrUu3BGU7kdnB/nkBnB3Hwyoo4NN3FQgoYuyyPmDI5Teq60fLax+gS +JX8LHHoNvNcV3g10JI+OpqO7QuBNbRMjUOBzXuJ0oVSMFNcZ/6Equgzj5Mcc6zhbjyq rcKt0tMI39+oUk/UhA8f/aSYIaoGo33eeNNUHcHqfH8T0jeLIHfIz9DxE9JJk8riEXwn GshxCFWXjy15++E0inFxGN5F6JvhjgzdCHUYbfJnthB21f6xOitp1BcQKcMS329TAXVM pnMsS4JrUD9pToL5FG49LGG8bGXtDvhgYjST5f838mW6S6ac9u5xu22D4SsSRo29dWPw S/xw== X-Gm-Message-State: AOAM532V83eFilIpKc8Jtk1Qn7rmrBPpODMt3jbMAIXQnuOsRx6Dmp41 TpBNkEPkB9gdtZb0IF7iElZ1ayq8GwJR2mCnIC/fF67TpHY= X-Google-Smtp-Source: ABdhPJxCrN/WGQvDZLipx0cALUpU+hRRf3RVn1+gnwLRZL6/8IZ/i6GLs1pACjzei7ExWU01x0JQAVgwSLWq6ZCrxvs= X-Received: by 2002:a62:7858:0:b0:47c:1cf3:d95 with SMTP id t85-20020a627858000000b0047c1cf30d95mr8024896pfc.60.1635338583332; Wed, 27 Oct 2021 05:43:03 -0700 (PDT) MIME-Version: 1.0 References: <20211027024323.1199441-1-goldstein.w.n@gmail.com> In-Reply-To: <20211027024323.1199441-1-goldstein.w.n@gmail.com> Date: Wed, 27 Oct 2021 05:42:26 -0700 Message-ID: Subject: Re: [PATCH v1 1/6] String: Add __memcmpeq as build target To: Noah Goldstein Content-Type: text/plain; charset="UTF-8" X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: "H.J. Lu via Libc-alpha" Reply-To: "H.J. Lu" Cc: GNU C Library Errors-To: libc-alpha-bounces+e=80x24.org@sourceware.org Sender: "Libc-alpha" On Tue, Oct 26, 2021 at 7:43 PM Noah Goldstein wrote: > > No bug. This commit just adds __memcmpeq as a build target so that > implementations for __memcmpeq that are not just aliases to memcmp can > be supported. > --- > string/Makefile | 2 +- > string/memcmpeq.c | 24 ++++++++++++++++++++++++ > 2 files changed, 25 insertions(+), 1 deletion(-) > create mode 100644 string/memcmpeq.c > > diff --git a/string/Makefile b/string/Makefile > index 40d6fac133..2199dd30b7 100644 > --- a/string/Makefile > +++ b/string/Makefile > @@ -34,7 +34,7 @@ routines := strcat strchr strcmp strcoll strcpy strcspn \ > strerror _strerror strlen strnlen \ > strncat strncmp strncpy \ > strrchr strpbrk strsignal strspn strstr strtok \ > - strtok_r strxfrm memchr memcmp memmove memset \ > + strtok_r strxfrm memchr memcmp memcmpeq memmove memset \ > mempcpy bcopy bzero ffs ffsll stpcpy stpncpy \ > strcasecmp strncase strcasecmp_l strncase_l \ > memccpy memcpy wordcopy strsep strcasestr \ > diff --git a/string/memcmpeq.c b/string/memcmpeq.c > new file mode 100644 > index 0000000000..08726325a8 > --- /dev/null > +++ b/string/memcmpeq.c > @@ -0,0 +1,24 @@ > +/* Copyright (C) 1991-2021 Free Software Foundation, Inc. > + This file is part of the GNU C Library. > + > + The GNU C Library is free software; you can redistribute it and/or > + modify it under the terms of the GNU Lesser General Public > + License as published by the Free Software Foundation; either > + version 2.1 of the License, or (at your option) any later version. > + > + The GNU C Library is distributed in the hope that it will be useful, > + but WITHOUT ANY WARRANTY; without even the implied warranty of > + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU > + Lesser General Public License for more details. > + > + You should have received a copy of the GNU Lesser General Public > + License along with the GNU C Library; if not, see > + . */ > + > +/* This file is intentionally left empty. It exists so that both > + architectures which implement __memcmpeq seperately from memcmp and > + architectures which implement __memcmpeq by having it alias memcmp will > + build. > + > + The alias for __memcmpeq to memcmp for the C implementation is in > + memcmp.c. */ > -- > 2.25.1 > LGTM. Reviewed-by: H.J. Lu Thanks. H.J.