HighTechTalks DotNet Forums  

Why does conversion to 2.0 from 1.1 result in performance degradat

Dotnet Framework (Performance) microsoft.public.dotnet.framework.performance


Discuss Why does conversion to 2.0 from 1.1 result in performance degradat in the Dotnet Framework (Performance) forum.



Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old   
KVin
 
Posts: n/a

Default Why does conversion to 2.0 from 1.1 result in performance degradat - 10-01-2007 , 03:40 PM






Conversion to 2.0 (thro' vs2005) from 1.1, has made the app completely
unusable because of the performance degradation. It's a c# winforms,
multithreaded app, using datasets extensively.

I understand that in 2.0 Dataset/dataTable have become more performant, and
I was expecting a performance improvement. Instead, I see loss in
performance. I also find that app is using more memory(about 12% more) as
compared to 1.1.

I've tested the app running locally and I had expected that locally
compiled/debug app to have full trust and run-time security checks to be zero.

I did performance analysis, and I noticed following:

- % time in Run-time checks is averaging 50% ( in 1.1 it was 0)
- Total run-time checks are about 6000+/sec( in 1.1 it was 0)
- % time in GC is less than 4% ( about same as 1.1)

Has anyone else experienced this? Apparently, there are not many posts out
there with this type of problem.

Please advise.


Reply With Quote
  #2  
Old   
Chris Mullins [MVP - C#]
 
Posts: n/a

Default Re: Why does conversion to 2.0 from 1.1 result in performance degradat - 10-01-2007 , 04:41 PM






"KVin" <KVin (AT) discussions (DOT) microsoft.com> wrote:
Quote:
Conversion to 2.0 (thro' vs2005) from 1.1, has made the app completely
unusable because of the performance degradation. It's a c# winforms,
multithreaded app, using datasets extensively.
I've worked with a number of applications that exactly match that
description, and never experienced the problem you're describing. I know
that's not of any help to you, but it does at least point the finger at your
application (which is fixable) and not the platform (which isn't).

The questions I have to ask:
- Which version of Visual Studio are you compiling with?
- Are you testing a Debug or a Release version? If it's release, do you have
"enable optimization" turned on?
- I'm assuming x86 on a Windows XP system. Are you running Vista? Is UAC
turned on?
- Are you by chance running a Debug/Checked build of the O/S?

--
Chris Mullins




Reply With Quote
  #3  
Old   
schneider
 
Posts: n/a

Default Re: Why does conversion to 2.0 from 1.1 result in performance degradat - 10-01-2007 , 05:32 PM



I would also run FxCop against your code and look at security/performance
items, it may help you isolate the problems.


"Chris Mullins [MVP - C#]" <cmullins (AT) yahoo (DOT) com> wrote

Quote:
"KVin" <KVin (AT) discussions (DOT) microsoft.com> wrote:
Conversion to 2.0 (thro' vs2005) from 1.1, has made the app completely
unusable because of the performance degradation. It's a c# winforms,
multithreaded app, using datasets extensively.

I've worked with a number of applications that exactly match that
description, and never experienced the problem you're describing. I know
that's not of any help to you, but it does at least point the finger at
your application (which is fixable) and not the platform (which isn't).

The questions I have to ask:
- Which version of Visual Studio are you compiling with?
- Are you testing a Debug or a Release version? If it's release, do you
have "enable optimization" turned on?
- I'm assuming x86 on a Windows XP system. Are you running Vista? Is UAC
turned on?
- Are you by chance running a Debug/Checked build of the O/S?

--
Chris Mullins





Reply With Quote
  #4  
Old   
KVin
 
Posts: n/a

Default Re: Why does conversion to 2.0 from 1.1 result in performance degr - 10-01-2007 , 08:37 PM





"schneider" wrote:

Quote:
I would also run FxCop against your code and look at security/performance
items, it may help you isolate the problems.


"Chris Mullins [MVP - C#]" <cmullins (AT) yahoo (DOT) com> wrote in message
news:umyw4OHBIHA.484 (AT) TK2MSFTNGP06 (DOT) phx.gbl...
"KVin" <KVin (AT) discussions (DOT) microsoft.com> wrote:
Conversion to 2.0 (thro' vs2005) from 1.1, has made the app completely
unusable because of the performance degradation. It's a c# winforms,
multithreaded app, using datasets extensively.

I've worked with a number of applications that exactly match that
description, and never experienced the problem you're describing. I know
that's not of any help to you, but it does at least point the finger at
your application (which is fixable) and not the platform (which isn't).

The questions I have to ask:
- Which version of Visual Studio are you compiling with?
- Are you testing a Debug or a Release version? If it's release, do you
have "enable optimization" turned on?
- I'm assuming x86 on a Windows XP system. Are you running Vista? Is UAC
turned on?
- Are you by chance running a Debug/Checked build of the O/S?

--
Chris Mullins





1. App is compiled with vs2005.
2. I'm testing 'debug' version compiled by vs2005.
3. I'm running x86, windows XP.
4. What's debug/checked build of o/s?


Reply With Quote
  #5  
Old   
Patrick van Dijk
 
Posts: n/a

Default Re: Why does conversion to 2.0 from 1.1 result in performance degr - 10-02-2007 , 03:44 AM



Try using a Release build. There is a significant performance
difference in the Release vs. Debug versions on .NET 2.0.
We have seen only performance improvements when moving from 1.1 to
2.0, but alwyas compared Release versions.


Reply With Quote
  #6  
Old   
KVin
 
Posts: n/a

Default Re: Why does conversion to 2.0 from 1.1 result in performance degr - 10-02-2007 , 07:45 AM



Hi Patrick,

I tried Release version too. Sure, there's improvement, but not even close
to what I had in 1.1. Both Debug/Release version are compiled with 'optimize
code' checked.

I am at a loss as to why an app which runs great in 1.1 has problem on
conversion to 2.0. Obviously, I am missing something.



Reply With Quote
  #7  
Old   
schneider
 
Posts: n/a

Default Re: Why does conversion to 2.0 from 1.1 result in performance degr - 10-07-2007 , 09:10 PM




I would also run FxCop against your code and look at security/performance
items, it may help you isolate the problems.

Again, this is an easy way to check for a lot of know issues...


"KVin" <KVin (AT) discussions (DOT) microsoft.com> wrote

Quote:
Hi Patrick,

I tried Release version too. Sure, there's improvement, but not even close
to what I had in 1.1. Both Debug/Release version are compiled with
'optimize
code' checked.

I am at a loss as to why an app which runs great in 1.1 has problem on
conversion to 2.0. Obviously, I am missing something.





Reply With Quote
Reply




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.