【发布时间】:2018-06-23 14:22:56
【问题描述】:
我正在尝试了解 GNURadio 中的浮点运算并开始研究他们的测试。测试生成随机浮点输入和随机抽头,然后将所有内容传递给过滤器。稍后它会使用一些边距比较预期输出和实际输出。
有一条关于margin的神秘评论:
// we use a sloppy error margin because on the x86 architecture,
// our reference implementation is using 80 bit floating point
// arithmetic, while the SSE version is using 32 bit float point
// arithmetic.
我在源代码中找不到任何 80 位算术。谁能帮我?或者只是解释为什么误差范围取决于抽头大小?
【问题讨论】:
-
我相信 x87 浮点架构的内部精度是 80 位 - 请参阅 en.wikipedia.org/wiki/…。
-
@OliverCharlesworth:一些 (Win32) 编译器也允许您使用扩展(80 位)精度,如
long double。
标签: c++ floating-point gnuradio