Creating high performance Windows Phone apps - THE WHITEPAPER

7 August 2010

Update 11/15/2010: I've been told that the team working on getting this document online has removed it from the download. For now, instead, you should actually see this reference online at MSDN here: http://msdn.microsoft.com/en-us/library/ff967560(v=VS.92).aspx, Sorry for any confusion, I'm not sure why they removed the darn thing!

Our perf whitepaper has made it out in the wild, please take a look at “Creating high performance Silverlight applications for Windows Phone” – the download includes not only the whitepaper, but also sample applications.

CreatingHighPerformanceSilverlightForWindowsPhoneApps

Some of the features it covers:

  • Compositor thread and user interface thread
  • Frame rate counter & cache visualizations
  • Cache mode
  • Fill rate concepts
  • Loading images larger than 2000 x 2000
  • Navigating into pages in other assemblies

Some tips it includes:

  • Using Opacity = 0 to hide objects and reduce the fill count
  • Using images over XAML for some graphics that don’t need to be vectors
  • Minimizing the code in constructors and initialization code paths
  • Using Dispatcher.BeginInvoke at startup to get initialization work happening quickly, but after rendering the screen
  • Using async

It includes sample apps that demonstrate concepts:

  • Examples about fill rate
  • How to hide objects using Opacity = 0
  • Loading large images
  • Per-frame callback implications
  • How to split code across DLLs to improve app startup time

This was created by performance experts on the phone and Silverlight teams, and even I’ve even contributed to the whitepaper – the frame rate counters image from my blog is in there.

I’ll also be covering many of these topics in depth on this blog going forward.

Hope this helps.

Jeff Wilcox is a Software Engineer at Microsoft in the Open Source Programs Office (OSPO), helping Microsoft engineers use, contribute to and release open source at scale.

comments powered by Disqus