apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bill Stoddard" <b...@wstoddard.com>
Subject Re: cvs commit: apr-util/buckets apr_buckets_file.c
Date Thu, 05 Jul 2001 14:35:08 GMT
> PS: The common case for this segment of code is that the offset will be
> non-zero, since it reads in from a file in 8KB hunks, incrementing the
> offset each time.  So removing the conditional actually (very slightly)
> improves the performance of this section for the common case.  Only the
> case where offset == 0 might be negatively impacted.
>
> --Cliff

Maybe there is something very fundamental that I a missing here.  Each 8K chunk that is
read causes the system to increment its file pointer for that open fd. You should not need
to call seek() to do something the system is already doing for you under the covers.

Bill


Mime
View raw message