Message ID | 20210503084435.160548-1-goldstein.w.n@gmail.com |
---|---|
State | Committed |
Commit | 1427d28e3008e2d2d467883a14a24df6a40b82b1 |
Headers |
Return-Path: <libc-alpha-bounces@sourceware.org> X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 496CA3898521; Mon, 3 May 2021 08:45:39 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 496CA3898521 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1620031539; bh=dnmUg4hj1uHdE/Ms6ATbXwrhqJX/0fTvtdAlhjUkDqA=; h=To:Subject:Date:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:From; b=bbQkHE6JXYRnbvSNcaFDJdxzoIyEyoWungReKMSBqtQOXELRBOHVJ/e2+OXgd1vW8 5relYWfkN3mH3Cp5MbMeI5soa9MXghKrXcEUKUBNPtX8mUqhss7ZI/nhU254h8jZeZ PA4q2JlrwEfGXv7/LweeMAvRWqYMGr9AUK7W9OsA= X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mail-qk1-x72c.google.com (mail-qk1-x72c.google.com [IPv6:2607:f8b0:4864:20::72c]) by sourceware.org (Postfix) with ESMTPS id D6826385DC33 for <libc-alpha@sourceware.org>; Mon, 3 May 2021 08:45:36 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org D6826385DC33 Received: by mail-qk1-x72c.google.com with SMTP id 197so4014985qkl.12 for <libc-alpha@sourceware.org>; Mon, 03 May 2021 01:45:36 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=dnmUg4hj1uHdE/Ms6ATbXwrhqJX/0fTvtdAlhjUkDqA=; b=BeuBfmRZQ+jBfxrf3mlIKBKPX+aN36ce6hOcmhxFL5Vy8hNHIGm5de/O+CHasEoWjL cDp6Z7Uv3b+BmPVdudLIelwfPSFcWAWS5AWJ1zoyqiINZNjZXsYi5UZVpe9enrbRYobV Qj4UMZRqidnsB1oGKA3Yhk7sZCG4+5WI4jMG1oeB71W3ZqfWmXBliWiEm3oNIsLFYDXQ 1ZLDHbHXADvcAHaoQrMp16EiYxPAyb0IjlBV+sx7oydmy7h5GsxehKzrQXNvM2vIIE50 yx98mjrPdBNUOGx5Qs/QNLDj80lRFxR3hVSN+AosHQ0rsqSlTg+JjnaFoGd5EiW+2qno ENkg== X-Gm-Message-State: AOAM531o/lwkuPLBIPz+Ay5MVKQGkd9zdTsuGsiQRsdSiO6vYVTlaBX+ WhB4jQCeNVCXlw+P5yOx5KUxHN6OoPQ= X-Google-Smtp-Source: ABdhPJyP1JKxtauc+oOdyrGtNwz8vIZ7nzaD80IG4RJEmxKqmG1Kw/bv7vhqsHys6hHO/KI2kgxaVQ== X-Received: by 2002:a37:ba83:: with SMTP id k125mr17812373qkf.336.1620031536165; Mon, 03 May 2021 01:45:36 -0700 (PDT) Received: from localhost.localdomain (pool-71-245-178-39.pitbpa.fios.verizon.net. [71.245.178.39]) by smtp.googlemail.com with ESMTPSA id a3sm7954970qto.2.2021.05.03.01.45.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 03 May 2021 01:45:35 -0700 (PDT) To: libc-alpha@sourceware.org Subject: [PATCH v1 1/3] Bench: Expand bench-memchr.c Date: Mon, 3 May 2021 04:44:35 -0400 Message-Id: <20210503084435.160548-1-goldstein.w.n@gmail.com> X-Mailer: git-send-email 2.29.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-12.6 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list <libc-alpha.sourceware.org> List-Unsubscribe: <https://sourceware.org/mailman/options/libc-alpha>, <mailto:libc-alpha-request@sourceware.org?subject=unsubscribe> List-Archive: <https://sourceware.org/pipermail/libc-alpha/> List-Post: <mailto:libc-alpha@sourceware.org> List-Help: <mailto:libc-alpha-request@sourceware.org?subject=help> List-Subscribe: <https://sourceware.org/mailman/listinfo/libc-alpha>, <mailto:libc-alpha-request@sourceware.org?subject=subscribe> From: Noah Goldstein via Libc-alpha <libc-alpha@sourceware.org> Reply-To: Noah Goldstein <goldstein.w.n@gmail.com> Errors-To: libc-alpha-bounces@sourceware.org Sender: "Libc-alpha" <libc-alpha-bounces@sourceware.org> |
Series |
[v1,1/3] Bench: Expand bench-memchr.c
|
|
Commit Message
Noah Goldstein
May 3, 2021, 8:44 a.m. UTC
No bug. This commit adds some additional cases for bench-memchr.c
including testing medium sizes and testing short length with both an
inbound match and out of bound match.
Signed-off-by: Noah Goldstein <goldstein.w.n@gmail.com>
---
benchtests/bench-memchr.c | 13 +++++++++++++
1 file changed, 13 insertions(+)
Comments
On Mon, May 3, 2021 at 1:45 AM Noah Goldstein <goldstein.w.n@gmail.com> wrote: > > No bug. This commit adds some additional cases for bench-memchr.c > including testing medium sizes and testing short length with both an > inbound match and out of bound match. > > Signed-off-by: Noah Goldstein <goldstein.w.n@gmail.com> > --- > benchtests/bench-memchr.c | 13 +++++++++++++ > 1 file changed, 13 insertions(+) > > diff --git a/benchtests/bench-memchr.c b/benchtests/bench-memchr.c > index f5ced9d80d..5573f93312 100644 > --- a/benchtests/bench-memchr.c > +++ b/benchtests/bench-memchr.c > @@ -135,12 +135,25 @@ test_main (void) > do_test (i, i, 256, 0); > #endif > } > + for (i = 1; i < 8; ++i) > + { > + do_test (i, i << 5, 192, 23); > + do_test (i, i << 5, 192, 0); > + do_test (i, i << 5, 256, 23); > + do_test (i, i << 5, 256, 0); > + do_test (i, i << 5, 512, 23); > + do_test (i, i << 5, 512, 0); > + } > for (i = 1; i < 32; ++i) > { > do_test (0, i, i + 1, 23); > do_test (0, i, i + 1, 0); > do_test (i, i, i + 1, 23); > do_test (i, i, i + 1, 0); > + do_test (0, i, i - 1, 23); > + do_test (0, i, i - 1, 0); > + do_test (i, i, i - 1, 23); > + do_test (i, i, i - 1, 0); > #ifdef USE_AS_MEMRCHR > /* Also test the position close to the beginning for memrchr. */ > do_test (0, 1, i + 1, 23); > -- > 2.29.2 > LGTM. I will check it in for you. BTW, can you apply an account on sourceware.org: https://sourceware.org/ so that you can push your commits directly? You can put me down as your sponsor. Thanks.
On Mon, May 3, 2021 at 1:18 PM H.J. Lu <hjl.tools@gmail.com> wrote: > > On Mon, May 3, 2021 at 1:45 AM Noah Goldstein <goldstein.w.n@gmail.com> wrote: > > > > No bug. This commit adds some additional cases for bench-memchr.c > > including testing medium sizes and testing short length with both an > > inbound match and out of bound match. > > > > Signed-off-by: Noah Goldstein <goldstein.w.n@gmail.com> > > --- > > benchtests/bench-memchr.c | 13 +++++++++++++ > > 1 file changed, 13 insertions(+) > > > > diff --git a/benchtests/bench-memchr.c b/benchtests/bench-memchr.c > > index f5ced9d80d..5573f93312 100644 > > --- a/benchtests/bench-memchr.c > > +++ b/benchtests/bench-memchr.c > > @@ -135,12 +135,25 @@ test_main (void) > > do_test (i, i, 256, 0); > > #endif > > } > > + for (i = 1; i < 8; ++i) > > + { > > + do_test (i, i << 5, 192, 23); > > + do_test (i, i << 5, 192, 0); > > + do_test (i, i << 5, 256, 23); > > + do_test (i, i << 5, 256, 0); > > + do_test (i, i << 5, 512, 23); > > + do_test (i, i << 5, 512, 0); > > + } > > for (i = 1; i < 32; ++i) > > { > > do_test (0, i, i + 1, 23); > > do_test (0, i, i + 1, 0); > > do_test (i, i, i + 1, 23); > > do_test (i, i, i + 1, 0); > > + do_test (0, i, i - 1, 23); > > + do_test (0, i, i - 1, 0); > > + do_test (i, i, i - 1, 23); > > + do_test (i, i, i - 1, 0); > > #ifdef USE_AS_MEMRCHR > > /* Also test the position close to the beginning for memrchr. */ > > do_test (0, 1, i + 1, 23); > > -- > > 2.29.2 > > > > LGTM. I will check it in for you. Thanks! > > BTW, can you apply an account on sourceware.org: > > https://sourceware.org/ > > so that you can push your commits directly? You can put me down > as your sponsor. Done. Are there any wikis / manuals on how to properly use write access? All I'm finding are resources on how to obtain it. > > Thanks. > > -- > H.J.
On Mon, May 3, 2021 at 12:52 PM Noah Goldstein <goldstein.w.n@gmail.com> wrote: > > On Mon, May 3, 2021 at 1:18 PM H.J. Lu <hjl.tools@gmail.com> wrote: > > > > On Mon, May 3, 2021 at 1:45 AM Noah Goldstein <goldstein.w.n@gmail.com> wrote: > > > > > > No bug. This commit adds some additional cases for bench-memchr.c > > > including testing medium sizes and testing short length with both an > > > inbound match and out of bound match. > > > > > > Signed-off-by: Noah Goldstein <goldstein.w.n@gmail.com> > > > --- > > > benchtests/bench-memchr.c | 13 +++++++++++++ > > > 1 file changed, 13 insertions(+) > > > > > > diff --git a/benchtests/bench-memchr.c b/benchtests/bench-memchr.c > > > index f5ced9d80d..5573f93312 100644 > > > --- a/benchtests/bench-memchr.c > > > +++ b/benchtests/bench-memchr.c > > > @@ -135,12 +135,25 @@ test_main (void) > > > do_test (i, i, 256, 0); > > > #endif > > > } > > > + for (i = 1; i < 8; ++i) > > > + { > > > + do_test (i, i << 5, 192, 23); > > > + do_test (i, i << 5, 192, 0); > > > + do_test (i, i << 5, 256, 23); > > > + do_test (i, i << 5, 256, 0); > > > + do_test (i, i << 5, 512, 23); > > > + do_test (i, i << 5, 512, 0); > > > + } > > > for (i = 1; i < 32; ++i) > > > { > > > do_test (0, i, i + 1, 23); > > > do_test (0, i, i + 1, 0); > > > do_test (i, i, i + 1, 23); > > > do_test (i, i, i + 1, 0); > > > + do_test (0, i, i - 1, 23); > > > + do_test (0, i, i - 1, 0); > > > + do_test (i, i, i - 1, 23); > > > + do_test (i, i, i - 1, 0); > > > #ifdef USE_AS_MEMRCHR > > > /* Also test the position close to the beginning for memrchr. */ > > > do_test (0, 1, i + 1, 23); > > > -- > > > 2.29.2 > > > > > > > LGTM. I will check it in for you. > > Thanks! > > > > > BTW, can you apply an account on sourceware.org: > > > > https://sourceware.org/ > > > > so that you can push your commits directly? You can put me down > > as your sponsor. > > Done. Are there any wikis / manuals on how to properly use write access? https://sourceware.org/glibc/wiki/HomePage has a lot of good information. > All I'm finding are resources on how to obtain it. > > > > > Thanks. > > > > -- > > H.J.
diff --git a/benchtests/bench-memchr.c b/benchtests/bench-memchr.c index f5ced9d80d..5573f93312 100644 --- a/benchtests/bench-memchr.c +++ b/benchtests/bench-memchr.c @@ -135,12 +135,25 @@ test_main (void) do_test (i, i, 256, 0); #endif } + for (i = 1; i < 8; ++i) + { + do_test (i, i << 5, 192, 23); + do_test (i, i << 5, 192, 0); + do_test (i, i << 5, 256, 23); + do_test (i, i << 5, 256, 0); + do_test (i, i << 5, 512, 23); + do_test (i, i << 5, 512, 0); + } for (i = 1; i < 32; ++i) { do_test (0, i, i + 1, 23); do_test (0, i, i + 1, 0); do_test (i, i, i + 1, 23); do_test (i, i, i + 1, 0); + do_test (0, i, i - 1, 23); + do_test (0, i, i - 1, 0); + do_test (i, i, i - 1, 23); + do_test (i, i, i - 1, 0); #ifdef USE_AS_MEMRCHR /* Also test the position close to the beginning for memrchr. */ do_test (0, 1, i + 1, 23);