SlideShare a Scribd company logo
Debug, Analyze and Optimize
Games with Intel Tools
Surviving the apocalypse on mainstream graphics
Matteo Valoriani, FifthIngenium CEO
Intel Software Innovator
Nice to Meet You
www.slideshare.net/MatteoValoriani
https://it.linkedin.com/in/matteovaloriani
http://fifthingenium.com/blog
https://github.com/mvaloriani
mvaloriani at gmail dot com
@MatteoValoriani
Matteo Valoriani
CEO of FifthIngenium
PhD at Politecnico of Milano
Speaker and Consultant
2
Agenda
3
• Introduction
• Intel® Graphics Performance
Analyzers .. What ?
• Intel® GPA Live Demo
• Optimizations
• Conclusion
4
PC Virtual Reality Mobile
6
Getting Started with
Intel® Graphics
Performance Analyzers
(Intel® GPA)
https://goo.gl/2cKmMa
Intel® Graphics Performance Analyzers 2017 R1
8
How to Get Started?
Download for FREE at https://software.intel.com/gpa/
• No Code Changes Needed
• No Environment Changes
• No IDE Necessary
9
Intel® GPA - Optimize Your Graphics Applications!
High–End
GPU
Mainstream
Graphics
10fps
5fps
60+
fps
5fps
30 fps
30+
fps
Intel® Graphics
Performance
Analyzers
Host OS
▪ Win 7, Win 8.1, Win 10 (64-
bit)
DirectX*
▪ DX 9, 9EX, 10.x, 11.0, 11.1, 12
Target Hardware
▪ Intel, NVidia* & AMD* GPUs
▪ Windows x86 Tablets
▪ HTC Vive*, Oculus Rift*
10
Optimize Windows*, Android*, and Ubuntu* Games!
Windows
Gaming
Android
Gaming
Host OS
▪ Windows, Ubuntu, Mac* OSX
OpenGL* ES
▪ 1.x, 2.x, 3.x
Target Hardware
▪ Intel Atom®
Android OS
▪ 4.x, 5.x, 6.x
Ubuntu
Gaming
Host OS
▪ Ubuntu 16.04
OpenGL
▪ 3.2, 3.3, 4.0, 4.1 (Core Profile)
Target Hardware
▪ Intel® HD Graphics 4k-6k
Target OS
▪ Ubuntu 16.04
11
Host/Target Architecture
Host System Target System
12
What’s Inside Intel® GPA?
System Analyzer / HUD
Graphics Frame
Analyzer
In-game analysis
Single frame analysisTimeline analysis
Graphics Monitor
Launch & config tool
Graphics Trace
Analyzer
13
How to Use Intel® GPA?
HUD / System Analyzer:
Frame Analyzer:
Trace Analyzer:
CPU Limited
GPU Limited
Capture Frame
Capture Trace
?Run with
Intel® GPA
In-Game Analysis Offline Analysis
14
Graphics Monitor
Launch & config tool
Define profiles & preferences
15
System Analyzer / HUD
In-game analysis
• Get metrics for CPU, GPU, graphics drivers, DirectX*,
OpenGL*, or OpenGL* ES
• Experiment with override modes that quickly isolate
common performance bottlenecks
• Capture frames and traces for further analysis
• Display up to 16 performance metrics
simultaneously
• Monitor the current, minimum, and maximum frame
rate
• Use without code modifications or special libraries
16
System Analyzer / HUD
Live Analysis
17
18
Graphics Frame Analyzer
In-game analysis
• Use the API log to identify visual errors by function and call
errors and warnings to graphics APIs
• Select a draw call and verify its contribution to the frame,
alpha channel, color, format, and depth buffers
• Quantify performance optimization opportunities with
render experiments per draw call
• Solve issues with shadowing, lighting, or color schemes by
locating misplaced objects
19
Graphics Frame Analyzer
Performance Analysis with Hardware Metrics
Evaluation Flow to find 3D hotspots
20
21
Published in the 6th generation graphics API dev guide :
https://software.intel.com/en-us/articles/6th-gen-graphics-api-dev-guide
22
23
Graphics Trace Analyzer
Single frame analysis
24
Optimizations
25
Script Frustum Culling and Co-routines
Use the following Monobehavior callbacks to cull scripts
outside of the camera frustum that do not need to
update when not in focus.
Monobehavior callbacks which trigger when object with
script leaves / enters the camera frustum
26
Script Frustum Culling and Co-routines (2)
Co-routines are essentially functions with the ability to
pause and resume execution.
The power of co-routines can be leveraged by
removing the original Update() function in your script
and replacing it with a co-routine.
You can then set how often you would like your co-
routine to execute using the yield command.
27
Memory Management Optimization
A great way to get an overview of how you are managing memory is to check the ‘GC
Alloc’ section of the Overview window in Unity Profiler and step through your frames until
you see a significant allocation.
• To avoid frequent allocations, it is advantageous to use structs instead of classes to
have allocations be done on the stack, instead of in the heap.
• Multiple allocations to the heap can lead to significant memory fragmentation and
frequent garbage collections.
28
Occlusion Culling
Occlusion culling is a feature available in Unity that enables you to cull out objects that
are occluded by other objects with respect to the camera.
29
Occlusion Culling
1. Go through your entire scene to multi-select
any objects that should be included in
occlusion culling calculations and mark them
as “Occluder Static” and “Occludee Static”.
2. When setting up your occlusion culling system,
set your occlusion areas carefully.By default,
Unity uses the entire scene as the occlusion
area, which can lead to frivolous computation.
3. To make sure that the entire scene isn’t used,
create an occlusion area manually and
surround only the area to be included in the
calculation.
30
LOD
Level of Detail (LOD) allows multiple meshes to attach to a game object and provides the
ability to switch between meshes the object uses based on camera distance. The LOD can
automatically simplify the mesh to compensate.
LOD L0 L1 L2
fps 160 180 220
31
Terrain Optimization
• Sampler limited
• No dynamic branching
• Optimized for Legacy HW where sampling was faster than computing LODs
• Implementation of dynamic branching increased perf by 2x ( 3ms -> 1.5ms)
• Using samplegrad for dynamic LOD selection
Conclusion
32
33
Conclusion
With the right tools :
and the right methodology, finding performance bottlenecks is easy !
Questions ?
34
References
https://software.intel.com/gpa/
https://software.intel.com/en-us/articles/6th-gen-graphics-api-dev-guide
https://software.intel.com/en-us/articles/how-to-plan-optimizations-with-unity
https://software.intel.com/en-us/android/articles/unity-optimization-guide-for-x86-android-part-2
https://software.intel.com/en-us/android/articles/unity-optimization-guide-for-x86-android-part-3
https://software.intel.com/en-us/android/articles/unity-optimization-guide-for-x86-android-part-4
https://x-team.com/blog/unity-3d-optimisation-and-best-practices-part-1/
http://docs.unity3d.com/Manual/class-OcclusionArea.html
Legal Notices and Disclaimers
No license (express or implied, by estoppel or otherwise) to any intellectual property rights is granted by this document.
Intel disclaims all express and implied warranties, including without limitation, the implied warranties of merchantability, fitness for a particular purpose, and non-infringement, as well
as any warranty arising from course of performance, course of dealing, or usage in trade.
You may not use or facilitate the use of this document in connection with any infringement or other legal analysis concerning Intel products described herein. You agree to grant Intel
a non-exclusive, royalty-free license to any patent claim thereafter drafted which includes subject matter disclosed herein.
The products and services described may contain defects or errors known as errata which may cause deviations from published specifications. Current characterized errata are
available on request.
Intel technologies’ features and benefits depend on system configuration and may require enabled hardware, software or service activation. Performance varies depending on
system configuration. No computer system can be absolutely secure. Check with your system manufacturer or retailer or learn more at [intel.com].
Software and workloads used in performance tests may have been optimized for performance only on Intel microprocessors. Performance tests, such as SYSmark and MobileMark,
are measured using specific computer systems, components, software, operations and functions. Any change to any of those factors may cause the results to vary. You should
consult other information and performance tests to assist you in fully evaluating your contemplated purchases, including the performance of that product when combined with other
products. For more complete information visit www.intel.com/benchmarks.
Optimization Notice: Intel's compilers may or may not optimize to the same degree for non-Intel microprocessors for optimizations that are not unique to Intel microprocessors.
These optimizations include SSE2, SSE3, and SSSE3 instruction sets and other optimizations. Intel does not guarantee the availability, functionality, or effectiveness of any
optimization on microprocessors not manufactured by Intel. Microprocessor-dependent optimizations in this product are intended for use with Intel microprocessors. Certain
optimizations not specific to Intel microarchitecture are reserved for Intel microprocessors. Please refer to the applicable product User and Reference Guides for more information
regarding the specific instruction sets covered by this notice.
Results have been estimated or simulated using internal Intel analysis or architecture simulation or modeling, and provided to you for informational purposes. Any differences in your
system hardware, software or configuration may affect your actual performance.
Intel, Atom and the Intel logo are trademarks of Intel Corporation in the U.S. and/or other countries.
*Other names and brands may be claimed as the property of others
© Intel Corporation.
36
Debug, Analyze and Optimize Games with Intel Tools

