HyperDbg Debugger
Loading...
Searching...
No Matches
PtApi.c File Reference

Tracing routines for HyperTrace module (Intel Processor Trace). More...

#include "pch.h"

Functions

BOOLEAN HyperTracePtEnable (HYPERTRACE_PT_OPERATION_PACKETS *PtOperationRequest)
 Enable PT tracing for HyperTrace.
BOOLEAN HyperTracePtDisable (HYPERTRACE_PT_OPERATION_PACKETS *PtOperationRequest)
 Disable PT tracing for HyperTrace.
BOOLEAN HyperTracePtPause (HYPERTRACE_PT_OPERATION_PACKETS *HyperTraceOperationRequest)
 Pause PT tracing on every core. Buffers stay allocated and the per-CPU CTL is preserved, so HyperTracePtResume can restart the trace exactly where it stopped.
BOOLEAN HyperTracePtResume (HYPERTRACE_PT_OPERATION_PACKETS *HyperTraceOperationRequest)
 Resume PT tracing on every core after a prior HyperTracePtPause.
BOOLEAN HyperTracePtSize (HYPERTRACE_PT_OPERATION_PACKETS *HyperTraceOperationRequest)
 Snapshot the current PT output position on every core and write the per-CPU byte counts into HyperTraceOperationRequest->BytesPerCpu. The returned counts are the decode window — bytes [0, BytesPerCpu[i]) in CPU i's user mapping currently hold valid trace data.
BOOLEAN HyperTracePtDump (HYPERTRACE_PT_OPERATION_PACKETS *HyperTraceOperationRequest)
 Dump PT trace state for HyperTrace.
BOOLEAN HyperTracePtFlush (HYPERTRACE_PT_OPERATION_PACKETS *HyperTraceOperationRequest)
 Flush PT trace state on all cores (free buffers).
BOOLEAN HyperTracePtFilter (HYPERTRACE_PT_OPERATION_PACKETS *Req)
 Apply a new PT trace configuration (TraceUser / TraceKernel / TargetCr3 / BufferSize / NumAddrRanges + AddrRanges) on all cores.
BOOLEAN HyperTracePtMmap (HYPERTRACE_PT_MMAP_PACKETS *Req)
 Map every per-CPU PT main output + overflow buffer into the calling user-mode process. See HYPERTRACE_PT_MMAP_PACKETS for the full lifetime / single-process contract.
BOOLEAN HyperTracePtPerformOperation (HYPERTRACE_PT_OPERATION_PACKETS *PtOperationRequest)
 Perform actions related to HyperTrace PT.

Detailed Description

Tracing routines for HyperTrace module (Intel Processor Trace).

Author
Masoud Rahimi Jafari (Masoo.nosp@m.drah.nosp@m.imy13.nosp@m.79@g.nosp@m.mail..nosp@m.com)
Version
0.19
Date
2026-04-29

Function Documentation

◆ HyperTracePtDisable()

BOOLEAN HyperTracePtDisable ( HYPERTRACE_PT_OPERATION_PACKETS * PtOperationRequest)

Disable PT tracing for HyperTrace.

Parameters
PtOperationRequestPointer to the HyperTrace PT operation request packet
Returns
BOOLEAN
158{
159 //
160 // Check if PT is already disabled or not
161 //
163 {
164 if (PtOperationRequest != NULL)
165 {
167 }
168
169 return FALSE;
170 }
171
172 //
173 // Disabling PT
174 //
176
177 //
178 // Broadcast disabling PT on all cores (DPC stops tracing per-core)
179 //
181
182 //
183 // Free per-CPU buffers at PASSIVE_LEVEL after the broadcast has stopped
184 // tracing on every core.
185 //
187
188 //
189 // Set successful status
190 //
191 if (PtOperationRequest != NULL)
192 {
194 }
195
196 return TRUE;
197}
#define TRUE
Definition BasicTypes.h:114
#define FALSE
Definition BasicTypes.h:113
#define DEBUGGER_ERROR_PT_ALREADY_DISABLED
error, PT is already disabled
Definition ErrorCodes.h:630
#define DEBUGGER_OPERATION_WAS_SUCCESSFUL
General value to indicate that the operation or request was successful.
Definition ErrorCodes.h:23
VOID PtFreeAllCpuBuffers()
Free ToPA / output / overflow buffers for every active CPU.
Definition Pt.c:1089
VOID BroadcastDisablePtOnAllCores()
Routines to disable PT on all cores.
Definition Broadcast.c:89
BOOLEAN g_ProcessorTraceEnabled
The flag indicating whether the hypertrace Processor Trace is initialized or not.
Definition GlobalVariables.h:78
UINT32 KernelStatus
Definition RequestStructures.h:1384

