summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMatthias P. Braendli <matthias.braendli@mpb.li>2015-08-17 20:50:06 +0200
committerMatthias P. Braendli <matthias.braendli@mpb.li>2015-08-17 20:50:06 +0200
commit15902d31f5a723db28664c986fbfc352bdb3a5ab (patch)
treeb51a8abd80d3dde0d7aaf425ef294cf9de2ad708 /src
parent1dbc8cb2580fcc1ab3446b0862f09c6daba0f7b9 (diff)
downloaddabmux-15902d31f5a723db28664c986fbfc352bdb3a5ab.tar.gz
dabmux-15902d31f5a723db28664c986fbfc352bdb3a5ab.tar.bz2
dabmux-15902d31f5a723db28664c986fbfc352bdb3a5ab.zip
Use references in FIG deadline reduction loop
Diffstat (limited to 'src')
-rw-r--r--src/fig/FIGCarousel.cpp17
1 files changed, 6 insertions, 11 deletions
diff --git a/src/fig/FIGCarousel.cpp b/src/fig/FIGCarousel.cpp
index 106e78e..2d09ade 100644
--- a/src/fig/FIGCarousel.cpp
+++ b/src/fig/FIGCarousel.cpp
@@ -141,9 +141,13 @@ size_t FIGCarousel::write_fibs(
{
/* Decrement all deadlines of all figs */
for (auto& fib_fig : m_fibs) {
- auto fig = fib_fig.second;
- for (auto fig_el : fig) {
+ auto& fig = fib_fig.second;
+ for (auto& fig_el : fig) {
fig_el.reduce_deadline();
+#if CAROUSELDEBUG
+ std::cerr << " * " << fig_el.fig->name() <<
+ " d:" << fig_el.deadline << std::endl;
+#endif
}
}
@@ -213,15 +217,6 @@ size_t FIGCarousel::carousel(
return left->deadline < right->deadline;
});
-#if CAROUSELDEBUG
- // Carousel debugging help
- std::cerr << " ***** Sorted figs in FIB" << fib << ":" << std::endl;
- for (auto& fig_el : sorted_figs) {
- std::cerr << " " << fig_el->fig->name() <<
- " d:" << fig_el->deadline << std::endl;
- }
-#endif
-
/* Data structure to carry FIB */
size_t available_size = bufsize;