| Index: include/v8.h
|
| diff --git a/include/v8.h b/include/v8.h
|
| index ec1941e6fd86eec42707e4d41011112961fe2109..e546cb3e40b5558843ef8a613117852b9ee84832 100644
|
| --- a/include/v8.h
|
| +++ b/include/v8.h
|
| @@ -1415,6 +1415,14 @@ class V8_EXPORT StackFrame {
|
| };
|
|
|
|
|
| +struct RegisterState {
|
| + RegisterState() : pc(NULL), sp(NULL), fp(NULL) {}
|
| + void* pc; // Instruction pointer.
|
| + void* sp; // Stack pointer.
|
| + void* fp; // Frame pointer.
|
| +};
|
| +
|
| +
|
| /**
|
| * A JSON Parser.
|
| */
|
| @@ -4548,6 +4556,19 @@ class V8_EXPORT Isolate {
|
| void GetHeapStatistics(HeapStatistics* heap_statistics);
|
|
|
| /**
|
| + * Get a call stack sample from the isolate.
|
| + * \param state Execution state.
|
| + * \param frames Caller allocated buffer to store stack frames.
|
| + * \param frames_limit Maximum number of frames to capture. The buffer must
|
| + * be large enough to hold the number of frames.
|
| + * \return Actual number of captured frames.
|
| + * \note GetStackSample should only be called when the JS thread is paused or
|
| + * interrupted. Otherwise the behavior is undefined.
|
| + */
|
| + size_t GetStackSample(const RegisterState& state, void** frames,
|
| + size_t frames_limit);
|
| +
|
| + /**
|
| * Adjusts the amount of registered external memory. Used to give V8 an
|
| * indication of the amount of externally allocated memory that is kept alive
|
| * by JavaScript objects. V8 uses this to decide when to perform global
|
|
|