9

I have an app that is slow to start. I assumed it was because of all the various controls on the first page, but even after I removed all the XAML (as an experiment), my start time wasn't reduced (or at least not perceptibly). I then noticed all the various assemblies getting loaded one by one in the output window.

Obviously, adding anything to a phone application (with its limited resources) is going to affect performance. But at what point will adding dlls start affecting start up performance? If you create a new app in Visual Studio, you'll have ten references automatically. How many more until you have a performance issue?

Joel Shea
  • 789
  • 7
  • 21
  • CLR loads everything on demand as needed. [Stackoverflow Discussion][1] [1]: http://stackoverflow.com/questions/2967164/how-are-dlls-loaded-by-the-clr – Smith3 Jun 24 '11 at 17:04
  • Have you downloaded the newest tools for WP7? I think there was supposed to be some sort of performance monitor tool. Not sure if that will help but it might. – webdad3 Jun 24 '11 at 19:08
  • I did, but I couldn't get them to work with my 7.0 app. I've tried to get confirmation from MS that they should work with 7.0 and 7.1 projects but no luck so far. – Joel Shea Jun 24 '11 at 19:10

1 Answers1

2

I don't see how can just-references delay your start up time. Maybe you're actually using them (see for singletons or factories on your constructors, they tend to use more resources than expected ones).

Anyway I don't see a fix. You can not load assemblies on demand cause they must be signed and licensed by Windows Marketplace. (Assembly.Load is marked as SecurityCritical).

Are you trying on emulator or device?

Erre Efe
  • 15,387
  • 10
  • 45
  • 77
  • I see this behavior on both the emulator and on the device, though of course on the device the delay is more exaggerated. – Joel Shea Jun 24 '11 at 18:59