aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/convert/convert_unpack_sc12.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Move all license headers to SPDX format.Martin Braun2017-12-221-12/+1
|
* convert: Add SSE implementation for sc12Tom Tsou2017-07-251-97/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Implementation uses SSSE3 intructions to perform 12-bit sample pack/unpack operations to/from standard 16 and 32 bit host values. Input/output shuffle orderings for a single 128-bit SSE register with 16-bit integers shown below. 16-bit interleaved I/Q --------------------------------------- | Q3 | I3 | Q2 | I2 | Q1 | I1 | Q0 | I0 | Input --------------------------------------- | 127 0 | 12-bit packed I/Q byteswapped ----------------------- | I0 | Q0 | I1 | 0 |-----------------------| | I1 | Q1 | I2 | Q2 | Output |-----------------------| | Q2 | I3 | Q3 | |-----------------------| | Unused | 3 ----------------------- 31 0 Fixes: #1740, #966 Related: #1739
* convert: Add sc12-sc16 convertersTom Tsou2017-07-181-4/+46
| | | | | | | | | | | | | | | | | Create missing sc12-sc16 and sc16-sc12 type converters. To avoid replicating the full sc12 converter class object, overload the converter calls with C++11 std::enable_if metafunctions. When used with std::is_floating and std::is_integral templates, this allow a single template interface with compile time function selection and static type checking. Note the below std::enable_if interface is confusing, but quite effective in this case. typename enable_if<is_floating_point<type>::value>::type* = NULL Fixes: #966 Related: #967, #1721
* utils: introduce new logging API and remove msg APIAndrej Rode2017-02-201-1/+1
|
* Remove all boost:: namespace prefix for uint32_t, int32_t etc. (fixed-width ↵Martin Braun2016-11-081-11/+11
| | | | | | | | types) - Also removes all references to boost/cstdint.hpp and replaces it with stdint.h (The 'correct' replacement would be <cstdint>, but not all of our compilers support that).
* converters: Clarifying comment re packingMartin Braun2016-06-221-0/+5
|
* convert: Fix sc12 unpack shiftingTom Tsou2015-01-121-8/+8
| | | | | | | | | | | | Resolve issue #666 "B200: Rx signal distortion when using SC12". During 12-bit unpacking, OTW samples are shifted into the high order bits of the 16-bit intermediate values. The remaining 4-bits are not zeroed and contain bits from adjacent samples. Consequently, signal distortion becomes noticable with spurs and other random signal garbage when operating at low signal levels. Signed-off-by: Tom Tsou <tom@tsou.cc>
* Squashed merge of Coverity fixes.Ben Hilburn2013-11-271-1/+1
|
* sc12: fixed byte alignment issueJohannes Demel2013-11-191-4/+57
|
* convert: added sc12 and fc32 convertersJosh Blum2013-08-281-0/+152