This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
Tom Tsou gerrit-no-reply at lists.osmocom.org
Patch Set 5:
(2 comments)
https://gerrit.osmocom.org/#/c/1337/5/src/viterbi.c
File src/viterbi.c:
PS5, Line 541: _cnt
Can get rid of this variable.
diff --git a/src/viterbi.c b/src/viterbi.c
index 9422575..06aae85 100644
--- a/src/viterbi.c
+++ b/src/viterbi.c
@@ -538,12 +538,12 @@ static int depuncture(const int8_t *in, const int *punc, int8_t *out, int len)
* accumulated path metric sums and path selections are stored. Normalize on
* the interval specified by the decoder.
*/
-static void _conv_decode(struct vdecoder *dec, const int8_t *seq, int _cnt)
+static void _conv_decode(struct vdecoder *dec, const int8_t *seq)
{
- int i, len = dec->len;
+ int i;
struct vtrellis *trellis = dec->trellis;
- for (i = 0; i < len; i++) {
+ for (i = 0; i < dec->len; i++) {
dec->metric_func(&seq[dec->n * i],
trellis->outputs,
trellis->sums,
@@ -571,10 +571,10 @@ static int conv_decode(struct vdecoder *dec, const int8_t *seq,
}
/* Propagate through the trellis with interval normalization */
- _conv_decode(dec, seq, cnt);
+ _conv_decode(dec, seq);
if (term == CONV_TERM_TAIL_BITING)
- _conv_decode(dec, seq, cnt);
+ _conv_decode(dec, seq);
return traceback(dec, out, term, len);
}
https://gerrit.osmocom.org/#/c/1337/5/src/viterbi_gen.c
File src/viterbi_gen.c:
PS5, Line 47:
Change > to >= in order to match existing implementation behavior.
diff --git a/src/viterbi_gen.c b/src/viterbi_gen.c
index 219b25b..7972c39 100644
--- a/src/viterbi_gen.c
+++ b/src/viterbi_gen.c
@@ -44,7 +44,7 @@ static void acs_butterfly(int state, int num_states,
sum2 = state0 - metric;
sum3 = state1 + metric;
- if (sum0 > sum1) {
+ if (sum0 >= sum1) {
*new_sum = sum0;
*path = -1;
} else {
@@ -52,7 +52,7 @@ static void acs_butterfly(int state, int num_states,
*path = 0;
}
- if (sum2 > sum3) {
+ if (sum2 >= sum3) {
*(new_sum + num_states / 2) = sum2;
*(path + num_states / 2) = -1;
} else {
--
To view, visit https://gerrit.osmocom.org/1337
To unsubscribe, visit https://gerrit.osmocom.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I74d355274b4176a7d924f91ef3c96912ce338fb2
Gerrit-PatchSet: 5
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Owner: Vadim Yanitskiy <axilirator at gmail.com>
Gerrit-Reviewer: Alexander Chemeris <Alexander.Chemeris at gmail.com>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Max <msuraev at sysmocom.de>
Gerrit-Reviewer: Tom Tsou <tom at tsou.cc>
Gerrit-Reviewer: Vadim Yanitskiy <axilirator at gmail.com>
Gerrit-Reviewer: tnt <tnt at 246tNt.com>
Gerrit-HasComments: Yes