More Related Content

PDF
Intel Graphics Performance Analyzers (Intel GPA)
PPTX
So You Want to Build a Snowman…But it is Summer
PDF
Make your unity game faster, faster
PPTX
Intel® Graphics Performance Analyzers
PPTX
Real-Time Game Optimization with Intel® GPA
PPTX
Optimization Deep Dive: Unreal Engine 4 on Intel
PDF
In The Trenches Optimizing UE4 for Intel
PDF
Ultra HD Video Scaling: Low-Power HW FF vs. CNN-based Super-Resolution
Intel Graphics Performance Analyzers (Intel GPA)
So You Want to Build a Snowman…But it is Summer
Make your unity game faster, faster
Intel® Graphics Performance Analyzers
Real-Time Game Optimization with Intel® GPA
Optimization Deep Dive: Unreal Engine 4 on Intel
In The Trenches Optimizing UE4 for Intel
Ultra HD Video Scaling: Low-Power HW FF vs. CNN-based Super-Resolution

What's hot (20)

PDF
More explosions, more chaos, and definitely more blowing stuff up
PDF
Real-Time Game Optimization with Intel® GPA
PDF
Bringing the Real World Into the Game World
PPTX
Unity Optimization Tips, Tricks and Tools
PPTX
Unleashing Intel® Advanced Vector Extensions 512 (Intel® AVX-512) Inside the ...
PDF
Open Source Interactive CPU Preview Rendering with Pixar's Universal Scene De...
PDF
The Architecture of 11th Generation Intel® Processor Graphics
PDF
Streamed Cloud Gaming Solutions for Android* and PC Games
PDF
Intel® Open Image Denoise in Unity*
PDF
clCaffe*: Unleashing the Power of Intel Graphics for Deep Learning Acceleration
PPTX
Embree Ray Tracing Kernels | Overview and New Features | SIGGRAPH 2018 Tech S...
PPTX
Tuning For Deep Learning Inference with Intel® Processor Graphics | SIGGRAPH ...
PDF
[Android Codefest Germany] Adding x86 target to your Android app by Xavier Ha...
PDF
Radeon Vega Pro
PDF
Create a Scalable and Destructible World in HITMAN 2*
PDF
The abcs of gpu
PDF
GPU Virtualization in SUSE
PDF
GS-4093, "AstoundSound for Gaming – The next dimension in the evolution of Au...
PDF
Snapdragon 845 Benchmarking UX Workshop
PDF
It Doesn't Have to Be Hard: How to Fix Your Performance Woes
More explosions, more chaos, and definitely more blowing stuff up
Real-Time Game Optimization with Intel® GPA
Bringing the Real World Into the Game World
Unity Optimization Tips, Tricks and Tools
Unleashing Intel® Advanced Vector Extensions 512 (Intel® AVX-512) Inside the ...
Open Source Interactive CPU Preview Rendering with Pixar's Universal Scene De...
The Architecture of 11th Generation Intel® Processor Graphics
Streamed Cloud Gaming Solutions for Android* and PC Games
Intel® Open Image Denoise in Unity*
clCaffe*: Unleashing the Power of Intel Graphics for Deep Learning Acceleration
Embree Ray Tracing Kernels | Overview and New Features | SIGGRAPH 2018 Tech S...
Tuning For Deep Learning Inference with Intel® Processor Graphics | SIGGRAPH ...
[Android Codefest Germany] Adding x86 target to your Android app by Xavier Ha...
Radeon Vega Pro
Create a Scalable and Destructible World in HITMAN 2*
The abcs of gpu
GPU Virtualization in SUSE
GS-4093, "AstoundSound for Gaming – The next dimension in the evolution of Au...
Snapdragon 845 Benchmarking UX Workshop
It Doesn't Have to Be Hard: How to Fix Your Performance Woes
Ad

