SlideShare ist ein Scribd-Unternehmen logo
1 von 32
#techday2012
•   loading, parsing, fetching data
Background Threads   •   networking
•   Parse and create objects from XAML
                     •   Draw all visuals the first time they are drawn
UI Thread            •   Process per-frame callbacks and execute
                         other user code
                     •   Bindings


                     •   loading, parsing, fetching data
Background Threads   •   networking
•   Storyboard-driven animations (including
                         ScaleTransform, TranslateTransform,
                         RotateTransform, PlaneProjection)
Composition Thread       NB! Scale transforms must be less   than 50 percent
                         of the original size
                     •   Clip, Opacity
                     •   Back-buffer


                     •   Parse and create objects from XAML.
                     •   Draw all visuals the first time they are drawn.
UI Thread            •   Process per-frame callbacks and execute
                         other user code
                     •   Bindings


                     •   loading, parsing, fetching data
Background Threads   •   networking
Showing the areas that are being redrawn
each frame
Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin
Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin
Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin
Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin
Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin
Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin
Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin
Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin
Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin
Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin
Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin
Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin
Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin
Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin
Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin
Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin
Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin

Weitere ähnliche Inhalte

Ähnlich wie Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin

Millions quotes per second in pure java
Millions quotes per second in pure javaMillions quotes per second in pure java
Millions quotes per second in pure java
Roman Elizarov
 
Java 8 selected updates
Java 8 selected updatesJava 8 selected updates
Java 8 selected updates
Vinay H G
 
VoltDB and Erlang - Tech planet 2012
VoltDB and Erlang - Tech planet 2012VoltDB and Erlang - Tech planet 2012
VoltDB and Erlang - Tech planet 2012
Eonblast
 
Making a game with Molehill: Zombie Tycoon
Making a game with Molehill: Zombie TycoonMaking a game with Molehill: Zombie Tycoon
Making a game with Molehill: Zombie Tycoon
Jean-Philippe Doiron
 
Mike Taulty TechDays 2010 Silverlight and Windows Phone 7 CTP
Mike Taulty TechDays 2010 Silverlight and Windows Phone 7 CTPMike Taulty TechDays 2010 Silverlight and Windows Phone 7 CTP
Mike Taulty TechDays 2010 Silverlight and Windows Phone 7 CTP
ukdpe
 
Scotas - Oracle Open World Sao Pablo
Scotas - Oracle Open World Sao PabloScotas - Oracle Open World Sao Pablo
Scotas - Oracle Open World Sao Pablo
Julian Arocena
 

Ähnlich wie Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin (20)

Extbase object to xml mapping
Extbase object to xml mappingExtbase object to xml mapping
Extbase object to xml mapping
 
Cloud stack overview
Cloud stack overviewCloud stack overview
Cloud stack overview
 
Making HTML5 Mobile Games Indistinguishable from Native Apps
Making HTML5 Mobile Games Indistinguishable from Native AppsMaking HTML5 Mobile Games Indistinguishable from Native Apps
Making HTML5 Mobile Games Indistinguishable from Native Apps
 
"Source Code Abstracts Classification Using CNN", Vadim Markovtsev, Lead Soft...
"Source Code Abstracts Classification Using CNN", Vadim Markovtsev, Lead Soft..."Source Code Abstracts Classification Using CNN", Vadim Markovtsev, Lead Soft...
"Source Code Abstracts Classification Using CNN", Vadim Markovtsev, Lead Soft...
 
Millions quotes per second in pure java
Millions quotes per second in pure javaMillions quotes per second in pure java
Millions quotes per second in pure java
 
Java 8 selected updates
Java 8 selected updatesJava 8 selected updates
Java 8 selected updates
 
VoltDB and Erlang - Tech planet 2012
VoltDB and Erlang - Tech planet 2012VoltDB and Erlang - Tech planet 2012
VoltDB and Erlang - Tech planet 2012
 
Layers in Deep Learning & Caffe layers (model architecture )
Layers in Deep Learning&Caffe layers (model architecture )Layers in Deep Learning&Caffe layers (model architecture )
Layers in Deep Learning & Caffe layers (model architecture )
 
My sql tutorial-oscon-2012
My sql tutorial-oscon-2012My sql tutorial-oscon-2012
My sql tutorial-oscon-2012
 