◆ HyperTracePtDump()

BOOLEAN HyperTracePtDump ( HYPERTRACE_PT_OPERATION_PACKETS * HyperTraceOperationRequest)

Dump PT trace state for HyperTrace.

Parameters
HyperTraceOperationRequest
Returns
BOOLEAN
309{
311 {
312 if (HyperTraceOperationRequest != NULL)
313 {
314 HyperTraceOperationRequest->KernelStatus = DEBUGGER_ERROR_PT_ALREADY_DISABLED;
315 }
316 return FALSE;
317 }
318
319 LogInfo("Dumping PT trace summary...\n");
320
322
323 if (HyperTraceOperationRequest != NULL)
324 {
325 HyperTraceOperationRequest->KernelStatus = DEBUGGER_OPERATION_WAS_SUCCESSFUL;
326 }
327
328 return TRUE;
329}
#define LogInfo(format,...)
Define log variables.
Definition HyperDbgHyperLogIntrinsics.h:71
VOID BroadcastDumpPtOnAllCores()
Routines to dump PT state on all cores.
Definition Broadcast.c:135

◆ HyperTracePtEnable()

BOOLEAN HyperTracePtEnable ( HYPERTRACE_PT_OPERATION_PACKETS * PtOperationRequest)

Enable PT tracing for HyperTrace.

Parameters
PtOperationRequestPointer to the HyperTrace PT operation request packet
Returns
BOOLEAN
95{
96 //
97 // Check if PT is already enabled or not
98 //
100 {
102 return FALSE;
103 }
104
105 //
106 // Check PT support on CPU
107 //
108 if (!PtCheck())
109 {
110 PtOperationRequest->KernelStatus = DEBUGGER_ERROR_PT_NOT_SUPPORTED;
111 return FALSE;
112 }
113
114 //
115 // Allocate per-CPU ToPA / output / overflow buffers at PASSIVE_LEVEL
116 // (the contiguous-memory allocator cannot run from a DPC).
117 // PtAllocateAllCpuBuffers reads Cpu->Config.BufferSize, which was set
118 // either at module init (default 2MB) or by a prior !pt filter — so
119 // any pre-enable filter settings are preserved here.
120 //
122 {
123 //
124 // Roll back any partial allocations so we don't leak on next try.
125 //
127 PtOperationRequest->KernelStatus = DEBUGGER_ERROR_PT_NOT_SUPPORTED;
128 return FALSE;
129 }
130
131 //
132 // Broadcast enabling PT on all cores
133 //
135
136 //
137 // Set the flag to indicate that PT tracing is enabled
138 //
140
141 //
142 // Set successful status
143 //
145
146 return TRUE;
147}
#define DEBUGGER_ERROR_PT_ALREADY_ENABLED
error, PT is already enabled
Definition ErrorCodes.h:624
#define DEBUGGER_ERROR_PT_NOT_SUPPORTED
error, PT is not supported by the processor
Definition ErrorCodes.h:636
BOOLEAN PtAllocateAllCpuBuffers()
Allocate ToPA / output / overflow buffers for every active CPU.
Definition Pt.c:1051
BOOLEAN PtCheck()
Check whether Intel PT is supported on the current CPU. Mirrors LbrCheck — must be called once before...
Definition Pt.c:1012
VOID BroadcastEnablePtOnAllCores()
Routines to enable PT on all cores.
Definition Broadcast.c:78

◆ HyperTracePtFilter()

BOOLEAN HyperTracePtFilter ( HYPERTRACE_PT_OPERATION_PACKETS * Req)

Apply a new PT trace configuration (TraceUser / TraceKernel / TargetCr3 / BufferSize / NumAddrRanges + AddrRanges) on all cores.

Mirrors HyperTraceLbrUpdateFilterOptions / LbrFilter:

  • If PT is currently enabled, stop tracing on all cores, free and reallocate buffers (because BufferSize may have changed), push the new config into every per-CPU slot, and resume tracing on all cores.
  • If PT is currently disabled, only update the per-CPU config so that the next !pt enable picks it up.

Must be called at IRQL == PASSIVE_LEVEL because of the contiguous-memory allocator.