Similar to Debug, Analyze and Optimize Games with Intel Tools (20)

PPTX
Getting Space Pirate Trainer* to Perform on Intel® Graphics
PPTX
Forts and Fights Scaling Performance on Unreal Engine*
PPTX
Design and Optimize your code for high-performance with Intel® Advisor and I...
PDF
Leveraging Artificial Intelligence Processing on Edge Devices
 
PDF
Kostiantyn Yelisavenko "Mastering Macro Benchmarking in .NET"
PPTX
Tales from the Optimization Trenches - Unite Copenhagen 2019
PDF
Unlocking the Power of ChatGPT and AI in Testing - NextSteps, presented by Ap...
PDF
Intel® Xeon® Processor E7-8800/4800 v4 EAMG 2.0
PPTX
Desirable software features simulation & modeling
PDF
New_Microsoft_PowerPoint_Presentation-1[1].pdf
PPTX
Common Project Mistakes (And How to Avoid Them)
PDF
Enhance and Accelerate Your AI and Machine Learning Solution | SIGGRAPH 2019 ...
PPTX
GPGPU in Commercial Software: Lessons From Three Cycles of the Adobe Creative...
PDF
Accelerating AI Adoption with Partners
PDF
Accelerating AI from the Cloud to the Edge
PPT
Agentless System Crawler - InterConnect 2016
PDF
“Benchmarking vs. Benchmarketing: Why Should You Care?,” a Presentation from ...
PPTX
Briforum2013 applicationpackagingsmackdown public
PPTX
Dublin Unity User Group Meetup Sept 2015
PDF
The Architecture of Intel Processor Graphics: Gen 11
Getting Space Pirate Trainer* to Perform on Intel® Graphics
Forts and Fights Scaling Performance on Unreal Engine*
Design and Optimize your code for high-performance with Intel® Advisor and I...
Leveraging Artificial Intelligence Processing on Edge Devices
 
