From 95ac58a5a2dabef619865720e9b3f6a20941a252 Mon Sep 17 00:00:00 2001 From: Martin Braun Date: Thu, 21 Jun 2012 22:45:29 -0400 Subject: core: tiny performance boost, and it looks tidier. --- gnuradio-core/src/lib/gengen/gr_sig_source_X.cc.t | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'gnuradio-core/src/lib/gengen') diff --git a/gnuradio-core/src/lib/gengen/gr_sig_source_X.cc.t b/gnuradio-core/src/lib/gengen/gr_sig_source_X.cc.t index bdd0e810a..6959eac82 100644 --- a/gnuradio-core/src/lib/gengen/gr_sig_source_X.cc.t +++ b/gnuradio-core/src/lib/gengen/gr_sig_source_X.cc.t @@ -29,6 +29,7 @@ #include #include #include +#include #include @@ -64,8 +65,7 @@ int case GR_CONST_WAVE: t = (gr_complex) d_ampl + d_offset; - for (int i = 0; i < noutput_items; i++) // FIXME unroll - optr[i] = t; + std::fill_n(optr, noutput_items, t); break; case GR_SIN_WAVE: @@ -142,8 +142,7 @@ int case GR_CONST_WAVE: t = (@TYPE@) d_ampl + d_offset; - for (int i = 0; i < noutput_items; i++) // FIXME unroll - optr[i] = t; + std::fill_n(optr, noutput_items, t); break; case GR_SIN_WAVE: -- cgit