Percepio Trace Recorder v4.8.0.hotfix1
Loading...
Searching...
No Matches
Trace Multi-Core Event Buffer APIs

Data Structures

struct  TraceMultiCoreEventBuffer
 Trace Multi-Core Event Buffer Structure. More...
 

Macros

#define xTraceMultiCoreEventBufferAlloc(pxTraceMultiCoreEventBuffer, uiSize, ppvData)   xTraceEventBufferAlloc((pxTraceMultiCoreEventBuffer)->xEventBuffer[TRC_CFG_GET_CURRENT_CORE()], uiSize, ppvData)
 Allocates a data slot directly from the event buffer.
 
#define xTraceMultiCoreEventBufferAllocCommit(pxTraceMultiCoreEventBuffer, pvData, uiSize, piBytesWritten)   xTraceEventBufferAllocCommit((pxTraceMultiCoreEventBuffer)->xEventBuffer[TRC_CFG_GET_CURRENT_CORE()], pvData, uiSize, piBytesWritten)
 Commits the last allocated block to the event buffer.
 
#define xTraceMultiCoreEventBufferPush(pxTraceMultiCoreEventBuffer, pvData, uiSize, piBytesWritten)   xTraceEventBufferPush((pxTraceMultiCoreEventBuffer)->xEventBuffer[TRC_CFG_GET_CURRENT_CORE()], pvData, uiSize, piBytesWritten)
 Pushes data into multi-core trace event buffer.
 

Typedefs

typedef struct TraceMultiCoreEventBuffer TraceMultiCoreEventBuffer_t
 Trace Multi-Core Event Buffer Structure.
 

Functions

traceResult xTraceMultiCoreEventBufferTransferAll (const TraceMultiCoreEventBuffer_t *const pxTraceMultiCoreEventBuffer, int32_t *piBytesWritten)
 Transfer multi-core trace event buffer data through streamport.
 
traceResult xTraceMultiCoreEventBufferTransferChunk (const TraceMultiCoreEventBuffer_t *const pxTraceMultiCoreEventBuffer, uint32_t uiChunkSize, int32_t *piBytesWritten)
 Transfer multi-core trace event buffer data through streamport.
 
traceResult xTraceMultiCoreEventBufferClear (const TraceMultiCoreEventBuffer_t *const pxTraceMultiCoreEventBuffer)
 Clears all data from event buffer.
 

Detailed Description

Macro Definition Documentation

◆ xTraceMultiCoreEventBufferAlloc

#define xTraceMultiCoreEventBufferAlloc (   pxTraceMultiCoreEventBuffer,
  uiSize,
  ppvData 
)    xTraceEventBufferAlloc((pxTraceMultiCoreEventBuffer)->xEventBuffer[TRC_CFG_GET_CURRENT_CORE()], uiSize, ppvData)

Allocates a data slot directly from the event buffer.

Parameters
[in]pxTraceEventBufferPointer to initialized multi-core trace event buffer.
[in]uiSizeAllocation size
[out]ppvDataPointer that will hold the area from the buffer.
Return values
TRC_FAILFailure
TRC_SUCCESSSuccess

◆ xTraceMultiCoreEventBufferAllocCommit

#define xTraceMultiCoreEventBufferAllocCommit (   pxTraceMultiCoreEventBuffer,
  pvData,
  uiSize,
  piBytesWritten 
)    xTraceEventBufferAllocCommit((pxTraceMultiCoreEventBuffer)->xEventBuffer[TRC_CFG_GET_CURRENT_CORE()], pvData, uiSize, piBytesWritten)

Commits the last allocated block to the event buffer.

Parameters
[in]pxTraceEventBufferPointer to initialized multi-core trace event buffer.
Return values
TRC_FAILFailure
TRC_SUCCESSSuccess

◆ xTraceMultiCoreEventBufferPush

#define xTraceMultiCoreEventBufferPush (   pxTraceMultiCoreEventBuffer,
  pvData,
  uiSize,
  piBytesWritten 
)    xTraceEventBufferPush((pxTraceMultiCoreEventBuffer)->xEventBuffer[TRC_CFG_GET_CURRENT_CORE()], pvData, uiSize, piBytesWritten)

Pushes data into multi-core trace event buffer.

This routine attempts to push data into the multi-core trace event buffer. Selection of which core the data is pushed for is managed automatically through the TRC_CFG_GET_CURRENT_CORE macro which is defined on an RTOS basis.

Parameters
[in]pxTraceMultiCoreEventBufferPointer to initialized multi-core event buffer.
[in]pvDataPointer to data should be pushed into multi-core event buffer.
[in]uiSizeSize of data that should be pushed into multi-core trace event buffer.
[out]piBytesWrittenPointer to variable which the routine will write the number of bytes that was pushed into the multi-core trace event buffer.
Return values
TRC_FAILFailure
TRC_SUCCESSSuccess

Function Documentation

◆ xTraceMultiCoreEventBufferClear()

traceResult xTraceMultiCoreEventBufferClear ( const TraceMultiCoreEventBuffer_t *const  pxTraceMultiCoreEventBuffer)

Clears all data from event buffer.

Parameters
[in]pxTraceMultiCoreEventBufferPointer to initialized multi-core trace event buffer.
Return values
TRC_FAILFailure
TRC_SUCCESSSuccess

◆ xTraceMultiCoreEventBufferTransferAll()

traceResult xTraceMultiCoreEventBufferTransferAll ( const TraceMultiCoreEventBuffer_t *const  pxTraceMultiCoreEventBuffer,
int32_t *  piBytesWritten 
)

Transfer multi-core trace event buffer data through streamport.

This routine will attempt to transfer all existing data in the multi-core trace event buffer through the streamport. New data pushed to the trace event buffer during the execution of this routine will not be transfered to

Parameters
[in]pxTraceMultiCoreEventBufferPointer to initialized multi-core event buffer.
[out]piBytesWrittenPointer to variable which the routine will write the number of bytes that was pushed into the multi-core trace event buffer.
Return values
TRC_FAILFailure
TRC_SUCCESSSuccess

◆ xTraceMultiCoreEventBufferTransferChunk()

traceResult xTraceMultiCoreEventBufferTransferChunk ( const TraceMultiCoreEventBuffer_t *const  pxTraceMultiCoreEventBuffer,
uint32_t  uiChunkSize,
int32_t *  piBytesWritten 
)

Transfer multi-core trace event buffer data through streamport.

This routine will attempt to transfer a chunk of stored event data in the multi-core trace event buffer. Note that the chunk size is on a per-core basis with each core event buffer attempting to push up to uiChunkSize of bytes.

Parameters
[in]pxTraceMultiCoreEventBufferPointer to initialized multi-core event buffer.
[in]uiChunkSizeNumber of bytes to attempt to transfer per core.
[out]piBytesWrittenPointer to variable which the routine will write the number of bytes that was pushed into the multi-core trace event buffer.