Kostiantyn Yelisavenko "Mastering Macro Benchmarking in .NET"
Tales from the Optimization Trenches - Unite Copenhagen 2019
Unlocking the Power of ChatGPT and AI in Testing - NextSteps, presented by Ap...
Intel® Xeon® Processor E7-8800/4800 v4 EAMG 2.0
Desirable software features simulation & modeling
New_Microsoft_PowerPoint_Presentation-1[1].pdf
Common Project Mistakes (And How to Avoid Them)
Enhance and Accelerate Your AI and Machine Learning Solution | SIGGRAPH 2019 ...
GPGPU in Commercial Software: Lessons From Three Cycles of the Adobe Creative...
Accelerating AI Adoption with Partners
Accelerating AI from the Cloud to the Edge
Agentless System Crawler - InterConnect 2016
“Benchmarking vs. Benchmarketing: Why Should You Care?,” a Presentation from ...
Briforum2013 applicationpackagingsmackdown public
Dublin Unity User Group Meetup Sept 2015
The Architecture of Intel Processor Graphics: Gen 11
Ad

More from Matteo Valoriani (20)

PDF
Immerge yourself in a new Reality
PDF
How Augment your Reality: Different perspective on the Reality / Virtuality C...
PPTX
Hour ofcode
PDF
More Personal Computing: Windows 10, Kinect and Wearables
PDF
Introduction to development
PDF
Etna dev 2016 - Deep Dive Holographic Applications
PDF
Etna dev 2016 - Introduction to Holographic Development
PDF
Etna dev 2016 - Introduction to Mixed Reality with HoloLens
PDF
Mixed Reality from demo to product
PDF
Intel RealSense Hands-on Lab - Rome
PDF
Develop store apps with kinect for windows v2
PDF
Programming with kinect v2
PPTX
Programming with RealSense using .NET
PPTX
Face recognition
PPTX
Communitydays2015
PDF
Tecnologie e Startup: ICT è solo una commodity?
PDF
Intel real sense handson
PDF
Communityday2013
PDF
Communitydays2014
PPTX
Corso pratico di C# - 2013
Immerge yourself in a new Reality
How Augment your Reality: Different perspective on the Reality / Virtuality C...
Hour ofcode
More Personal Computing: Windows 10, Kinect and Wearables
Introduction to development
Etna dev 2016 - Deep Dive Holographic Applications
Etna dev 2016 - Introduction to Holographic Development
Etna dev 2016 - Introduction to Mixed Reality with HoloLens
Mixed Reality from demo to product
Intel RealSense Hands-on Lab - Rome
Develop store apps with kinect for windows v2
Programming with kinect v2
Programming with RealSense using .NET
Face recognition
Communitydays2015
Tecnologie e Startup: ICT è solo una commodity?
Intel real sense handson
Communityday2013
Communitydays2014
Corso pratico di C# - 2013

