Usenet.com

www.Usenet.com

Group Index

Comp Thread Archive from Usenet.com

<-- __Chronological__ --> <-- __Thread__ -->

Re: why still use C?



In comp.lang.c.moderated P.J. Plauger <[EMAIL PROTECTED]> wrote:
> "Hans-Bernhard Broeker" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]

> > I'm all for it, _as_long_as_ it doesn't interfere with existing code.
> > Scientists will insist that behaviour of existing code that does rely
> > on FP being done in base 2 doesn't change.

> You really think so? 

Yes.  Been there, done that.  It was big High-Energy Physics
experiment, with a total project time of more than a decade, and still
counting.  Lots of computations go on between the actual raw data
taking and the output of published results.  At least 3 generations of
computer hardware were involved over the time the experiment has been
running, and they want to be sure that changing the FPU doesn't affect
the results.  Not even minimally.  Result was that they decided to
re-configure the Intel FPUs to turn of their "excess" precision.
These guys would be *very* upset if a compiler came out that no longer
supported binary FP.

> Most `scientists' I know are content to have their FP calculations
> produce results that look more or less reasonable to, say, a dozen
> decimal places. 

Then may you only know `scientists' (including the quotes), but no
actual scientists.

I see no problem adding new features to the language.  But the day you
start removing features is when you may be causing real trouble for
people out there.

Actually, if the plan were to just use decimal FP *instead* of the now
common binary FP, there would be nothing for the committee to decide
about, as far as I can see.  A platform with FLT_RADIX==10 should be
perfectly compliant right now, as far as I can see.  It might enrage
some potential users and steer them away from such a platform, but
that's an economic risk for its vendors to worry about rather than a
concern for the C standardization comittee.

The only thing the current standard(s) doesn't support, and thus
requiring an actual committee decision, would be having more than one
FP base available on the same platform, to be used within the same
program.  And once you support more two, you have to make essentially
3 substantial decisions:

1) Whether to prescribe which of them is used as good old float, 
   double & surrounding tools, or leave that to the implementors
2) If so, which one to prescribe.
3) Whether to make support for the known-base types optional or mandatory

-- 
Hans-Bernhard Broeker ([EMAIL PROTECTED])
Even if all the snow were burnt, ashes would remain.
-- 
comp.lang.c.moderated - moderation address: [EMAIL PROTECTED]



<-- __Chronological__ --> <-- __Thread__ -->


Usenet.com



Please check out one of the premium Usenet Newsgroup Service Providers below for access to Usenet.