@@ -518,6 +518,31 @@ namespace BinaryNinjaDebuggerAPI {
518518 TTDCallEvent () : threadId(0 ), uniqueThreadId(0 ), functionAddress(0 ), returnAddress(0 ), returnValue(0 ), hasReturnValue(false ) {}
519519 };
520520
521+ struct TTDHeapEvent
522+ {
523+ std::string eventType; // Event type (always "Heap" for TTD.Heap objects)
524+ std::string action; // Heap action: Alloc, ReAlloc, Free, Create, Protect, Lock, Unlock, Destroy
525+ uint32_t threadId; // OS thread ID of thread that made the heap call
526+ uint32_t uniqueThreadId; // Unique ID for the thread across the trace
527+ uint64_t heap; // Handle for the Win32 heap
528+ uint64_t address; // Address of the allocated object (if applicable)
529+ uint64_t previousAddress; // Address before reallocation (for ReAlloc)
530+ uint64_t size; // Size of allocated object (if applicable)
531+ uint64_t baseAddress; // Base address of allocated object (if applicable)
532+ uint64_t flags; // Heap API flags (meaning depends on API)
533+ uint64_t result; // Result of heap API call (non-zero = success)
534+ uint64_t reserveSize; // Amount of memory to reserve (for Create)
535+ uint64_t commitSize; // Initial committed size (for Create)
536+ uint64_t makeReadOnly; // Non-zero = make heap read-only (for Protect)
537+ std::vector<std::string> parameters; // Raw parameters from the heap call
538+ TTDPosition timeStart; // Position when heap operation started
539+ TTDPosition timeEnd; // Position when heap operation ended
540+
541+ TTDHeapEvent () : threadId(0 ), uniqueThreadId(0 ), heap(0 ), address(0 ), previousAddress(0 ),
542+ size (0 ), baseAddress(0 ), flags(0 ), result(0 ), reserveSize(0 ),
543+ commitSize(0 ), makeReadOnly(0 ) {}
544+ };
545+
521546 // TTD Event Types - bitfield flags for filtering events
522547 enum TTDEventType
523548 {
@@ -590,31 +615,6 @@ namespace BinaryNinjaDebuggerAPI {
590615 TTDEvent (TTDEventType eventType) : type(eventType) {}
591616 };
592617
593- struct TTDHeapEvent
594- {
595- std::string eventType; // Event type (always "Heap" for TTD.Heap objects)
596- std::string action; // Heap action: Alloc, ReAlloc, Free, Create, Protect, Lock, Unlock, Destroy
597- uint32_t threadId; // OS thread ID of thread that made the heap call
598- uint32_t uniqueThreadId; // Unique ID for the thread across the trace
599- uint64_t heap; // Handle for the Win32 heap
600- uint64_t address; // Address of the allocated object (if applicable)
601- uint64_t previousAddress; // Address before reallocation (for ReAlloc)
602- uint64_t size; // Size of allocated object (if applicable)
603- uint64_t baseAddress; // Base address of allocated object (if applicable)
604- uint64_t flags; // Heap API flags (meaning depends on API)
605- uint64_t result; // Result of heap API call (non-zero = success)
606- uint64_t reserveSize; // Amount of memory to reserve (for Create)
607- uint64_t commitSize; // Initial committed size (for Create)
608- uint64_t makeReadOnly; // Non-zero = make heap read-only (for Protect)
609- std::vector<std::string> parameters; // Raw parameters from the heap call
610- TTDPosition timeStart; // Position when heap operation started
611- TTDPosition timeEnd; // Position when heap operation ended
612-
613- TTDHeapEvent () : threadId(0 ), uniqueThreadId(0 ), heap(0 ), address(0 ), previousAddress(0 ),
614- size (0 ), baseAddress(0 ), flags(0 ), result(0 ), reserveSize(0 ),
615- commitSize(0 ), makeReadOnly(0 ) {}
616- };
617-
618618
619619 typedef BNDebugAdapterConnectionStatus DebugAdapterConnectionStatus;
620620 typedef BNDebugAdapterTargetStatus DebugAdapterTargetStatus;
0 commit comments