This is the mail archive of the
mailing list for the glibc project.
Re: printing length in benchtests
- From: Rajalakshmi Srinivasaraghavan <raji at linux dot vnet dot ibm dot com>
- To: Siddhesh Poyarekar <siddhesh at redhat dot com>
- Cc: libc-alpha <libc-alpha at sourceware dot org>
- Date: Thu, 06 Feb 2014 22:10:40 +0530
- Subject: Re: printing length in benchtests
- Authentication-results: sourceware.org; auth=none
- References: <52F3B592 dot 9070103 at linux dot vnet dot ibm dot com> <20140206163330 dot GL26862 at spoyarek dot pnq dot redhat dot com>
On 02/06/2014 10:03 PM, Siddhesh Poyarekar wrote:
On Thu, Feb 06, 2014 at 09:47:22PM +0530, Rajalakshmi Srinivasaraghavan wrote:
Should we print len instead of pos in the following 4 benchtests to
interpret the output better?
Why would it be better? When there is a match, it is the match
position that determines the exit from these functions. The length
comes into the picture when there is no match.
So both would be useful to have in different cases IMO.
I looked at strrchr,we exit once we hit null even after crossing the pos.
So atleast for such functions, it would be better to change.