On 2012-03-22 16:29:00 +0000, Joseph S. Myers wrote: > On Thu, 22 Mar 2012, Vincent Lefevre wrote: > > For the same reason, if the user chose long double instead of > > double, this may be because he wanted more precision than double. > > You mean range? IBM long double provides more precision, but not more > range.
Well, precision and/or range. If double precision format is sufficient for his application, the user can just choose the "double" type. So, I don't think that it is useful to have long double = double. Then concerning double-double vs quad (binary128) for the "long double" type, I think that quad would be more useful, in particular because it has been standardized and it is a true FP format. If need be (for efficiency reasons), double-double could still be implemented using the "double" type, via a library or ad-hoc code (that does something more clever, taking the context into account). And the same code (with just a change of the base type) could be reused to get a double-quad (i.e. quad + quad) arithmetic, that can be useful to implement the "long double" versions of the math functions (expl, and so on). > > So, in the long term, the ABI should probably be changed to have > > long double = quadruple precision (binary128). > > The ABI for Power Architecture changed away from quad precision to using > IBM long double (the original SysV ABI for PowerPC used quad precision, > the current ABI uses IBM long double).... Perhaps they could change back to quad precision. -- Vincent Lefèvre <vinc...@vinc17.net> - Web: <http://www.vinc17.net/> 100% accessible validated (X)HTML - Blog: <http://www.vinc17.net/blog/> Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)