Recently uploaded (20)

PDF
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
PPT
Teaching material agriculture food technology
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
Approach and Philosophy of On baking technology
PDF
Dropbox Q2 2025 Financial Results & Investor Presentation
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PDF
cuic standard and advanced reporting.pdf
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PDF
Network Security Unit 5.pdf for BCA BBA.
PPTX
MYSQL Presentation for SQL database connectivity
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PDF
Spectral efficient network and resource selection model in 5G networks
PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PDF
NewMind AI Monthly Chronicles - July 2025
PPTX
Big Data Technologies - Introduction.pptx
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
Teaching material agriculture food technology
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
Approach and Philosophy of On baking technology
Dropbox Q2 2025 Financial Results & Investor Presentation
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
cuic standard and advanced reporting.pdf
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Network Security Unit 5.pdf for BCA BBA.
MYSQL Presentation for SQL database connectivity
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
20250228 LYD VKU AI Blended-Learning.pptx
Spectral efficient network and resource selection model in 5G networks
Building Integrated photovoltaic BIPV_UPV.pdf
NewMind AI Monthly Chronicles - July 2025
Big Data Technologies - Introduction.pptx
Advanced methodologies resolving dimensionality complications for autism neur...
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
Digital-Transformation-Roadmap-for-Companies.pptx

