Getting Started with Profiling Laravel Code
summary
A demo shows Blackfire profiler installed as a PHP extension and a browser extension that safely profiles production by sending 10 requests averaged and reporting a 1.69s wall time plus CPU, I/O, memory and SQL details. The profile surfaces a hot path where a function runs almost 7,000 times, revealing an N+1 issue caused by lazy-loading recent comments; the fix replaces model iteration with a direct DB count and the reprofile shows the request time dropping accordingly.
AI-written summary · about
chapters (16)
- 0:00Intro
- 1:04Inside Blackfire
- 3:50Time Summary
- 5:35Profile Overview
- 8:20Feature Blocks
- 9:25Memory Usage
- 10:20Visualization
- 11:23Function Calls
- 13:45Exclusive Time
- 14:18Inclusive Time
- 14:49Hot Path
- 17:10Meta Information
- 19:06Recommendations
- 20:17Number of Entities
- 20:55User Activity Text
- 23:20User Comments
related talks
52mUsing Blackfire to Profile Your Loading Time
50mPerformance optimization: how do I go about it?
44mDebugging Performance
54mBottleneck Analysis
23mProfiling the Profiler
47mPerformance optimisation: how do I go about it?
31mNo more slow requests
39mPHP Performance Demystified - Measure, Understand, Optimise
