Shopify

Adding the V8 CPU Profiler to v8go - Shopify

Mar 4, 2022
Adding the V8 CPU Profiler to v8go - Shopify
SummaryAI, from the source post

This post details the integration of the V8 CPU Profiler into the v8go library. It explores two primary API implementation strategies: lazy loading, where each profile node property requires a separate Cgo call, and eager loading, where the entire profile graph is built in C++ and passed as a single pointer to Go. Performance benchmarks comparing these approaches for small and large JavaScript execution trees are presented, highlighting the trade-offs in Cgo call overhead.