mirror of
https://github.com/aicodix/code.git
synced 2026-04-27 22:35:44 +00:00
keep locations sorted by offset per layer
This commit is contained in:
parent
02d5b5f12c
commit
488a8cbe2b
2 changed files with 2 additions and 0 deletions
|
|
@ -160,6 +160,7 @@ class LDPCDecoder
|
||||||
lo[c].shi = shift[c] / W;
|
lo[c].shi = shift[c] / W;
|
||||||
shift[c] = (shift[c] + 1) % M;
|
shift[c] = (shift[c] + 1) % M;
|
||||||
}
|
}
|
||||||
|
std::sort(lo, lo + cnt, [](const Loc &a, const Loc &b){ return a.off < b.off; });
|
||||||
TYPE par[2];
|
TYPE par[2];
|
||||||
if (i) {
|
if (i) {
|
||||||
par[0] = pty[W*(i-1)+j];
|
par[0] = pty[W*(i-1)+j];
|
||||||
|
|
|
||||||
|
|
@ -223,6 +223,7 @@ public:
|
||||||
lo[c].shi = shift[c] / W;
|
lo[c].shi = shift[c] / W;
|
||||||
shift[c] = (shift[c] + 1) % M;
|
shift[c] = (shift[c] + 1) % M;
|
||||||
}
|
}
|
||||||
|
std::sort(lo, lo + cnt, [](const Loc &a, const Loc &b){ return a.off < b.off; });
|
||||||
lo += cnt;
|
lo += cnt;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue