mirror of
https://github.com/aicodix/code.git
synced 2026-04-27 22:35:44 +00:00
step pointers after updating at the end
This commit is contained in:
parent
65dd0fab50
commit
a61a7d05cf
2 changed files with 8 additions and 4 deletions
|
|
@ -169,7 +169,7 @@ class LDPCDecoder
|
|||
for (int d = 0; d < deg; ++d)
|
||||
out[d] = selfcorr(bl[d], out[d]);
|
||||
for (int d = 0; d < deg; ++d)
|
||||
*bl++ = out[d];
|
||||
bl[d] = out[d];
|
||||
for (int c = 0; c < cnt; ++c)
|
||||
mes[c] = vqadd(inp[c], out[c]);
|
||||
par[0] = vqadd(inp[cnt], out[cnt]);
|
||||
|
|
@ -187,6 +187,7 @@ class LDPCDecoder
|
|||
msg[of[c]] = rotate(mes[c], sh[c]);
|
||||
of += cnt;
|
||||
sh += cnt;
|
||||
bl += deg;
|
||||
}
|
||||
}
|
||||
//assert(bl <= bnl + BNL);
|
||||
|
|
@ -223,10 +224,12 @@ public:
|
|||
}
|
||||
for (int j = 0; j < W; ++j) {
|
||||
for (int c = 0; c < cnt; ++c) {
|
||||
*of++ = offset[c] / D + shift[c] % W;
|
||||
*sh++ = shift[c] / W;
|
||||
of[c] = offset[c] / D + shift[c] % W;
|
||||
sh[c] = shift[c] / W;
|
||||
shift[c] = (shift[c] + 1) % M;
|
||||
}
|
||||
of += cnt;
|
||||
sh += cnt;
|
||||
}
|
||||
}
|
||||
//assert(of <= off + POS);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue