.Net Comparison

L

LV

Hi,

Are there any useful resources that give a comparison of the difference in
terms of performance for C# and C++, being used with .Net?

I come from a Delphi/C++ Builder background, and am looking to migrate to
..Net for some future graphics based Windows based projects, but is C# really
the new way that we should all be doing things?, or does C++ still offer the
best in terms of power and performance?

Any pointers would be appreciated.
 
T

Tom Yates

LV said:
Hi,

Are there any useful resources that give a comparison of the difference in
terms of performance for C# and C++, being used with .Net?

I come from a Delphi/C++ Builder background, and am looking to migrate to
.Net for some future graphics based Windows based projects, but is C# really
the new way that we should all be doing things?, or does C++ still offer the
best in terms of power and performance?

Any pointers would be appreciated.

Whatever language you write your .net code in, it is compiled into
Intermediate Language (IL). So different languages do not differ in
performance.

HTH,

J
 
L

LV

Thanks for your reply Tom,

I appreciate that all code is compiled into the IL, that is then used by the
runtime. But is there any significant difference in the IL code created by
the different languages, each with their own individual features?

I see Microsoft is pushing C# as *The* language of choice, however is the
same view held in industry?
 
O

Odi [Xceed]

Hi,

Thanks for your reply Tom,

I appreciate that all code is compiled into the IL, that is then used by the
runtime. But is there any significant difference in the IL code created by
the different languages, each with their own individual features?

I see Microsoft is pushing C# as *The* language of choice, however is the
same view held in industry?

Well, our shop uses C#. We find it is a no-nonsense language that
leverages our developer's C++ and Java knowledge.

From what I understand, there is no significant difference in the IL
code created by VB.NET and C#. Likely the same with J#. But I don't
know about Eiffel, Scheme, Ada or others.

Odi
 
W

William Ryan

There can be tremendous differences between VB.NET and C# even though they
both compile to IL Code. But try turning Option Strict Off in VB (which
IMHO should be considered a war crime) and using tons of implicit type
conversion, you'll see a marked difference in performance. But this isn't
the fault of the language, it's the fault of VB programmers holding on to
the old way of doing things at the expense of performance and accuracy.

There are a lot more examples out there written in C#, and unfortunately, VB
still has a connotation of being a toy language however unfair that may be.

IMHO, the way a language is coded and efficiencies the programmer takes
advantage of will be the biggest indicator of performance. In the old days,
C++ was 'faster' than VB all else being equal, but there's some terrible C++
code out there that could run faster if written better in VB. Dan
Appleman has pounded his chest about this a lot, and he makes a pretty
compelling argument that programming, way more than the language is what to
focus on . If you haven't read his ebook with the discussion "Option Slow
On" in it, it's well worth picking up.

Cheers,

Bill
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,763
Messages
2,569,562
Members
45,038
Latest member
OrderProperKetocapsules

Latest Threads

Top