Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   ASP .Net (http://www.velocityreviews.com/forums/f29-asp-net.html)
-   -   language performance question... (http://www.velocityreviews.com/forums/t77714-language-performance-question.html)

Paul M 05-09-2004 12:47 PM

language performance question...
 
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.




Ken Cox [Microsoft MVP] 05-09-2004 12:58 PM

Re: language performance question...
 
You might want to see this:

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

"Paul M" <milsnips@hotmail.com> wrote in message
news:Om$PIPcNEHA.3944@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.
>
>
>



Mark Fitzpatrick 05-09-2004 01:01 PM

Re: language performance question...
 
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" <milsnips@hotmail.com> wrote in message
news:Om$PIPcNEHA.3944@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.
>
>
>




David Jessee 05-09-2004 06:14 PM

Re: language performance question...
 
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" <milsnips@hotmail.com> wrote in message
news:Om$PIPcNEHA.3944@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.
>
>
>




Marek 05-09-2004 07:11 PM

Re: language performance question...
 
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" <milsnips@hotmail.com> wrote in message
news:Om$PIPcNEHA.3944@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.
>
>
>




Rick Spiewak 05-10-2004 02:34 AM

Re: language performance question...
 
An article from 2001 based on the beta? Why would anyone want to see that at
this point!

"Ken Cox [Microsoft MVP]" <BANSPAMken_cox@sympatico.ca> wrote in message
news:uuZDaVcNEHA.3556@TK2MSFTNGP09.phx.gbl...
> You might want to see this:
>
> http://builder.com.com/5100-6373-1027686.html
>
> "Paul M" <milsnips@hotmail.com> wrote in message
> news:Om$PIPcNEHA.3944@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.
> >
> >
> >

>




Paul M 05-10-2004 07:29 AM

Re: language performance question...
 
great! thanks for everybody's input.

regards,
Paul.

"Paul M" <milsnips@hotmail.com> wrote in message
news:Om$PIPcNEHA.3944@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.
>
>
>





All times are GMT. The time now is 06:55 PM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.