C++ Memory Management
eBook - ePub

C++ Memory Management

Write leaner and safer C++ code using proven memory-management techniques

  1. English
  2. ePUB (mobile friendly)
  3. Available on iOS & Android
eBook - ePub

C++ Memory Management

Write leaner and safer C++ code using proven memory-management techniques

About this book

"This book contains something for everyone, even the most seasoned C++ programmer." — Guy Davidson, ISO C and C++ Standard Committee Voting Member "A solid foundation in memory management that quickly builds to advanced, modern C++ concepts." — Yacob Cohen Arazi, Software Engineer at NVIDIA "This book challenged my thinking and changed how I design embedded C++ systems." — Khalil Estell, ISO C++ Committee Member

Key Features

  • Use contemporary C++ features to enhance code safety and reliability
  • Develop a deeper understanding of memory management mechanisms in C++
  • Write programs that adapt to the constraints of your chosen architecture or platform

Book Description

Memory management in C++ isn't one-size-fits-all; real-time systems, games, and embedded applications each present unique memory constraints. This book delivers targeted solutions for each domain. Written by ISO C++ Standards Committee member, Patrice Roy, this guide covers fundamental concepts of object lifetime and memory organization to help you write simpler and safer programs. You'll learn how to control memory allocation mechanisms, create custom containers and allocators, and adapt allocation operators to suit your specific requirements, making your programs smaller, faster, safer, and more predictable. From core principles to modern facilities that simplify your work, you'll master memory management mechanics, build tailored memory solutions for your application needs, and measure their impact on your program's behavior. By the end of this book, you'll be able to write secure programs that handle memory optimally for your application domain. You will also have a strong grasp of both high-level abstractions for safer programs and low-level abstractions that allow detailed customization.

What you will learn

  • Master the C++ object model to write more efficient and maintainable code
  • Automate resource management to reduce manual errors and improve safety
  • Customize memory allocation operators to optimize performance for specific applications
  • Develop your own smart pointers to manage dynamic memory with greater control
  • Adapt allocation behavior to meet the unique needs of different data types
  • Create safe and fast containers to ensure optimal data handling in your programs
  • Utilize standard allocators to streamline memory management in your containers

Who this book is for

This book is for programmers who find C++ memory management challenging yet want to master it. It's ideal for those seeking greater control over memory allocation to make their programs smaller, faster, and safer. Whether you're a seasoned C++ developer or transitioning from other languages, you'll gain insights into how C++ can enhance your programming. It's especially valuable if you're working in constrained environments, like embedded systems or game development. Prior experience with programming concepts, such as generic and concurrent programming, is helpful.

]]>

Trusted by 375,005 students

Access to over 1 million titles for a fair monthly price.

Study more efficiently using our study tools.

Information

Year
2025
eBook ISBN
9781805128243

Table of contents

  1. C++ Memory Management
  2. Foreword
  3. Contributors
  4. About the reviewers
  5. Preface
  6. Part 1: Memory in C++
  7. 1
  8. 2
  9. 3
  10. Part 2: Implicit Memory Management Techniques
  11. 4
  12. 5
  13. 6
  14. Part 3: Taking Control (of Memory Management Mechanisms)
  15. 7
  16. 8
  17. 9
  18. 10
  19. 11
  20. Part 4: Writing Generic Containers (and a Bit More)
  21. 12
  22. 13
  23. 14
  24. 15
  25. 16
  26. Annexure
  27. Index

Frequently asked questions

Yes, you can cancel anytime from the Subscription tab in your account settings on the Perlego website. Your subscription will stay active until the end of your current billing period. Learn how to cancel your subscription
No, books cannot be downloaded as external files, such as PDFs, for use outside of Perlego. However, you can download books within the Perlego app for offline reading on mobile or tablet. Learn how to download books offline
Perlego offers two plans: Essential and Complete
  • Essential is ideal for learners and professionals who enjoy exploring a wide range of subjects. Access the Essential Library with 800,000+ trusted titles and best-sellers across business, personal growth, and the humanities. Includes unlimited reading time and Standard Read Aloud voice.
  • Complete: Perfect for advanced learners and researchers needing full, unrestricted access. Unlock 1.4M+ books across hundreds of subjects, including academic and specialized titles. The Complete Plan also includes advanced features like Premium Read Aloud and Research Assistant.
Both plans are available with monthly, semester, or annual billing cycles.
We are an online textbook subscription service, where you can get access to an entire online library for less than the price of a single book per month. With over 1 million books across 990+ topics, we’ve got you covered! Learn about our mission
Look out for the read-aloud symbol on your next book to see if you can listen to it. The read-aloud tool reads text aloud for you, highlighting the text as it is being read. You can pause it, speed it up and slow it down. Learn more about Read Aloud
Yes! You can use the Perlego app on both iOS and Android devices to read anytime, anywhere — even offline. Perfect for commutes or when you’re on the go.
Please note we cannot support devices running on iOS 13 and Android 7 or earlier. Learn more about using the app
Yes, you can access C++ Memory Management by Patrice Roy in PDF and/or ePUB format, as well as other popular books in Computer Science & Programming. We have over one million books available in our catalogue for you to explore.