We don’t allow questions seeking recommendations for software libraries, tutorials, tools, books, or other off-site resources. You can edit the question so it can be answered with facts and citations.
Closed 9 years ago.
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
接受
或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
发布评论
评论(4)
我相信 C 库 SoftFloat 和 fdlibm 适合您正在寻找的内容。其他包括 Linux(GNU libc、glibc)或 *BSD libc 的 数学函数。最后,CRlibm 您应该也会感兴趣。
Ulrich Drepper 有一篇有趣的查看不同的数学库,可能也值得一读。
I believe the C libraries SoftFloat and fdlibm are suitable for what you are looking for. Others include Linux (GNU libc, glibc) or *BSD libc's math functions. Finally, CRlibm should also be of interest to you.
Ulrich Drepper has a interesting look at different math libraries, that might be also worth reading through.
我一定让你失望了:几乎没有。
虽然从技术上讲存在 IEEE-754 兼容系统,因为它们确实
不实现标准中描述的非必需功能,参考
允许
在标准语言中并不存在。这会导致反复出现的麻烦
威廉·卡汉 (William Kahan),该标准及其改编背后的主要力量
在英特尔处理器上。
我不知道是否有一些深奥的语言确实支持它们,
但我可以排除 Java、C#、C++、Fortran。
编辑:虽然缺乏编译器支持,但我建议 Hausers SoftFloat
mctylr 给出的实现。豪瑟知道他在做什么。
http:// Portal.acm.org/itation.cfm?id=227699.227701&coll=portal&dl=ACM&CFID=77938829&CFTOKEN=18578907
I must disappoint you: There is practically none.
While technically there are IEEE-754 compliant systems because they do
not implement non-required features described in the standard, a reference
implementation allowing
does not exist in the standard languages. This causes recurring woes
of William Kahan, the main force behind the standard and its adaption
on the Intel processors.
I don't know if there are some esoteric languages which do support them,
but I can rule out Java, C#, C++, Fortran.
EDIT: While there is a lack of compiler support, I advise Hausers SoftFloat
implementation given by mctylr. Hauser knows what he is doing.
http://portal.acm.org/citation.cfm?id=227699.227701&coll=portal&dl=ACM&CFID=77938829&CFTOKEN=18578907
一个相当令人困惑的问题;在 C++ 中,假设此类细节由硬件或编译器处理。所以,在 C++ 中,浮点加法是
我确信这不是你真正的意思;也许您会受益于此页面,它试图模拟javascript 中的 IEEE-754 兼容硬件?
A rather confusing question; in C++ it is assumed this sort of detail is taken care of by the hardware or the compiler. So, in C++ floating-point addition would be
I'm sure this is not what you actually meant; perhaps you'd benefit from this page which tries to emulate IEEE-754-compliant hardware in javascript?
一种解决办法可以是 python。 python有一个函数可以转换IEEE-754 32/64位精度十六进制浮点
你可以用python编写你的应用程序或者只是创建一个python函数并在C/C++中调用它
我不确定如何从C/调用python C++但这是可能的。 从 C++ 调用 Python 函数
one work around for you could python. python has a function that can convert IEEE-754 32/64 bit precision HEX float point
You can either write you app in python or just create a python function and call it in C/C++
I'm unsure how to call python from C/C++ but it is possible. Calling Python functions from C++