plafrim
play

PlaFRIM Exploration The Roofline model Performance Methodology - PowerPoint PPT Presentation

PlaFRIM Court` es L., Ru e F. Introduction General PlaFRIM Exploration The Roofline model Performance Methodology Court` es L., Ru e F. November 8, 2019 Table of contents PlaFRIM Court` es L., Ru e F. Introduction


  1. PlaFRIM Court` es L., Ru´ e F. Introduction General PlaFRIM Exploration The Roofline model Performance Methodology Court` es L., Ru´ e F. November 8, 2019

  2. Table of contents PlaFRIM Court` es L., Ru´ e F. Introduction Introduction 1 General Exploration The Roofline General Exploration 2 model Performance Methodology The Roofline model 3 Performance Methodology 4

  3. The hard way PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration printf(”%i”,time(NULL)); The Roofline model Performance Methodology

  4. The hard way PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration printf(”%i”,time(NULL)); The Roofline model Performance � Methodology

  5. The optimization objectives PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration Improve the speed of execution The Roofline model Performance Methodology

  6. The optimization objectives PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration Improve the speed of execution The Roofline model Reduce memory footprint Performance Methodology

  7. The optimization objectives PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration Improve the speed of execution The Roofline model Reduce memory footprint Performance Reduce energy consumption Methodology

  8. The optimization objectives PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration Improve the speed of execution The Roofline model Reduce memory footprint Performance Reduce energy consumption Methodology Consume fewer resources

  9. The Process PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration Identify bottlenecks (Profiling) The Roofline model Choose better algorithms or improve implementation Performance Methodology (Optimization)

  10. How profilers do it PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration Call stack sampling The Roofline model Performance Methodology

  11. How profilers do it PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration Call stack sampling The Roofline model Optional function call instrumentation Performance Methodology

  12. How profilers do it PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration Call stack sampling The Roofline model Optional function call instrumentation Performance Hardware simulation Methodology

  13. How profilers do it PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration Call stack sampling The Roofline model Optional function call instrumentation Performance Hardware simulation Methodology Hardware counter

  14. Memory PlaFRIM Court` es L., Ru´ e F. Introduction Understanding memory locality General Exploration The Roofline model Performance Methodology

  15. General Exploration PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration The Roofline model Optimization and granularity Performance Methodology

  16. The easiest way PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration Time command The Roofline model Real, user & sys time Performance Best way to evaluate scalability Methodology

  17. The easiest way PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration Time command The Roofline model Real, user & sys time Performance Best way to evaluate scalability Methodology Accuracy of the evaluation?

  18. Profiler PlaFRIM Court` es L., Ru´ e F. Introduction General static instrumentation - gprof Exploration The Roofline Sampling technique model no instrumentation needed Performance Methodology 2 types of view (flat profile and call graph)

  19. Profiler PlaFRIM Court` es L., Ru´ e F. Introduction General static instrumentation - gprof Exploration The Roofline Sampling technique model no instrumentation needed Performance Methodology 2 types of view (flat profile and call graph) Annotated code

  20. Profiler PlaFRIM static instrumentation - gprof Court` es L., Ru´ e F. use the -pg option to compile Introduction evaluate the output : gprof ’binary name’ gmon.out General Exploration The Roofline model Performance Methodology

  21. Profiler PlaFRIM static instrumentation - gprof Court` es L., use the -pg option to compile Ru´ e F. evaluate the output : gprof ’binary name’ gmon.out Introduction General Exploration The Roofline model Performance Methodology

  22. Profiler PlaFRIM static instrumentation - gprof Court` es L., Ru´ e F. gprof -A -l ’binary name’ gmon.out Introduction General Exploration The Roofline model Performance Methodology

  23. Profiler PlaFRIM static instrumentation - gprof Court` es L., Ru´ e F. gprof -A -l ’binary name’ gmon.out Introduction General Exploration The Roofline model Performance Methodology

  24. Profiler PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration The Roofline model and for memory usage ? Performance Methodology

  25. Profiler PlaFRIM Court` es L., Ru´ e F. Introduction Dynamic instrumentation - valgrind General Exploration Done at execution time The Roofline model no instrumentation needed Performance different tools for differents analysis Methodology massif - heap profiler callgrind - call history among functions cachegrind - interactions with machine cache

  26. Profiler PlaFRIM Dynamic instrumentation - valgrind Court` es L., Ru´ e F. valgrind –tool=massif –time-unit=ms ./bin/wave0 5 5 5 Introduction 100 100 100 0.0005 50 General Exploration ms print massif.out.%pid The Roofline model Performance Methodology

  27. Profiler PlaFRIM Dynamic instrumentation - valgrind Court` es L., Ru´ e F. valgrind –tool=massif –time-unit=ms ./bin/wave0 5 5 5 Introduction 100 100 100 0.0005 50 General ms print massif.out.%pid Exploration The Roofline model Performance Methodology

  28. Profiler PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration The Roofline model what kind of expertise ? Performance Methodology

  29. Profiler PlaFRIM Court` es L., what kind of image of your program do you need ? Ru´ e F. Introduction General Exploration The Roofline model Performance Methodology

  30. Profiler PlaFRIM Court` es L., what kind of image of your program do you need ? Ru´ e F. Introduction General Exploration The Roofline model Performance Methodology

  31. The Roofline model PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration The Roofline model roofline Performance Methodology

  32. The model PlaFRIM cache aware roofline model Court` es L., Ru´ e F. Introduction General Exploration The Roofline model Performance Methodology Figure: IBM - ICSC 2014, Shanghai, China

  33. The model PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration The Roofline model Performance Methodology Figure: PICSAR Project

  34. The model PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration The Roofline model Performance Methodology Figure: Thomas Jefferson National Accelerator Facility

  35. The model PlaFRIM cache aware roofline model Court` es L., Ru´ e F. Introduction General Exploration The Roofline model Performance Methodology Figure: IBM - ICSC 2014, Shanghai, China

  36. The model PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration The Roofline How to construct this model ? model Performance Methodology

  37. The model PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration The Roofline How to construct this model ? model Performance How to evaluate your Arithmetic Intensity ? Methodology

  38. Roofline evaluation PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration The Roofline model ... Performance Methodology

  39. Roofline evaluation PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration The Roofline model evaluate the performance you can achieve Performance Methodology

  40. PlaFRIM Court` es L., Ru´ e F. Performance achievement Introduction Understanding memory locality General Exploration The Roofline model Performance Methodology Figure: Memory Bound Figure: Compute Bound

  41. Intel Advisor tool PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration The Roofline model one tool to do that ... Performance Methodology

  42. Intel Advisor tool PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration The Roofline model Performance Methodology Figure: The 3D stencil: its memory access pattern (a) and the data points it uses (b). - Raul de la Cruz, BSC

  43. Intel Advisor tool PlaFRIM Court` es L., Ru´ e F. Introduction General Exploration The Roofline model Performance Methodology Figure: Stencil 1 thread - roofline

  44. Intel Advisor tool PlaFRIM Court` es L., Ru´ e F. Introduction General module load compiler/gcc/9.1.0 compiler/intel/2019 update4 Exploration intel/vtune-advisor The Roofline model advixe-cl -collect roofline –project-dir=wave0 –ignore-checksums Performance ./bin/wave0 5 5 5 100 100 100 0.0005 500 Methodology advixe-gui

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend