Mailing List archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[vdr] Re: Bug in EIT parser.. this is the fix!!



Guido Fiala wrote:
> 
> On Tuesday, 29. January 2002 21:59, you wrote:
> > Deti Fliegl wrote:
> > ...
> >
> > > Please replace the definition line by
> > >
> > >    int                SectionLength, LoopLength;
> > >
> > > and vdr should work.
> >
> > Yes!
> > Wonderful, Deti!
> > Many thanks!
> >
> > Actually, the same bug occurs four times in  si_parser.c.
> > Here is the patch I applied to my vdr:
> >
> 
> Seems to help, but also it increses sysload to 10% so long Pro7 or Kabel1 is displayed (only 0.1% on other channels).

Have you tried it with the latest patch at

  ftp://ftp.cadsoft.de/pub/people/kls/vdr/vdr-0.99pre3-epgfix.diff

> 
> I used gprof to find out why:
> 
> Most time is spent in cBitmap::Fill and cBitmap::Text  (although no OSD/key-activity) - it seems, that these functions are called so long until the EIT/OSD information
> of the "current/next"-field changes, not only as they are actually used=displayed.
> Inside the Fill() it's mainly the SetIndex() function that matters, inlining it and optimize it would help otherwhere too.
> Also the 2,5 million strreplace's (vdr was running just some minutes) indicate some problems with EIT.

VDR does a lot of string processing to fix the bugs in the EPG data
transmitted from the TV stations, so I guess that's what's causing this.

Klaus

> What i could'nt interpret is, that the cummulative seconds below show only 0.23 sec, although "top" said vdr has eaten up 10 seconds.
> Can someone explain it?
> 
> $>gprof /usr/local/bin/vdr
> Flat profile:
> 
> Each sample counts as 0.01 seconds.
>   %   cumulative   self              self     total
>  time   seconds   seconds    calls  us/call  us/call  name
>  69.57      0.16     0.16      147  1088.44  1088.44  cBitmap::Fill(int, int, in
>  26.09      0.22     0.06      227   264.32   264.32  cBitmap::Text(int, int, ch
>   4.35      0.23     0.01     7650     1.31     1.31  cTimer::Matches(long)
>   0.00      0.23     0.00  2568648     0.00     0.00  strreplace(char *, char, c
>   0.00      0.23     0.00  1284291     0.00     0.00  compactspace(char *)
>   0.00      0.23     0.00  1284291     0.00     0.00  strcpyrealloc(char *, char
>   0.00      0.23     0.00   615551     0.00     0.00  cMutex::Unlock(void)
>   0.00      0.23     0.00   615550     0.00     0.00  cMutex::Lock(void)
>   0.00      0.23     0.00   614296     0.00     0.00  safe_read(int, void *, uns
>   0.00      0.23     0.00   428097     0.00     0.00  cEventInfo::FixEpgBugs(voi
>   0.00      0.23     0.00   428097     0.00     0.00  cEIT::IsPresentFollowing(v
>   0.00      0.23     0.00   310487     0.00     0.00  cThreadLock::Lock(cThread
>   0.00      0.23     0.00   308684     0.00     0.00  cThreadLock::~cThreadLock(
>   0.00      0.23     0.00   308683     0.00     0.00  cThreadLock::cThreadLock(c
>   0.00      0.23     0.00   306865     0.00     0.00  cEIT::ProcessEIT(unsigned
>   0.00      0.23     0.00     9042     0.00     0.00  isempty(char const *)
>   0.00      0.23     0.00     5521     0.00     0.00  cInterface::Flush(void)
>   0.00      0.23     0.00     4871     0.00     0.00  cListBase::Add(cListObject
>   0.00      0.23     0.00     4871     0.00     0.00  cListObject::~cListObject(
>   0.00      0.23     0.00     4871     0.00     0.00  cListObject::cListObject(v
>   0.00      0.23     0.00     4756     0.00     0.00  cBitmap::Dirty(int &, int
>   0.00      0.23     0.00     4703     0.00     0.00  cEventInfo::~cEventInfo(vo
>   0.00      0.23     0.00     4566     0.00     0.00  cFile::AnyFileReady(int, i
>   0.00      0.23     0.00     3996     0.00     0.00  cDvbApi::Flush(void)
>   0.00      0.23     0.00     3996     0.00     0.00  cDvbOsd::Flush(void)
>   0.00      0.23     0.00     3706     0.00     0.00  startswith(char const *, c
>   0.00      0.23     0.00     3532     0.00     0.00  cEventInfo::GetSubtitle(vo
>   0.00      0.23     0.00     3532     0.00     0.00  cEventInfo::GetTitle(void)
>   0.00      0.23     0.00     2768     0.00     0.00  cInterface::GetKey(bool)
>   0.00      0.23     0.00     2768     0.00     0.00  cSVDRP::Process(void)
>   0.00      0.23     0.00     2759     0.00     0.00  cThread::EmergencyExit(boo
>   0.00      0.23     0.00     2745     0.00     0.00  cRcIoBase::InputAvailable(
>   0.00      0.23     0.00     2743     0.00     0.00  cRcIoBase::GetCommand(unsi
>   0.00      0.23     0.00     2743     0.00     0.00  cKeys::Get(unsigned int)
>   0.00      0.23     0.00     1821     0.00     0.00  cFile::Ready(bool)
>   0.00      0.23     0.00     1817     0.00     0.00  time_ms(void)
>   0.00      0.23     0.00     1805     0.00     0.00  cSchedule::GetFollowingEve
>   0.00      0.23     0.00     1805     0.00     0.00  cSchedule::GetPresentEvent
>   0.00      0.23     0.00     1805     0.00     0.00  cSchedules::GetSchedule(vo
>   0.00      0.23     0.00     1804     0.00     9.35  cDisplayChannel::DisplayIn
>   0.00      0.23     0.00     1804     0.00     9.32  cDisplayChannel::ProcessKe
> ...

-- 
_______________________________________________________________

Klaus Schmidinger                       Phone: +49-8635-6989-10
CadSoft Computer GmbH                   Fax:   +49-8635-6989-40
Hofmark 2                               Email:   kls@cadsoft.de
D-84568 Pleiskirchen, Germany           URL:     www.cadsoft.de
_______________________________________________________________



Home | Main Index | Thread Index