From: Junio C Hamano <gitster@pobox.com>
To: Taylor Blau <me@ttaylorr.com>
Cc: git@vger.kernel.org, Jeff King <peff@peff.net>,
Derrick Stolee <stolee@gmail.com>
Subject: Re: [PATCH] t/perf: use 'test_file_size' in more places
Date: Fri, 22 Nov 2024 09:47:03 +0900 [thread overview]
Message-ID: <xmqqed34dri0.fsf@gitster.g> (raw)
In-Reply-To: <50c1368630684f235548d2e9a68d4de3745b5fe6.1732220875.git.me@ttaylorr.com> (Taylor Blau's message of "Thu, 21 Nov 2024 15:29:24 -0500")
Taylor Blau <me@ttaylorr.com> writes:
> The perf test suite prefers to use test_file_size over 'wc -c' when
> inside of a test_size block. One advantage is that accidentally writign
> "wc -c file" (instead of "wc -c <file") does not inadvertently break the
> tests (since the former will include the filename in the output of wc).
Another advantage is, instead of reading through the file and
counting bytes, the helper uses stat() without reading. For a
performance test that potentially deals with a large-ish file, it
probably counts (pun intended) more.
Will queue. Thanks.
next prev parent reply other threads:[~2024-11-22 0:47 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-21 20:29 [PATCH] t/perf: use 'test_file_size' in more places Taylor Blau
2024-11-22 0:47 ` Junio C Hamano [this message]
2024-11-22 8:28 ` Jeff King
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=xmqqed34dri0.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=me@ttaylorr.com \
--cc=peff@peff.net \
--cc=stolee@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox