Get Free Shipping on orders over $89
C++ Memory Management : Write leaner and safer C++ code using proven memory-management techniques - Patrice Roy

C++ Memory Management

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

By: Patrice Roy, Michael Wong (Foreword by)

Paperback | 25 March 2025

At a Glance

Paperback


$63.79

or 4 interest-free payments of $15.95 with

 or 

Ships in 5 to 7 business days

Harness the power of C++ to build smaller, faster, safer, and more predictable programs using the latest techniques and best practices to optimize performance and ensure reliability in your software development projects

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

- Purchase of the print or Kindle book includes a free PDF eBook

Book Description:

C++ programmers often face challenges in allocating and managing memory efficiently, especially given the diverse needs of real-time systems, embedded systems, games, and conventional desktop applications. This book offers a targeted approach to address the unique memory constraints of each domain.

Written by an 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.

Starting with core principles of memory management, this book introduces modern facilities that simplify your work and then dives into memory management mechanics, building solutions for specific application needs, and measuring 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.

Table of Contents

- Objects, Pointers, and References

- Things to Be Careful With

- Casts and cv-qualifications

- Using Destructors

- Using Standard Smart Pointers

- Writing Smart Pointers

- Overloading Memory Allocation Operators

- Writing a Na¯ve Leak Detector

- Atypical Allocation Mechanisms

- Arena-Based Memory Management and Other Optimizations

- Deferred Reclamation

- Writing Generic Containers with Explicit Memory Management

- Writing Generic Containers with Implicit Memory Management

- Writing Generic Containers with Allocator Support

- Contemporary Issues

- Annexure: Things You Should Know

More in Programming & Scripting Languages

Python All-in-One For Dummies : 3rd Edition - John C. Shovic

RRP $74.95

$49.99

33%
OFF
Swift : The Practical Guide - Kerem Koseoglu
Introduction to Programming Languages - Gordon Hurley
The C Programming Language : Prentice Hall Software - Brian Kernighan

RRP $107.04

$75.75

29%
OFF
Learning Go : An Idiomatic Approach to Real-World Go Programming - Jon Bodner
Fundamentals of Python : 3rd Edition - First Programs - Kenneth Lambert
C# 10.0 All-in-One For Dummies : For Dummies (Computer/Tech) - John Paul Mueller
Coding All-in-One For Dummies : 2nd Edition - Chris Minnick

RRP $69.95

$46.99

33%
OFF
PHP, MySQL, & JavaScript All-In-One For Dummies : For Dummies - Richard Blum
C++ Programming Language, The - Bjarne Stroustrup

RRP $117.91

$89.99

24%
OFF
Fluent Python : Clear, Concise, and Effective Programming 2nd Edition - Luciano Ramalho
Effective Typescript : 83 Specific Ways to Improve Your Typescript - Dan VanderKam