As great as Event Monitoring is, it doesn't always capture what you're looking for. Because while replaying a request might help you determine that an incident occurred, often the cause of that issue may be transient. The data may have changed for the next request or the conditions on the server may have changed. Code Tracing will store the request execution flow from start to finish, including every function/method call, its parameters and return values, any exceptions that were thrown and any PHP errors that occurred.
Code Tracing can be set to run when an individual event is triggered or for each request by toggling a switch in the DevCloud UI.
The Code Tracing output can be accessed either in the Event Monitor UI for an individual event or by going to the Code Tracing menu option under "Monitor". Click on the Code Tracing button and you will get an output that is similar to this.