summaryrefslogtreecommitdiff
path: root/gr-digital/lib
Commit message (Collapse)AuthorAgeFilesLines
...
* digital/header: Remove manual memory managementThomas Habets2020-08-143-22/+15
|
* digital/glfsr_source: Remove manual memory managementThomas Habets2020-08-144-16/+10
|
* digital/corr_est: Remove manual memory managementThomas Habets2020-08-142-29/+20
|
* digital/clock_recovery_mm: Remove manual memory managementThomas Habets2020-08-144-19/+16
|
* digital/symbol_sync: Remove manual memory managementThomas Habets2020-08-148-151/+118
| | | | | | | | | | | | | The `cc` version already used more smart pointers, but `d_clock` didn't need to be a pointer at all. I consted function args to make it clear in the initializer that they will not be changed in the constructor body. Return value for `make` for the TED and interpolator was changed to a `unique_ptr` to make it clear that ownership is transferred. And it makes it all but impossible to accidentally memory leak. (core guidelines F.26. Also relevant I.11,R.20).
* digital/interpolating_resampler: Remove manual memory managementThomas Habets2020-08-142-118/+59
|
* digital/pn_correlator: Remove manual memory managementThomas Habets2020-08-142-10/+8
|
* Replace all calls to `get_initial_sptr` with `make_block_sptr`Thomas Habets2020-07-3061-162/+153
| | | | | | | | | | | | | | First batch of changes: ``` find […] -print0 | xargs -0 sed -i -r '/get_initial_sptr/{:nxt N;/;/!b nxt;s/get_initial_sptr\(\s*new ([^(]+)(.*)\)\)/make_block_sptr<\1>\2)/}' ``` Then: * Back out `sptr_magic.h` edits * Change some `friend` clauses * clang-format the whole thing * Update checksums in the pybind11 bindings files
* msg_handler: Use lambdas in most componentsJohannes Demel2020-06-046-18/+12
| | | | | With this commit, all components except gr-qtgui use lambdas instead of `boost::bind` to register msg handlers.
* digital: replace stderr logging by calls to GR's logging faciltiesMarcus Müller2020-04-132-44/+36
| | | | | | | | This is a bit special: it should be worked out whether these `if(VERBOSE)` statements shouldn't simply be removed in face of the (anyways conditionally #defined-away) `GR_LOG_INFO`. For now, this gets the job done of centralizing logging.
* Remove VOLK as a submoduleMartin Braun2020-04-111-1/+1
| | | | | | | | | | | | | | This removes the volk/ submodule pointer and updates the CMake to detect VOLK like any other dependency. The VOLK_MIN_VERSION CMake variable is added (and set to 2.1.0). The GR_VOLK_LIB variable is replaced with Volk::volk everywhere. The VOLK_INSTALL_LIBRARY_DIR and VOLK_INSTALL_INCLUDE_DIR variables weren't used and were removed. CMake will now fail if VOLK cannot be detected. Therefore, ENABLE_VOLK was also removed as a variable; all in-tree components may assume the existence of VOLK.
* boost: remove deprecated math/common_factor.hppjapm482020-04-112-4/+4
| | | | | Remove deprecation warning and prefer using std::{lcm,gcd} to Boost. Fixes #2712.
* digital: restructure equalizers and add dfe (#3306)mormj2020-04-099-0/+806
| | | | | | | | | | | | | | | | | | * digital: restructure equalizers and add dfe This commit restructures the linear equalizer to have a separate specifiable adaptive algorithm. Generally this works the same as the previous LMS and CMA decision directed equalizers, but also adds the ability to equalize using training sequences as well. Also, a Decision Feedback Equalizer structure is added * digital: more const in equalizers * digital: equalizers - more safety based on review * digital: dfe - use deque instead of vector for decision_history * digital - equalizers, further cleanup
* gr-digital: Improve PLL Loops and Clock Recoveryghostop142020-02-156-87/+76
| | | | | | | These updates incorporate the same inlining of loop functions and the newly pushed fast_cc_multiply function to ensure consistent performance improvements across systems that do not support the cx-limited-range compiler parameter (Macs and Windows).
* runtime/math: unclutter GR_M_ math constant definesMarcus Müller2020-02-142-4/+4
| | | | | | * no speed advantage of GR_M_TWOPI: every compiler pre-computes constants, so that (2 * GR_M_PI) is just as fast * rest of constants not even used
* gr-digital: Improve Performance of Costas Loopghostop142020-02-142-115/+105
| | | | | | | | | | | | | This update is focused on improving the throughput of the Costas loop, however some changes are more global performance enhancements as this PR has evolved. Updates include an ENABLE_NATIVE added to CMake, which is off by default but enables native compiling (including FMA support) if desired; sincos was inlined in sincos.h and sincos.cc was removed from the appropriate CMake to improve sincos speed, some constants were added to math.h, inlined functions in costas loop and nco.h, used switch instead of function pointer (much faster), and used fast complex multiply to get around all the range checking in the standard complex.h complex multiply function on all builds.
* Update license header to SPDX formatdevnulling2020-01-27142-1846/+142
|
* gr-digital: Remove unused private variable and -Wsign-compare warnings.Ron Economos2020-01-274-5/+3
|
* gr-digital: fix undefined behaviourValerii Zapodovnikov2020-01-261-1/+2
| | | A variable is used several times between two sequence points
* gr-digital: cleanup double assignmentsValerii Zapodovnikov2020-01-241-7/+3
| | | and change one variable to bool
* gr-digital: no need in new operator NULL checksValerii Zapodovnikov2020-01-241-31/+0
| | | There is no sense in testing these pointers against null, as the memory was allocated using the 'new' operator. The exception will be generated in the case of memory allocation error.
* digital/constellation: Always initialize d_scalefactorThomas Habets2020-01-201-0/+1
| | | | Found by coverity. CID 1398481
* digital: Remove deprecated OFDM blocksMartin Braun2020-01-1610-1627/+0
| | | | | | | | | | | | | | | These blocks have been marked deprecated for a while and had been slated for removal. They are now being removed. This includes the following blocks: - ofdm_frame_acquisition - ofdm_frame_sink - ofdm_insert_preamble - ofdm_sync_fixed - ofdm_sync_pn - ofdm_sync_pnac - ofdm_sync_ml - ofdm_receiver
* Fix all formatting issuesMartin Braun2020-01-107-51/+51
| | | | | This fixes every leftover file in the GNU Radio source tree to match our clang-format definition.
* gr-digital/costas_loop: use std::norm for |z|^2japm482020-01-091-3/+3
|
* digital: ofdm: Allow multiple CP lengths for cyclic prefixerMaximilian Stiefel2020-01-082-64/+127
| | | | | | | | This allows to specify multiple CP lengths that can be used one after another, for example for LTE modulators. - Improve sanity checking - Maintains old API
* gr-digital/costas_loop: |z|*|z| -> z*conj(z)Thomas Habets2020-01-061-3/+3
|
* gr-digital: Replace double math funcs with float versionsThomas Habets2020-01-062-3/+3
|
* Change some ints to unsigned intThomas Habets2020-01-063-7/+7
|
* gr-digital/constellation_decoder: Add constThomas Habets2020-01-062-3/+3
|
* gr-digital/symbol_sync: More constThomas Habets2020-01-064-24/+24
|
* gr-digital: Add more constThomas Habets2020-01-0611-51/+45
|
* gr-digital/chunks_to_symbols: Simplify helper functionsThomas Habets2020-01-062-24/+17
|
* digital: pfb clock sync: Remove deprecated set_taps() API callMartin Braun2020-01-062-8/+8
| | | | | | | This API call was deprecated a long time ago and contained a warning that it will be removed, so we're now being true to our promise. This also fixes a compiler error in SWIG *if* you have old headers installed that SWIG will find (instead of the ones in the source tree).
* Replace many `const` variables with `constexpr`Thomas Habets2020-01-045-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | constexpr is like const but (for variables) guarantees evaluation at compile time (as opposed to runtime). Likely this change will do nothing on its own (though it could, since it gives the compiler more information). But it still has benefits. It allows programmer to know that initialization is not expensive (it was done at compile time), and reduces risk of a refactoring regressing the compiletimeness. Runtime initialization can be nonobvious in larger codebases. E.g.: struct S { static int foo(); }; const int bar = S::foo(); // Called and initialized at *runtime*. int S::foo() { return 10; } With constexpr: struct S { static constexpr int foo(); }; constexpr int bar = S::foo(); // Error: used before definition. constexpr int S::foo() { return 10; } Initializing at runtime is not just startup costs, but also can save memory since it'll end up in a R/O section of a binary and therefore doesn't need to be swapped out, but can be shared (in the mmap() sense of the word).
* additive_scrambler: Fix count based resetrear10192020-01-031-27/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Count based reset in the additive scrambler may be delayed by a single byte as reported in [1]. This happens whenever the work() function of the block is called: The first value of reset_index in work() is d_count - d_bytes where d_count is the number of bytes to output before a reset and d_bytes is the number of bytes produced after a previous reset (in the previous work() call). The very first reset is delayed by one byte due to zero-based counting in work()’s loop /and/ a check of the reset condition (i == reset_index) /after/ outputting a byte. (All following resets are performed at the correct interval after 4 bytes.) Example: With d_count = 4 and d_bytes = 0 the first reset is performed at i = 4, but only after a fifth byte has been output. Fix this error by checking the reset condition /before/ outputting a byte. This removes different handling of tag and count based reset, introduced by commit e3ad82e6d9 as a fix for delayed tag based reset [2]. The fix for tag based reset should have been applied to the count based reset as well (resulting in the same code as of this commit). The error in count based reset has not been detected due to wrong QA code (see previous commit). Fixes #2926. [1] https://github.com/gnuradio/gnuradio/issues/2926 [2] https://github.com/gnuradio/gnuradio/issues/1198
* gr-digital/map_bb: Make .map() thread safeThomas Habets2020-01-032-1/+2
|
* digital/map_bb: Fix buffer overflowThomas Habets2020-01-032-5/+8
|
* gr-digital: Remove needless type trickeryThomas Habets2020-01-023-18/+6
|
* gr-digital/symbol_sync: Remove needless memory managementThomas Habets2020-01-022-20/+10
|
* gr-digital: Modernize C++Thomas Habets2020-01-023-19/+10
|
* gr-digital/fll_band_edge: Modernize C++Thomas Habets2020-01-022-15/+6
|
* Remove newlines from exception messagesThomas Habets2020-01-014-12/+12
|
* Use C++11 ranged for and ranged insert instead of manual loopsThomas Habets2019-12-042-9/+7
|
* Use 'const' on more member variablesThomas Habets2019-12-041-1/+1
|
* delete unused variablesBastian Bloessl2019-09-051-1/+0
|
* Fix memset clearing non-trivial type gr_complex warnings in gcc-8Anders Kalør2019-08-221-2/+3
| | | | | | | | Using memset with gr_complex is not a problem since the underlying representation of gr_complex is guaranteed to be two floats in adjacent memory locations without padding or additional memory. Fixes #2743
* clang-tidy in gnuradio-runtime: use empty() instead of size()!=0Marcus Müller2019-08-228-14/+14
|
* Use emplace_back(params) instead of push_back(type(params))Marcus Müller2019-08-221-5/+3
| | | | | | | | | | | | | | | | | | | This is C++11: you can convert std::vector<complextype> vec; vec.push_back(complextype(foo, bar, baz)); by std::vector<complextype> vec; vec.emplace_back(foo, bar, baz); which saves one unnecessary copy. This mostly happened in rpc code. The automated clang-tidy check failed miserably, so most of this was done by hand.
* clang-format: Ordering all the includesMarcus Müller2019-08-0964-109/+109
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | clang-format: ordering includes in gnuradio-runtime clang-format: ordering includes in gr-filter clang-format: ordering includes in gr-fft clang-format: ordering includes in gr-audio clang-format: ordering includes in gr-analog clang-format: ordering includes in gr-fec clang-format: ordering includes in gr-wavelet clang-format: ordering includes in gr-zeromq clang-format: ordering includes in gr-vocoder clang-format: ordering includes in gr-video-sdl clang-format: ordering includes in gr-trellis clang-format: ordering includes in gr-blocks clang-format: ordering includes in gr-digital clang-format: ordering includes in gr-uhd clang-format: ordering includes in gr-dtv clang-format: ordering includes in gr-channels clang-format: ordering includes in gr-qtgui clang_format.py: re-enable include reordering