std - shared_ptr - T
Offered By: code::dive conference via YouTube
Course Description
Overview
Explore a comprehensive lecture from the code::dive 2016 conference focusing on std::shared_ptr in C++. Delve into the intricacies of C++ standard library smart pointers, RAII principles, and resource ownership. Examine problem statements, usage examples, and potential pitfalls of std::shared_ptr. Investigate thread safety considerations, mandatory synchronization, and idealistic implementations. Learn about custom deleters, allocator interfaces, type erasure, and Empty Base Optimization. Gain insights into the design overview, advantages of separate pointers, and the aliasing constructor. Enhance your understanding of C++ memory management and smart pointer usage through this in-depth presentation.
Syllabus
Intro
WHY DO WE USE C++?
C++ STANDARD LIBRARY SMART POINTERS
RAII (RESOURCE ACQUISITION IS INITIALIZATION)
RESOURCE OWNERSHIP
PROBLEM STATEMENT
SIMPLE USAGE EXAMPLE
std::shared_ptr - INCORRECT APPROACH
std::shared_ptr - IDEALISTIC APPROACH
IS std::shared_ptr THREAD-SAFE?
MANDATORY SYNCHRONIZATION
IDEALISTIC IMPLEMENTATION
HERB SUTTER'S FAVORITE C++ 10-LINER
std::shared_ptr CONSTRUCTION
CUSTOM DELETER INTERFACE
CUSTOM ALLOCATOR INTERFACE
ALLOCATOR TRAITS
TYPE ERASURE
EMPTY BASE OPTIMIZATION (EBO)
DESIGN OVERVIEW
ADVANTAGES OF HAVING 2 SEPARATE POINTERS
ALIASING CONSTRUCTOR
Taught by
code::dive conference
Related Courses
Основы разработки на С++: коричневый поясMoscow Institute of Physics and Technology via Coursera Complete Modern C++ (C++11/14/17)
Udemy C++: Advanced Topics
LinkedIn Learning C++ Komplettkurs: Praxisnahe und Moderne C++ Programmierung
Udemy Advance Your Skills in C++
LinkedIn Learning