jeffreytan81 wrote:

As another data point, I just encountered a telemetry data from a customer. 
Taking profile trace from that session shows "stackTrace" request takes more 
than 4 seconds. Around 94% of the time was spent in this hot path performing 
function evaluation:  
```
               lldb_dap::DAP::Loop()
               lldb_dap::DAP::HandleObject(llvm::json::Object const&)
               (anonymous namespace)::request_stackTrace(llvm::json::Object 
const&)
               |
               |--93.90%--lldb::SBThread::GetCurrentExceptionBacktrace()
               |          lldb_private::Thread::GetCurrentExceptionBacktrace()
               |          lldb_private::Thread::GetCurrentException()
               |          
lldb_private::ItaniumABILanguageRuntime::GetExceptionObjectForThread(std::shared_ptr<lldb_private::Thread>)
               |          |
               |          
|--91.09%--lldb_private::FunctionCaller::ExecuteFunction(lldb_private::ExecutionContext&,
 unsigned long*, lldb_private::EvaluateExpressionOptions const&, 
lldb_private::DiagnosticManager&, lldb_private::Value&)
               |          |          |
               |          |          
|--87.22%--lldb_private::FunctionCaller::InsertFunction(lldb_private::ExecutionContext&,
 unsigned long&, lldb_private::DiagnosticManager&)
               |          |          |          |
               |          |          |           
--87.13%--lldb_private::FunctionCaller::WriteFunctionWrapper(lldb_private::ExecutionContext&,
 lldb_private::DiagnosticManager&)
               |          |          |                     |
               |          |          |                      
--86.33%--lldb_private::IRExecutionUnit::GetJITModule()
               |          |          |                                
lldb_private::Module::SetLoadAddress(lldb_private::Target&, unsigned long, 
bool, bool&)
               |          |          |                                
lldb_private::ObjectFileJIT::SetLoadAddress(lldb_private::Target&, unsigned 
long, bool)
```

So this will fix a potential massive performance issue in VSCode IDE. 

https://github.com/llvm/llvm-project/pull/104874
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to