Debug, Analyze and Optimize Games with Intel Tools

  • 1. Debug, Analyze and Optimize Games with Intel Tools Surviving the apocalypse on mainstream graphics Matteo Valoriani, FifthIngenium CEO Intel Software Innovator
  • 2. Nice to Meet You www.slideshare.net/MatteoValoriani https://it.linkedin.com/in/matteovaloriani http://fifthingenium.com/blog https://github.com/mvaloriani mvaloriani at gmail dot com @MatteoValoriani Matteo Valoriani CEO of FifthIngenium PhD at Politecnico of Milano Speaker and Consultant 2
  • 3. Agenda 3 • Introduction • Intel® Graphics Performance Analyzers .. What ? • Intel® GPA Live Demo • Optimizations • Conclusion
  • 4. 4
  • 6. 6 Getting Started with Intel® Graphics Performance Analyzers (Intel® GPA) https://goo.gl/2cKmMa
  • 7. Intel® Graphics Performance Analyzers 2017 R1
  • 8. 8 How to Get Started? Download for FREE at https://software.intel.com/gpa/ • No Code Changes Needed • No Environment Changes • No IDE Necessary
  • 9. 9 Intel® GPA - Optimize Your Graphics Applications! High–End GPU Mainstream Graphics 10fps 5fps 60+ fps 5fps 30 fps 30+ fps Intel® Graphics Performance Analyzers
  • 10. Host OS ▪ Win 7, Win 8.1, Win 10 (64- bit) DirectX* ▪ DX 9, 9EX, 10.x, 11.0, 11.1, 12 Target Hardware ▪ Intel, NVidia* & AMD* GPUs ▪ Windows x86 Tablets ▪ HTC Vive*, Oculus Rift* 10 Optimize Windows*, Android*, and Ubuntu* Games! Windows Gaming Android Gaming Host OS ▪ Windows, Ubuntu, Mac* OSX OpenGL* ES ▪ 1.x, 2.x, 3.x Target Hardware ▪ Intel Atom® Android OS ▪ 4.x, 5.x, 6.x Ubuntu Gaming Host OS ▪ Ubuntu 16.04 OpenGL ▪ 3.2, 3.3, 4.0, 4.1 (Core Profile) Target Hardware ▪ Intel® HD Graphics 4k-6k Target OS ▪ Ubuntu 16.04
  • 12. 12 What’s Inside Intel® GPA? System Analyzer / HUD Graphics Frame Analyzer In-game analysis Single frame analysisTimeline analysis Graphics Monitor Launch & config tool Graphics Trace Analyzer
  • 13. 13 How to Use Intel® GPA? HUD / System Analyzer: Frame Analyzer: Trace Analyzer: CPU Limited GPU Limited Capture Frame Capture Trace ?Run with Intel® GPA In-Game Analysis Offline Analysis
  • 14. 14 Graphics Monitor Launch & config tool Define profiles & preferences
  • 15. 15 System Analyzer / HUD In-game analysis • Get metrics for CPU, GPU, graphics drivers, DirectX*, OpenGL*, or OpenGL* ES • Experiment with override modes that quickly isolate common performance bottlenecks • Capture frames and traces for further analysis • Display up to 16 performance metrics simultaneously • Monitor the current, minimum, and maximum frame rate • Use without code modifications or special libraries
  • 18. 18 Graphics Frame Analyzer In-game analysis • Use the API log to identify visual errors by function and call errors and warnings to graphics APIs • Select a draw call and verify its contribution to the frame, alpha channel, color, format, and depth buffers • Quantify performance optimization opportunities with render experiments per draw call • Solve issues with shadowing, lighting, or color schemes by locating misplaced objects
  • 20. Performance Analysis with Hardware Metrics Evaluation Flow to find 3D hotspots 20
  • 21. 21 Published in the 6th generation graphics API dev guide : https://software.intel.com/en-us/articles/6th-gen-graphics-api-dev-guide
  • 22. 22
  • 25. 25 Script Frustum Culling and Co-routines Use the following Monobehavior callbacks to cull scripts outside of the camera frustum that do not need to update when not in focus. Monobehavior callbacks which trigger when object with script leaves / enters the camera frustum
  • 26. 26 Script Frustum Culling and Co-routines (2) Co-routines are essentially functions with the ability to pause and resume execution. The power of co-routines can be leveraged by removing the original Update() function in your script and replacing it with a co-routine. You can then set how often you would like your co- routine to execute using the yield command.
  • 27. 27 Memory Management Optimization A great way to get an overview of how you are managing memory is to check the ‘GC Alloc’ section of the Overview window in Unity Profiler and step through your frames until you see a significant allocation. • To avoid frequent allocations, it is advantageous to use structs instead of classes to have allocations be done on the stack, instead of in the heap. • Multiple allocations to the heap can lead to significant memory fragmentation and frequent garbage collections.
  • 28. 28 Occlusion Culling Occlusion culling is a feature available in Unity that enables you to cull out objects that are occluded by other objects with respect to the camera.
  • 29. 29 Occlusion Culling 1. Go through your entire scene to multi-select any objects that should be included in occlusion culling calculations and mark them as “Occluder Static” and “Occludee Static”. 2. When setting up your occlusion culling system, set your occlusion areas carefully.By default, Unity uses the entire scene as the occlusion area, which can lead to frivolous computation. 3. To make sure that the entire scene isn’t used, create an occlusion area manually and surround only the area to be included in the calculation.
  • 30. 30 LOD Level of Detail (LOD) allows multiple meshes to attach to a game object and provides the ability to switch between meshes the object uses based on camera distance. The LOD can automatically simplify the mesh to compensate. LOD L0 L1 L2 fps 160 180 220
  • 31. 31 Terrain Optimization • Sampler limited • No dynamic branching • Optimized for Legacy HW where sampling was faster than computing LODs • Implementation of dynamic branching increased perf by 2x ( 3ms -> 1.5ms) • Using samplegrad for dynamic LOD selection
  • 33. 33 Conclusion With the right tools : and the right methodology, finding performance bottlenecks is easy !
  • 36. Legal Notices and Disclaimers No license (express or implied, by estoppel or otherwise) to any intellectual property rights is granted by this document. Intel disclaims all express and implied warranties, including without limitation, the implied warranties of merchantability, fitness for a particular purpose, and non-infringement, as well as any warranty arising from course of performance, course of dealing, or usage in trade. You may not use or facilitate the use of this document in connection with any infringement or other legal analysis concerning Intel products described herein. You agree to grant Intel a non-exclusive, royalty-free license to any patent claim thereafter drafted which includes subject matter disclosed herein. The products and services described may contain defects or errors known as errata which may cause deviations from published specifications. Current characterized errata are available on request. Intel technologies’ features and benefits depend on system configuration and may require enabled hardware, software or service activation. Performance varies depending on system configuration. No computer system can be absolutely secure. Check with your system manufacturer or retailer or learn more at [intel.com]. Software and workloads used in performance tests may have been optimized for performance only on Intel microprocessors. Performance tests, such as SYSmark and MobileMark, are measured using specific computer systems, components, software, operations and functions. Any change to any of those factors may cause the results to vary. You should consult other information and performance tests to assist you in fully evaluating your contemplated purchases, including the performance of that product when combined with other products. For more complete information visit www.intel.com/benchmarks. Optimization Notice: Intel's compilers may or may not optimize to the same degree for non-Intel microprocessors for optimizations that are not unique to Intel microprocessors. These optimizations include SSE2, SSE3, and SSSE3 instruction sets and other optimizations. Intel does not guarantee the availability, functionality, or effectiveness of any optimization on microprocessors not manufactured by Intel. Microprocessor-dependent optimizations in this product are intended for use with Intel microprocessors. Certain optimizations not specific to Intel microarchitecture are reserved for Intel microprocessors. Please refer to the applicable product User and Reference Guides for more information regarding the specific instruction sets covered by this notice. Results have been estimated or simulated using internal Intel analysis or architecture simulation or modeling, and provided to you for informational purposes. Any differences in your system hardware, software or configuration may affect your actual performance. Intel, Atom and the Intel logo are trademarks of Intel Corporation in the U.S. and/or other countries. *Other names and brands may be claimed as the property of others © Intel Corporation. 36