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
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
The Insider's Guide to Arm Cortex-M Development

You're reading from   The Insider's Guide to Arm Cortex-M Development Leverage embedded software development tools and examples to become an efficient Cortex-M developer

Arrow left icon
Product type Paperback
Published in Oct 2022
Publisher Packt
ISBN-13 9781803231112
Length 276 pages
Edition 1st Edition
Arrow right icon
Authors (3):
Arrow left icon
Jason Andrews Jason Andrews
Author Profile Icon Jason Andrews
Jason Andrews
Pareena Verma Pareena Verma
Author Profile Icon Pareena Verma
Pareena Verma
Zachary Lusiak Zachary Lusiak
Author Profile Icon Zachary Lusiak
Zachary Lusiak
Arrow right icon
View More author details
Toc

Table of Contents (15) Chapters Close

Preface 1. Part 1: Get Set Up
2. Chapter 1: Selecting the Right Hardware FREE CHAPTER 3. Chapter 2: Selecting the Right Software 4. Chapter 3: Selecting the Right Tools 5. Part 2: Sharpen Your Skills
6. Chapter 4: Booting to Main 7. Chapter 5: Optimizing Performance 8. Chapter 6: Leveraging Machine Learning 9. Chapter 7: Enforcing Security 10. Chapter 8: Streamlining with the Cloud 11. Chapter 9: Implementing Continuous Integration 12. Chapter 10: Looking Ahead 13. Index 14. Other Books You May Enjoy

Measuring dot product performance

Now that we know how to measure the cycle count of an important section of code, let’s give it a try by measuring the dot product performance on the Raspberry Pi Pico. We will look at multiple implementations of the dot product and experiment with compiler optimizations to see how the implementation of the dot product impacts performance.

Using the Raspberry Pi Pico

Often, a project already has a Cortex-M microcontroller chosen, which cannot be changed. In this case, the best system performance can be obtained using a combination of changes to the source code algorithms and the compiler optimization levels. In some cases, the compiler itself can also be changed (though this is often predetermined for projects).

In this section, we take the dot product example and create three different implementations with different source code and then use the compiler options to check the impact on performance. As the Cortex-M0+ in the Raspberry...

lock icon The rest of the chapter is locked
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