Another really interesting link compliments of Andy

Published Sun, Aug 22 2004 21:10 | William
Andy posted this  a while back on floating point accuracy he can't use .NET, at least in its current state.  Anyway, he's always good for some really thought provoking insights and has the links to back it up.  Here  is another example - and a great topic indeed
Filed under:

Comments

# William said on August 22, 2004 10:05 PM:

Thanks for the kind words Bill.

It's true for most things I can't use .Net and I hold .Net and VC++ to be separate things. What I call .Net is really the clr and because of the way the clr deals with floating points I can't use it.

VC++2005 on the other hand gives me all the control that I've been drooling for, for years now. Sometimes in the past it has been neccesary to step directly into assembler to control floating point calculations and keep the compiler from optimizing away your floating point specific logic.

I'm sure in the future we will see the clr implement the same flags for floating point control ( at least I hope we will ) and then many more things that used to be done at a very low level can be moved up into languages such as C# which use the clr.

I mean look at generics, people said "hey C# sucks for me because I need template style type deduction in my code." And walla a little later you get generics. Yes, they still have problems and are not as functional as C++'s templates but it's getting better.

Just look at Java's multi-threading stuff. Years ago people said that couldn't be done because threads were to platform specific, but now Java has some kick @ss multi-threading built into it.

I think the squeaky wheel gets the grease, if enough people want control over floating points and their calculations then I'm sure they will add more control to the clr over floating points. However I'm not sure that there is enough demand out there for them to implement it? I could be wrong but how many times have you ever heard "gee I sure wish I could control ulp's and the range of relative rounding error with C#" .

So far from what I have seen C# and the clr are targeting a different type of development than the type of development which requires this type of control. But just like I never thought I'd see templates in C# I could be very wrong about this too. Two years ago I didn't think there were enough people using C# that were used to using templates who would ask for that type of thing in C#. So perhapse two years from now we will see the floating point control offered in VC++2005 in the clr available to VB.Net and C#?

It seems that if enough people ask anything is possible. I am perfectly content to go on using C++ and C until something better comes along but I couldn't say I wouldn't love it if they added absolute control over floating points to C#.

Search

This Blog

Tags

Community

Archives

News

My other sites

Cool Stuff

Book Stuff

Security

ORM

Data Access

Funny Stuff

Compact Framework Stuff

Web Casts

My KnowledgeBase Articles

My MVP Profile

Design Patterns

Performance

Debugging

Remoting

My Fellow Authors

My Books

LINQ

Misc

Speech

Syndication

Email Notifications