407{
408 PT_FILTER_OPTIONS FilterOptions = {0};
409 BOOLEAN WasEnabled = g_ProcessorTraceEnabled;
410 BOOLEAN BufferChanged = FALSE;
411 UINT64 ExistingSize = 0;
412 UINT32 Copy;
413
414 //
415 // Translate the user-mode packet into PT_FILTER_OPTIONS — the narrow
416 // surface PtFilter operates on. Default to user+kernel when the
417 // caller specified neither (matches LBR's empty-filter behaviour).
418 //
419 if (Req->TraceUser || Req->TraceKernel)
420 {
421 FilterOptions.TraceUser = (Req->TraceUser != 0) ? TRUE : FALSE;
422 FilterOptions.TraceKernel = (Req->TraceKernel != 0) ? TRUE : FALSE;
423 }
424 else
425 {
426 FilterOptions.TraceUser = TRUE;
427 FilterOptions.TraceKernel = TRUE;
428 }
429 FilterOptions.TargetCr3 = Req->TargetCr3;
430 FilterOptions.BufferSize = Req->BufferSize;
431 FilterOptions.NumAddrRanges = Req->NumAddrRanges;
432 if (FilterOptions.NumAddrRanges > PT_MAX_ADDR_RANGES)
433 FilterOptions.NumAddrRanges = PT_MAX_ADDR_RANGES;
434 for (Copy = 0; Copy < FilterOptions.NumAddrRanges; Copy++)
435 {
436 FilterOptions.AddrRanges[Copy] = Req->AddrRanges[Copy];
437 }
438
439 //
440 // Decide between fast (filter-only) and slow (buffer-resize) paths.
441 //
442 if (g_PtStateList != NULL)
443 {
444 ExistingSize = g_PtStateList[0].Config.BufferSize;
445 }
446 if (FilterOptions.BufferSize != 0 && FilterOptions.BufferSize != ExistingSize)
447 {
448 BufferChanged = TRUE;
449 }
450
451 if (!WasEnabled || BufferChanged)
452 {
453 //
454 // Slow path — PT is off and/or BufferSize changed. We have to
455 // free + reallocate per-CPU buffers at PASSIVE_LEVEL, so we
456 // can't go through DPC for the config seeding either.
457 //
458 PT_TRACE_CONFIG Cfg;
459
460 if (WasEnabled)
461 {
464 }
465
466 //
467 // Build a full PT_TRACE_CONFIG (defaults + the user-tunable
468 // fields from the request) and seed it on every CPU so the next
469 // PtAllocateAllCpuBuffers picks up the right BufferSize and
470 // PtEngineStart programs the right RTIT_CTL bits.
471 //
472 HyperTracePtBuildConfig(Req, &Cfg);
473 HyperTracePtSeedConfigOnAllCpus(&Cfg);
474
475 if (WasEnabled)
476 {
478 {
481 if (Req != NULL)
482 {
484 }
485 return FALSE;
486 }
487
489 }
490 }
491 else
492 {
493 //
494 // Fast filter-only path: PT is running and BufferSize is
495 // unchanged. Force FilterOptions.BufferSize=0 so PtFilter on each core
496 // keeps the buffer that's already allocated, then broadcast.
497 //
498 FilterOptions.BufferSize = 0;
499 BroadcastFilterPtOnAllCores(&FilterOptions);
500 }
501
502 if (Req != NULL)
503 {
505 }
506
507 return TRUE;
508}
UCHAR BOOLEAN
Definition BasicTypes.h:35
unsigned int UINT32
Definition BasicTypes.h:54
struct _PT_TRACE_CONFIG PT_TRACE_CONFIG
Intel PT trace configuration — what the user specifies.
#define PT_MAX_ADDR_RANGES
Definition PtDefinitions.h:53
struct _PT_FILTER_OPTIONS PT_FILTER_OPTIONS
Narrow input descriptor for PtFilter.
VOID BroadcastFilterPtOnAllCores(PT_FILTER_OPTIONS *FilterOptions)
Routines to apply a PT filter on all cores. The same Options pointer is passed to every per-core DPC;...
Definition Broadcast.c:159
VOID BroadcastFlushPtOnAllCores()
Routines to flush PT state on all cores.
Definition Broadcast.c:146
PT_PER_CPU * g_PtStateList
Dynamically allocated array of per-CPU Intel PT state. Sized to KeQueryActiveProcessorCount(0) at hyp...
Definition GlobalVariables.h:84
UINT32 TraceUser
Definition RequestStructures.h:1389
UINT32 TraceKernel
Definition RequestStructures.h:1390
UINT32 NumAddrRanges
Definition RequestStructures.h:1393
PT_ADDR_RANGE AddrRanges[PT_MAX_ADDR_RANGES]
Definition RequestStructures.h:1397
UINT64 TargetCr3
Definition RequestStructures.h:1391
UINT64 BufferSize
Definition RequestStructures.h:1392
UINT64 BufferSize
Definition Pt.h:45
UINT32 NumAddrRanges
Definition Pt.h:46
UINT64 TargetCr3
Definition Pt.h:44
BOOLEAN TraceUser
Definition Pt.h:42
BOOLEAN TraceKernel
Definition Pt.h:43
PT_ADDR_RANGE AddrRanges[PT_MAX_ADDR_RANGES]
Definition Pt.h:47

