This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

[参考译文] TMS320F28377S:TMU 是否支持 float64除法

Guru**** 2478765 points


请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

https://e2e.ti.com/support/microcontrollers/c2000-microcontrollers-group/c2000/f/c2000-microcontrollers-forum/715448/tms320f28377s-whether-tmu-support-float64-divide

器件型号:TMS320F28377S

您好 C2000团队

我的客户希望确认 TMU 是否支持 float64除法、例如:

__DIV32 (float64 a、float64 b)?

客户表示结果是正确的、我查看了数据表、其中有详细的描述:

double __divf32 (double num,double denom);DIVF32 dstnumdenom 返回使用 TMU 除以 denom 的 num
浮点除法的硬件指令。

请提供您的意见。

谢谢!

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。
    您好!

    __DIV32 (float64 a、float64 b)结果看起来是正确的,因为编译器隐式地将 float64参数转换为双精度型(C28xx 上的 double 为32位)。 结果是正确的、但精度仅为单精度、而不是客户期望的双精度。 让他试一下1.0 / 3.0、看看他看到的是什么、~0.33333334或~0.3333333333333333333333331。

    TMU 和 FPU 仅支持单精度 FP 数字(浮点数和双精度)、双精度 FP (长双精度和浮点数64)在软件中完成。

    Edward
  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    作为 Ek、在 F28377x 和 F2804x 上重放 TMU 仅为单精度。