Opened 18 years ago

Closed 18 years ago

#1420 closed enhancement (fixed)

speed-up DVB event parsing with caching of QTextCodecs

Reported by: janne-mythtv@… Owned by: danielk
Priority: minor Milestone: 0.20
Component: dvb Version: head
Severity: medium Keywords:
Cc: Ticket locked: no

Description

I profiled mythtv today and found a bottle neck in the DVB event parsing.

Without the patch dvb_decode_text() takes about 93% of SIParser::ParseTable. The patch drops this to 4%.

I'm not sure if the caching in a static patch is acceptable (in particular if it's threadsafe). But it is working fine for me.

refs #892

Attachments (2)

mythtv_codec_chaching.patch (1.6 KB) - added by janne-mythtv@… 18 years ago.
mythtv_codec_chaching2.patch (2.1 KB) - added by janne-mythtv@… 18 years ago.
updated patch, removed tabs and added check for array access, as suggested by ijr

Download all attachments as: .zip

Change History (6)

comment:1 Changed 18 years ago by anonymous

Type: defectenhancement

Changed 18 years ago by janne-mythtv@…

Attachment: mythtv_codec_chaching.patch added

Changed 18 years ago by janne-mythtv@…

updated patch, removed tabs and added check for array access, as suggested by ijr

comment:2 Changed 18 years ago by anonymous

Milestone: 0.20
Version: head

The statics probably won't work, but I'll make sure some caching of these is implemented in #1035.

comment:3 Changed 18 years ago by janne-mythtv@…

They actually work on a dual DVB backend. Valgrind doesn't complain.

But a different solution is fine by my.

comment:4 Changed 18 years ago by danielk

Resolution: fixed
Status: newclosed

(In [9220]) Closes #1420. QTextCodec caching.

Uses static QTextCodecs, which is safe with the toUnicode() call.

Note: See TracTickets for help on using tickets.