From: Uwe Hermann Date: Mon, 6 Mar 2017 07:41:42 +0000 (+0100) Subject: Increase decoding chunk size for much better performance. X-Git-Tag: pulseview-0.4.0~176 X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=4e6301f9744f2c97b6ee7982ba56903f63cc455e;p=pulseview.git Increase decoding chunk size for much better performance. Increasing the (max) decoding chunk size from 4ksamples to 10Msamples leads to massively faster protocol decoding due to reduced overhead related to srd_session_send() and other functions invoked internally. In some cases a 2x (or more) speed-up has been observed. --- diff --git a/pv/data/decoderstack.cpp b/pv/data/decoderstack.cpp index c5a0e4a7..c216d8d2 100644 --- a/pv/data/decoderstack.cpp +++ b/pv/data/decoderstack.cpp @@ -53,7 +53,7 @@ namespace data { const double DecoderStack::DecodeMargin = 1.0; const double DecoderStack::DecodeThreshold = 0.2; -const int64_t DecoderStack::DecodeChunkLength = 4096; +const int64_t DecoderStack::DecodeChunkLength = 10 * 1024 * 1024; const unsigned int DecoderStack::DecodeNotifyPeriod = 1024; mutex DecoderStack::global_srd_mutex_;