Memory Leaks in PHP: Detection, Prevention, Tooling
summary
Practical techniques for tracking and preventing memory leaks in PHP command-line programs and worker processes, including using memory_get_usage() with $real_usage, understanding copy-on-write behavior, and avoiding cyclic references. Demonstrates tools and patterns such as effective code decomposition, WeakReference and WeakMap, and concrete monitoring strategies for console commands and workers.
AI-written summary · about
chapters (10)
- 0:00Introduction
- 3:37PHP memory issues 2020
- 10:37Symfony Console progress bar
- 17:31Actual allocated memory
- 20:21Generator data handling
- 22:49Cyclic references and GC
- 28:47Memory leaks in services
- 31:58WeakReference and WeakMap
- 32:39Memory control in workers
- 35:08Profiling tools
related talks
22mHunting down memory leaks with PHP Meminfo
51mHelp, I'm Running Out of Memory!
50mPerformance optimization: how do I go about it?
31mMemory Leaks in JavaScript
24mDemystifying Memory Leaks in JavaScript
35mMemory Chronicles: Manage, Trace and Fix Memory Leaks
20mMemory Leaks and the Havoc They Wreak
01h 12m25 Years of PHP