◆ HyperTracePtFlush()

BOOLEAN HyperTracePtFlush ( HYPERTRACE_PT_OPERATION_PACKETS * HyperTraceOperationRequest)

Flush PT trace state on all cores (free buffers).

Parameters
HyperTraceOperationRequest
Returns
BOOLEAN
340{
342 {
343 if (HyperTraceOperationRequest != NULL)
344 {
345 HyperTraceOperationRequest->KernelStatus = DEBUGGER_ERROR_PT_ALREADY_DISABLED;
346 }
347 return FALSE;
348 }
349
350 //
351 // Stop tracing on all cores via DPC (so MSRs are quiesced)
352 //
354
355 //
356 // Then free contiguous buffers at PASSIVE_LEVEL
357 //
359
360 //
361 // Reallocate buffers so subsequent !pt save / !pt dump / !pt enable
362 // continue to work — Flush in LBR keeps tracing alive, so we mirror
363 // that by leaving PT primed for the next !pt enable.
364 //
366 {
368 if (HyperTraceOperationRequest != NULL)
369 {
370 HyperTraceOperationRequest->KernelStatus = DEBUGGER_ERROR_PT_NOT_SUPPORTED;
371 }
373 return FALSE;
374 }
375
376 //
377 // Resume tracing on all cores
378 //
380
381 if (HyperTraceOperationRequest != NULL)
382 {
383 HyperTraceOperationRequest->KernelStatus = DEBUGGER_OPERATION_WAS_SUCCESSFUL;
384 }
385
386 return TRUE;
387}

◆ HyperTracePtMmap()

BOOLEAN HyperTracePtMmap ( HYPERTRACE_PT_MMAP_PACKETS * Req)

Map every per-CPU PT main output + overflow buffer into the calling user-mode process. See HYPERTRACE_PT_MMAP_PACKETS for the full lifetime / single-process contract.

517{
518 if (Req == NULL)
519 return FALSE;
520
521 Req->NumCpus = 0;
522
524 {
526 return FALSE;
527 }
528
530 {
532 return FALSE;
533 }
534
536 {
538 return FALSE;
539 }
540
542 return TRUE;
543}
#define DEBUGGER_ERROR_HYPERTRACE_NOT_INITIALIZED
error, HyperTrace is not initialized
Definition ErrorCodes.h:588
#define PT_MAX_CPUS_FOR_MMAP
Definition PtDefinitions.h:60
INT32 PtMmapAllCpuBuffersToUser(PT_USER_BUFFER_DESC *OutDescs, UINT32 MaxDescs, UINT32 *OutNumCpus)
Map every per-CPU PT main output buffer and 4 KB overflow page into the current user process as a sin...
Definition Pt.c:1127
BOOLEAN g_HyperTraceCallbacksInitialized
The flag indicating whether the hypertrace module callbacks is initialized or not.
Definition GlobalVariables.h:29
UINT32 KernelStatus
Definition RequestStructures.h:1438
PT_USER_BUFFER_DESC Cpus[PT_MAX_CPUS_FOR_MMAP]
Definition RequestStructures.h:1440
UINT32 NumCpus
Definition RequestStructures.h:1439

◆ HyperTracePtPause()

BOOLEAN HyperTracePtPause ( HYPERTRACE_PT_OPERATION_PACKETS * HyperTraceOperationRequest)

Pause PT tracing on every core. Buffers stay allocated and the per-CPU CTL is preserved, so HyperTracePtResume can restart the trace exactly where it stopped.

Parameters
HyperTraceOperationRequest
Returns
BOOLEAN
210{
212 {
213 if (HyperTraceOperationRequest != NULL)
214 {
215 HyperTraceOperationRequest->KernelStatus = DEBUGGER_ERROR_PT_ALREADY_DISABLED;
216 }
217 return FALSE;
218 }
219
221
222 if (HyperTraceOperationRequest != NULL)
223 {
224 HyperTraceOperationRequest->KernelStatus = DEBUGGER_OPERATION_WAS_SUCCESSFUL;
225 }
226
227 return TRUE;
228}
VOID BroadcastPausePtOnAllCores()
Routines to pause PT tracing on all cores.
Definition Broadcast.c:100

◆ HyperTracePtPerformOperation()

BOOLEAN HyperTracePtPerformOperation ( HYPERTRACE_PT_OPERATION_PACKETS * PtOperationRequest)

Perform actions related to HyperTrace PT.

Parameters
PtOperationRequest
Returns
BOOLEAN
554{
555 BOOLEAN Status = TRUE;
556
557 //
558 // Check if the hypertrace module is initialized before performing any operation
559 //
561 {
563 return FALSE;
564 }
565
566 //
567 // Perform the requested operation
568 //
569 switch (PtOperationRequest->PtOperationType)
570 {
572
573 LogInfo("HyperTrace: Enabling PT tracing...\n");
574
575 HyperTracePtEnable(PtOperationRequest);
576
577 break;
578
580
581 LogInfo("HyperTrace: Disabling PT tracing...\n");
582
583 HyperTracePtDisable(PtOperationRequest);
584
585 break;
586
588
589 LogInfo("HyperTrace: Pausing PT tracing...\n");
590
591 HyperTracePtPause(PtOperationRequest);
592
593 break;
594
596
597 LogInfo("HyperTrace: Resuming PT tracing...\n");
598
599 HyperTracePtResume(PtOperationRequest);
600
601 break;
602
604
605 LogInfo("HyperTrace: Snapshotting PT buffer sizes...\n");
606
607 HyperTracePtSize(PtOperationRequest);
608
609 break;
610
612
613 LogInfo("HyperTrace: Showing PT tracing...\n");
614
615 HyperTracePtDump(PtOperationRequest);
616
617 break;
618
620
621 LogInfo("HyperTrace: Flushing PT tracing...\n");
622
623 HyperTracePtFlush(PtOperationRequest);
624
625 break;
626
628
629 LogInfo("HyperTrace: Updating PT filter / config...\n");
630
631 HyperTracePtFilter(PtOperationRequest);
632
633 break;
634
635 default:
636 Status = FALSE;
638 break;
639 }
640
641 return Status;
642}
BOOLEAN HyperTracePtPause(HYPERTRACE_PT_OPERATION_PACKETS *HyperTraceOperationRequest)
Pause PT tracing on every core. Buffers stay allocated and the per-CPU CTL is preserved,...
Definition PtApi.c:209
BOOLEAN HyperTracePtSize(HYPERTRACE_PT_OPERATION_PACKETS *HyperTraceOperationRequest)
Snapshot the current PT output position on every core and write the per-CPU byte counts into HyperTra...
Definition PtApi.c:270
BOOLEAN HyperTracePtResume(HYPERTRACE_PT_OPERATION_PACKETS *HyperTraceOperationRequest)
Resume PT tracing on every core after a prior HyperTracePtPause.
Definition PtApi.c:238
BOOLEAN HyperTracePtFlush(HYPERTRACE_PT_OPERATION_PACKETS *HyperTraceOperationRequest)
Flush PT trace state on all cores (free buffers).
Definition PtApi.c:339
BOOLEAN HyperTracePtFilter(HYPERTRACE_PT_OPERATION_PACKETS *Req)
Apply a new PT trace configuration (TraceUser / TraceKernel / TargetCr3 / BufferSize / NumAddrRanges ...
Definition PtApi.c:406
BOOLEAN HyperTracePtDump(HYPERTRACE_PT_OPERATION_PACKETS *HyperTraceOperationRequest)
Dump PT trace state for HyperTrace.
Definition PtApi.c:308
BOOLEAN HyperTracePtEnable(HYPERTRACE_PT_OPERATION_PACKETS *PtOperationRequest)
Enable PT tracing for HyperTrace.
Definition PtApi.c:94
BOOLEAN HyperTracePtDisable(HYPERTRACE_PT_OPERATION_PACKETS *PtOperationRequest)
Disable PT tracing for HyperTrace.
Definition PtApi.c:157
#define DEBUGGER_ERROR_INVALID_HYPERTRACE_OPERATION_TYPE
error, invalid HyperTrace operation type is specified in the request
Definition ErrorCodes.h:594
@ HYPERTRACE_PT_OPERATION_REQUEST_TYPE_PAUSE
Definition RequestStructures.h:1356
@ HYPERTRACE_PT_OPERATION_REQUEST_TYPE_DUMP
Definition RequestStructures.h:1359
@ HYPERTRACE_PT_OPERATION_REQUEST_TYPE_ENABLE
Definition RequestStructures.h:1354
@ HYPERTRACE_PT_OPERATION_REQUEST_TYPE_FILTER
Definition RequestStructures.h:1361
@ HYPERTRACE_PT_OPERATION_REQUEST_TYPE_RESUME
Definition RequestStructures.h:1357
@ HYPERTRACE_PT_OPERATION_REQUEST_TYPE_SIZE
Definition RequestStructures.h:1358
@ HYPERTRACE_PT_OPERATION_REQUEST_TYPE_FLUSH
Definition RequestStructures.h:1360
@ HYPERTRACE_PT_OPERATION_REQUEST_TYPE_DISABLE
Definition RequestStructures.h:1355
HYPERTRACE_PT_OPERATION_REQUEST_TYPE PtOperationType
Definition RequestStructures.h:1383

◆ HyperTracePtResume()

BOOLEAN HyperTracePtResume ( HYPERTRACE_PT_OPERATION_PACKETS * HyperTraceOperationRequest)

Resume PT tracing on every core after a prior HyperTracePtPause.

Parameters
HyperTraceOperationRequest
Returns
BOOLEAN
239{
241 {
242 if (HyperTraceOperationRequest != NULL)
243 {
244 HyperTraceOperationRequest->KernelStatus = DEBUGGER_ERROR_PT_ALREADY_DISABLED;
245 }
246 return FALSE;
247 }
248
250
251 if (HyperTraceOperationRequest != NULL)
252 {
253 HyperTraceOperationRequest->KernelStatus = DEBUGGER_OPERATION_WAS_SUCCESSFUL;
254 }
255
256 return TRUE;
257}
VOID BroadcastResumePtOnAllCores()
Routines to resume PT tracing on all cores.
Definition Broadcast.c:111

◆ HyperTracePtSize()

BOOLEAN HyperTracePtSize ( HYPERTRACE_PT_OPERATION_PACKETS * HyperTraceOperationRequest)

Snapshot the current PT output position on every core and write the per-CPU byte counts into HyperTraceOperationRequest->BytesPerCpu. The returned counts are the decode window — bytes [0, BytesPerCpu[i]) in CPU i's user mapping currently hold valid trace data.

Parameters
HyperTraceOperationRequest
Returns
BOOLEAN
271{
272 UINT32 ProcessorsCount;
273
275 {
276 if (HyperTraceOperationRequest != NULL)
277 {
278 HyperTraceOperationRequest->KernelStatus = DEBUGGER_ERROR_PT_ALREADY_DISABLED;
279 }
280 return FALSE;
281 }
282
283 if (HyperTraceOperationRequest == NULL)
284 return FALSE;
285
286 ProcessorsCount = KeQueryActiveProcessorCount(0);
287 if (ProcessorsCount > PT_MAX_CPUS_FOR_MMAP)
288 ProcessorsCount = PT_MAX_CPUS_FOR_MMAP;
289
290 RtlZeroMemory(HyperTraceOperationRequest->BytesPerCpu,
291 sizeof(HyperTraceOperationRequest->BytesPerCpu));
292
293 BroadcastSizePtOnAllCores(HyperTraceOperationRequest->BytesPerCpu);
294
295 HyperTraceOperationRequest->NumCpus = ProcessorsCount;
296 HyperTraceOperationRequest->KernelStatus = DEBUGGER_OPERATION_WAS_SUCCESSFUL;
297 return TRUE;
298}
VOID BroadcastSizePtOnAllCores(UINT64 *Sizes)
Routines to snapshot per-CPU PT output positions. The DPC writes its own core's byte count into Sizes...
Definition Broadcast.c:124
UINT32 NumCpus
Definition RequestStructures.h:1402
UINT64 BytesPerCpu[PT_MAX_CPUS_FOR_MMAP]
Definition RequestStructures.h:1404