Rockbox mail archiveSubject: Re: A nasty inefficieny in file.c?
Re: A nasty inefficieny in file.c?
From: Jens Arnold <arnold-j_at_t-online.de>
Date: Fri, 14 Jul 2006 08:13:08 +0200
On 14.07.2006, Jens Arnold wrote:
> On 14.07.2006, postmaster_at_diffenbach.org wrote:
>> Jens Arnold wrote:
>>> For this purpose, file.c caches up to one sector worth of
>>> data. "headbytes" is any new data that fits into the sector
>>> cache when it's already dirty.
>> That implies thst the file is being /written/ to disk? What's
>> being written when I'm just listening to music?
> Hmm, my description was a little imprecise. readwrite() is
> used for both reading and writing, ...
> So, if a file is read or written in single-byte calls,
> there'll be 1x one tail byte and 511x one head byte for each
> 512 bytes of data. Very inefficient.
Are you listening to mp3? Iirc Slasheri said that the id3
parser is one such example of inefficiency as it reads
Received on 2006-07-14