将 mpfr_t (或任何其他任意精度库类型)转换为 __float128
我想我真的有两个问题。
1)我想知道是否有人知道在GCC中将mpfr_t类型转换为__float128类型的方法。我环顾四周,在 mpfr bugfixes 网站上发现了一个线程,其中有人讨论了他们尝试编写从 __float128 到 mpfr_t 的转换器,但它似乎在去年的某个时候已经消失了。
2) 如果没有人知道将 mpfr_t 转换为 __float128 的方法,是否有人知道另一个可以实现的任意精度 C/C++ 库?
谢谢
I guess I have two questions really.
1) I was wondering if anyone knows a way to convert mpfr_t types into __float128 types in GCC. I've looked around and found a thread on the mpfr bugfixes site where someone discusses their attempt to write a converter from __float128 to mpfr_t, but it seems to have dropped off sometime last year.
2) If no one knows a way to convert mpfr_t's to __float128's, does anyone know of another arbitrary precision C/C++ library that can?
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可能想查看 gfortran 的实现,用于转换为内在函数(代码是 C)。它通过中间树结构执行了几个步骤,但最终结果是相同的。
You might want to look at gfortran's implementation for translating to intrinsics (the code is C). It makes a couple steps through an intermediary tree structure but the end result is the same.