Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Hands-On High Performance Programming with Qt 5

You're reading from   Hands-On High Performance Programming with Qt 5 Build cross-platform applications using concurrency, parallel programming, and memory management

Arrow left icon
Product type Paperback
Published in Jan 2019
Publisher Packt
ISBN-13 9781789531244
Length 384 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Author (1):
Arrow left icon
Marek Krajewski Marek Krajewski
Author Profile Icon Marek Krajewski
Marek Krajewski
Arrow right icon
View More author details
Toc

Table of Contents (14) Chapters Close

Preface 1. Understanding Performant Programs FREE CHAPTER 2. Profiling to Find Bottlenecks 3. Deep Dive into C++ and Performance 4. Using Data Structures and Algorithms Efficiently 5. An In-Depth Guide to Concurrency and Multithreading 6. Performance Failures and How to Overcome Them 7. Understanding I/O Performance and Overcoming Related Problems 8. Optimizing Graphical Performance 9. Optimizing Network Performance 10. Qt Performance on Embedded and Mobile Platforms 11. Testing and Deploying Qt Applications 12. Assessments 13. Other Books You May Enjoy

Summary

I hope you've enjoyed the journey so far. We acquired a basic understanding of the matter that we'll put to good use in future chapters of this book. Admittedly, in the second half, the discussion started to be a little low-level, going down into the inner workings of processors, but I hope you picked up at least a couple of buzzwords along the way.

So, we've arrived at the end of this chapter. Looking back, first we learned about benefits and caveats arising when we optimize performance and the pair, premature optimization and pessimization. Then, we discussed the basic rules for performance optimization, the well-known optimization techniques inferred from those rules, how and why memory access patterns matter, the way processors are trying to parallelize work on the instruction level, and, not to forget, what the common performance lingo's buzzwords mean.

Not bad for an introductory chapter, don't you think?

So, after we learned all of those things that we can respond to, the main question of the chapter, namely what's a performant program? The widely acknowledged response is that a performant program is a program that does the following:

  • Uses the optimal algorithm for the problem
  • Optimizes memory access patterns as to be cache friendly
  • Fully uses the parallelization possibilities of the hardware

In the following chapter, we'll look at techniques that allow us to avoid the dreaded premature optimization trap. We can steer clear of this trap by measuring how our code performs and where the bottlenecks and the tight spots are located, before actually starting to optimize. In the next chapter, we'll learn tools and techniques for doing exactly that.

You have been reading a chapter from
Hands-On High Performance Programming with Qt 5
Published in: Jan 2019
Publisher: Packt
ISBN-13: 9781789531244
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image