20120802 timisoara
20120802 timisoara20120802 timisoara
20120802 timisoara
 
Scala and Lift
Scala and LiftScala and Lift
Scala and Lift
 
Making a game with Molehill: Zombie Tycoon
Making a game with Molehill: Zombie TycoonMaking a game with Molehill: Zombie Tycoon
Making a game with Molehill: Zombie Tycoon
 
Engineered Systems: Oracle’s Vision for the Future
Engineered Systems: Oracle’s Vision for the FutureEngineered Systems: Oracle’s Vision for the Future
Engineered Systems: Oracle’s Vision for the Future
 
Mike Taulty TechDays 2010 Silverlight and Windows Phone 7 CTP
Mike Taulty TechDays 2010 Silverlight and Windows Phone 7 CTPMike Taulty TechDays 2010 Silverlight and Windows Phone 7 CTP
Mike Taulty TechDays 2010 Silverlight and Windows Phone 7 CTP
 
Lots of facets, fast
Lots of facets, fastLots of facets, fast
Lots of facets, fast
 
Training on iOS app development - Samesh Swongamikha & Neetin Sharma
Training on iOS app development - Samesh Swongamikha & Neetin SharmaTraining on iOS app development - Samesh Swongamikha & Neetin Sharma
Training on iOS app development - Samesh Swongamikha & Neetin Sharma
 
Scotas - Oracle Open World Sao Pablo
Scotas - Oracle Open World Sao PabloScotas - Oracle Open World Sao Pablo
Scotas - Oracle Open World Sao Pablo
 
IBM-AIX Online Training
IBM-AIX Online TrainingIBM-AIX Online Training
IBM-AIX Online Training
 
Introduction to java by priti sajja
Introduction to java by priti sajjaIntroduction to java by priti sajja
Introduction to java by priti sajja
 
Erjang - A journey into Erlang-land
Erjang - A journey into Erlang-landErjang - A journey into Erlang-land
Erjang - A journey into Erlang-land
 

Kürzlich hochgeladen

Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
giselly40
 

Kürzlich hochgeladen (20)

Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 

Windows Phone app Performance and Memory Consumption Tuning by Jevgeni Tsaikin

  • 2.
  • 3.
  • 4.
  • 5.
  • 6.
  • 7. loading, parsing, fetching data Background Threads • networking
  • 8. Parse and create objects from XAML • Draw all visuals the first time they are drawn UI Thread • Process per-frame callbacks and execute other user code • Bindings • loading, parsing, fetching data Background Threads • networking
  • 9. Storyboard-driven animations (including ScaleTransform, TranslateTransform, RotateTransform, PlaneProjection) Composition Thread NB! Scale transforms must be less than 50 percent of the original size • Clip, Opacity • Back-buffer • Parse and create objects from XAML. • Draw all visuals the first time they are drawn. UI Thread • Process per-frame callbacks and execute other user code • Bindings • loading, parsing, fetching data Background Threads • networking
  • 10.
  • 11.
  • 12.
  • 13.
  • 14.
  • 15. Showing the areas that are being redrawn each frame

Hinweis der Redaktion

  1. Skype for Windows Phone 10/14/12
  2. 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  3. We all want to create applications that run snappy and fast and performance optimization helps us to achieve this goal. Those applications provide users with… 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  4. There is a set of technical certification requirements from the Marketplace dedicated to performance and resource management. 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  5. What are we going to discuss today? I will begin with explaining to you the basics of threading model used on Windows Phone platform. Then I will introduce you to a set of tools we can use to profile app performance and memory usage. After that we are going to discuss more specific things such as speeding up the startup of an application, speeding up the navigation between pages. Then I give some general performance considerations. And at the end we will discuss virtualization and how to fix the memory leaks. 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  6. 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  7. Most of our applications deal with large amount of data and to provide user with a smoother UX we need to delegate most of our data operations to background thread. 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  8. UI Thread is the main thread of our application which deals with parsing and creating objects from XAML, drawing all visual content for the first time, process per-frame callbacks and execute user code. Also it takes care of the bindings. Important thing is that thread is executed on the CPU. If this thread is very busy user may experience glitches and lags in application. 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  9. Composition thread mostly handles storyboard-driven animations such as ScaleTransform, TranslateTransform, RomateTransform and others. One limitation for ScaleTransform is that the scale should not be over 50 percent of original size. It also handles such properties as Clip and Opacity. Another important part is back-buffer… Composition Thread is mostly execute on GPU… +Direct Manipulation Thread to handle scrolling for lists. 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  10. The main idea behind performance and CPU usage optimization is to keep as much activity off of the UI thread as possible and pass the activities down to Composition Thread and Background Threads. Then the application will run much smoother, without any glitches or lags. 10/14/12
  11. Here is a list of tools that I use in my daily developer life. Those tools are… 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  12. WP Perf Analysis tools helps us to identify…, but the main purpose for this tool is to measure memory and CPU usage. Green – UI Thread (less than 50%), Purple – Composition+Background, Grey – system, White – available CPU 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  13. Composition (Render) Thread Frame Rate (FPS) The rate at which the screen is updated. User Interface Thread Frame Rate (FPS) The rate at which the UI thread is running. Texture Memory Usage The video memory and system memory copies of textures being used in the application. Surface Counter The number of explicit surfaces being passed to the GPU for processing. Intermediate Surface Counter The number of implicit surfaces generated as a result of cached surfaces. Screen Fill Rate Counter The number of pixels being painted per frame in terms of screens. A value of 1 represents 480 x 800 pixels. 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  14. Some of those values have recommended thresholds. 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  15. EnableRedrawRegions helps developers to identify the areas that are being redrawn each frame. Usually some of the areas are redrawn without developer intention or by mistake which also steal some of CPU/GPU resourses. 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  16. Let’s now talk about how can we speed up the startup. It is important because startup is the first time user meets the application and develop first impression, so it needs to be really fast. What can we do to achieve that goal? … 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  17. Let’s now talk about how can we speed up the startup. It is important because startup is the first time user meets the application and develop first impression, so it needs to be really fast. What can we do to achieve that goal? … 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  18. Another important area for optimization is the navigation between pages. It also needs to be optimized to provide user is with lag-free page transition. What can we do to optimize that? 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  19. One of the major differences between JPG and PNG formats is that JPG decoder is much faster than the PNG one. Also I would highly recommend to avoid image scaling in your applications to save some CPU and also you have to limit the image size to 2000x2000 pixels, because larger images will be sampled at a lower resolution. Which again leads to a CPU loss. 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  20. Another important thing is to use static visuals such as images instead of XAML, because XAML needs to be reinterpreted on UI Thread, which usually takes more time than just displaying a static image. Finally, since Mango release we can now use CreateOptions to delegate the image decoding to a background thread instead of blocking the UI thread. 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  21. How can we show and hide UI elements within our applications? There are two main ways to do that in Windows Phone environment: it is by using Visibility property or Opacity property. Then Visibility is set to collapsed then Silverlight does not hold any visual data for the element, but when we set the Visibility back to Visible the object is redrawn completely. While the UI element with Opacity set to 0 still stays in memory, but doesn’t require the object to be redrawn. It is a trade-off between the CPU and Memory usage. From my personal experience I would recommend to use Opacity combined with Bitmap Caching to improve the performance. 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  22. When it comes to displaying lists we can follow two basic approaches. First of all we can use StackPanel and secondly we can use VirtualizingStackPanel. What’s the difference between them? Pretty simple, StackPanel keeps all the elements in memory while VirtualizingStackPanel keeps only those items that fit into visible viewport plus two viewports in a buffer and all the rest is loaded on demand. One of the best implementations of VirtualizingStackPanel is the ListBox which is virtualized by default. 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  23. Limited to hardware, Less Memory, Less processing power. In some cases smooth UX is more important than fancy animations and extremely rich content. Also test on real devices, because emulator doesn’t provide you with accurate measurements. 10/14/12 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. Microsoft Consumer Channels and Central Marketing Group
  24. LITHUANIA 10/14/12 11:29 © 2010 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.
  25. LATVIA 10/14/12 11:29 © 2010 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.
  26. ESTONIA 10/14/12 11:29 © 2010 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.