Sebastien, I did mention Fortran when we were talking about procedural languages. Frankly, i have no idea about how Fortran.NET performs but my guess would be that any language on the .NET platform using the same framework Math classes would give the same performance, if the compiler spits out the exact optimized IL code. So IMO, C# = Fortran.NET or any other .NET language. I could be wrong but would love to be proved so.
Yes. Intel's MKL was my first choice. I can get C++ to run with MKL, BLAS and ATLAS to get a real high optimised code but i am trying the options in .NET first for now, primarily because of the ease in development. The next logical choice would of course be C++ and then Fortran. On 7/12/05, Sebastien Lorion <[EMAIL PROTECTED]> wrote: > I am a bit surprised no one has mentionned Fortran yet ... For a math > library, I would say it is a choice more than appropriate. There is a > Fortran.NET compiler, thought I don't know how it compares to C# or C++ in > terms of performance. Of course, you can't expect it to beat the Intel > "optimized to the metal" Fortran compiler :) > > For a complete list of languages supported by .NET, see > http://www.dotnetpowered.com/languages.aspx > <http://www.dotnetpowered.com/languages.aspx> > > Sébastien Lorion > > -----Original Message----- > From: Peter Ritchie [mailto:[EMAIL PROTECTED] > Sent: Mon 7/11/2005 3:22 PM > To: > Cc: > Subject: Re: Is C++ better over .NET Math library ? > > > > I wasn't talking about the value-added algorithms. I was talking about > the underlying features introduced by the language that may, > inadvertently, affect performance. > > For, example, there is no string type in C, so pointers to character > (or > character arrays) are used. In C++ with MFC you have the CString class > that adds a string "type". > > In C, you may have code like this: > char * psz; > psz = "this is some text"; > where in C++ you may have code like this: > CString str; > str = CString("str"); > > While both perform the same logic the C++ version is much less > efficient. > In C, it's a simple integer assignment. In C++, a temporary object is > allocated, a integer value is pushed on the stack, a method (c'tor) is > called), a method (operator= or default code) is called, and finally > another method is called (d'tor), not including all the stack pushing > and > popping. > > This doesn't mean C++ is less efficient; it just means that it allows > programmers that are familiar with the syntax and not the performance > consequences to write inefficient code easier. > > In all fairness, though, you could write something inefficient in C: > char * psz = strdup("text"); > > Optimizing the C++ to avoid this inefficiency would not translate to > the C > code. > > http://www.peterRitchie.com/ > > On Mon, 11 Jul 2005 13:49:44 -0500, Vijay Mahadevan > <[EMAIL PROTECTED]> wrote: > > >I have to disagree on the statement that any OO language can perform > >equally and as efficient as a procedural language like C. Any > >indirection in the execution of a procedural code is an overhead and > >it can never be compensated with a better logic or algorithm ( because > >you could write the same efficient algo in the procedural language too > >! ). If your logic is not the same in different languages, then the > >benchmark or comparison is meaningless. > > > >All higher level languages work on the principle of indirection, > >thereby creating another abstraction in the execution of the code. > >There could be several reasons and uses that come out of that but the > >speed of execution will be definitely lower. 10 calls instead of 50 > >calls on the same cpu is going to be lesser anytime ! > > > > =================================== > This list is hosted by DevelopMentor(r) http://www.develop.com > > View archives and manage your subscription(s) at > http://discuss.develop.com > > > > =================================== > This list is hosted by DevelopMentor(r) http://www.develop.com > > View archives and manage your subscription(s) at http://discuss.develop.com > =================================== This list is hosted by DevelopMentor® http://www.develop.com View archives and manage your subscription(s) at http://discuss.develop.com
