[haiku-development] Re: Scheduler algorithm improvements

  • From: "Axel Dörfler" <axeld@xxxxxxxxxxxxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Mon, 16 Nov 2009 11:40:36 +0100

Stephan Assmus <superstippi@xxxxxx> wrote:
> These threads you mention above should indeed get a higher 
> priority. Event queue runner and playback manager are timing threads.

So what priority should they have? Are they computational intensive, or 
should they get really high priorities for exact timing?

> The 
> Extractor thread should, IMHO, not really be so important, but what I 
> noticed is that many media readers work with *very* small read-
> buffers. You 
> can see this with the MP3 reader for example, if you playback an MP3, 
> you 
> can see te harddrive LED flash all the time, because it reads so tiny 
> chunks. I don't really see the philosophy behind this, maybe Marcus 
> can 
> explain.
> The "ChunkReader" is supposed to read chunks from media files 
> ahead. It does a read-ahead of four chunks in advance, if memory 
> serves. 

Why not simply let ChunkReader take the chunk size into account, and 
buffer much more in general?

> Additionally, MediaPlayer does it's own read-ahead buffering for 
> audio, 
> always up to the next seekable audio keyframe/chunk.

And that is refilled when you reach the keyframe? (so you are at least 
one key frame ahead?)

Bye,
   Axel.


Other related posts: