By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
449,315 Members | 1,672 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 449,315 IT Pros & Developers. It's quick & easy.

language performance question...

P: n/a
Can somebody please give me some coding examples in how C# written
applications perform better than VB.NEt applications?
I've read that .NET is written primarily for C# language and performance is
meant to be better for it.

thanks,
P.

Nov 18 '05 #1
Share this Question
Share on Google+
6 Replies


P: n/a
You might want to see this:

http://builder.com.com/5100-6373-1027686.html

"Paul M" <mi******@hotmail.com> wrote in message
news:Om**************@tk2msftngp13.phx.gbl...
Can somebody please give me some coding examples in how C# written
applications perform better than VB.NEt applications?
I've read that .NET is written primarily for C# language and performance
is
meant to be better for it.

thanks,
P.


Nov 18 '05 #2

P: n/a
I don't think that's truly the case. Because all the .Net languages compile
down to IL, there isactually very little performance difference. The tests
I've seen only show baout a 1 to 2% difference between various languages. C#
was just the new boy written for .Net and may be a little faster in some
things since it is not a re-write of an existing language. Basically though,
if a language's ability to compile down to IL is better than another, it
will be faster.Third-party .Net enabled languages may be right on par with
the default ones, or perhaps a tad slower if their compilers don't compile
to IL as efficiently. I remember reading that large parts of ASP.Net, if not
all parts, were actually written in C#, but that doesn't mean that C# code
runs better for ASP.Net than VB.Net and my performance tests haven't shown
that.
Hope this helps,
Mark Fitzpatrick
Microsoft MVP - FrontPage

"Paul M" <mi******@hotmail.com> wrote in message
news:Om**************@tk2msftngp13.phx.gbl...
Can somebody please give me some coding examples in how C# written
applications perform better than VB.NEt applications?
I've read that .NET is written primarily for C# language and performance is meant to be better for it.

thanks,
P.

Nov 18 '05 #3

P: n/a
The performance difference it relatively small. However, all .NET languages
are not equal. There have been projects that I've HAD to write in C# as
opposed to VB.NET because there were sertian things that I could not do with
VB.NET (e.g. serializing classes that had events)
"Paul M" <mi******@hotmail.com> wrote in message
news:Om**************@tk2msftngp13.phx.gbl...
Can somebody please give me some coding examples in how C# written
applications perform better than VB.NEt applications?
I've read that .NET is written primarily for C# language and performance is meant to be better for it.

thanks,
P.

Nov 18 '05 #4

P: n/a
Hi,

The differences are really small. Look at the following example in C#:

someValue = isConditionMet ? firstValue : anotherValue;

This generates a little bit more effective IL code than

If isConditionMet Then
someValue = firstValue
Else
someValue = anotherValue
EndIf

Marek

"Paul M" <mi******@hotmail.com> wrote in message
news:Om**************@tk2msftngp13.phx.gbl...
Can somebody please give me some coding examples in how C# written
applications perform better than VB.NEt applications?
I've read that .NET is written primarily for C# language and performance is meant to be better for it.

thanks,
P.

Nov 18 '05 #5

P: n/a
An article from 2001 based on the beta? Why would anyone want to see that at
this point!

"Ken Cox [Microsoft MVP]" <BA************@sympatico.ca> wrote in message
news:uu**************@TK2MSFTNGP09.phx.gbl...
You might want to see this:

http://builder.com.com/5100-6373-1027686.html

"Paul M" <mi******@hotmail.com> wrote in message
news:Om**************@tk2msftngp13.phx.gbl...
Can somebody please give me some coding examples in how C# written
applications perform better than VB.NEt applications?
I've read that .NET is written primarily for C# language and performance
is
meant to be better for it.

thanks,
P.

Nov 18 '05 #6

P: n/a
great! thanks for everybody's input.

regards,
Paul.

"Paul M" <mi******@hotmail.com> wrote in message
news:Om**************@tk2msftngp13.phx.gbl...
Can somebody please give me some coding examples in how C# written
applications perform better than VB.NEt applications?
I've read that .NET is written primarily for C# language and performance is meant to be better for it.

thanks,
P.

Nov 18 '05 #7

This discussion thread is closed

Replies have been disabled for this discussion.