OpenMP Runtime
Defines | Functions | Variables
tomp_qmss.c File Reference
#include "tomp_init.h"
#include "tomp_qmss.h"
#include "tomp_qmss_api.h"
#include "tomp_util.h"
#include "tomp_log.h"
Include dependency graph for tomp_qmss.c:

Defines

#define FREE_QID   (TOMP_HW_QUEUE_BASE_IDX)
#define IMPLICIT_TASK_QID   (TOMP_HW_QUEUE_BASE_IDX + 1)
#define EXIT_QID   (TOMP_HW_QUEUE_BASE_IDX + 2)
#define EXPLICIT_TASK_BASE_QID   (TOMP_HW_QUEUE_BASE_IDX + 3)
#define SELECT_QID(a, b)   ((a) == QMSS_PARAM_NOT_SPECIFIED ? (a) : (b))

Functions

static void tomp_initRegionConfig (Qmss_MemRegInfo *memRegInfo, bool memRegionInitialized)
 Initialize QMSS memory region for OpenMP.
static bool tomp_initQmss (Qmss_MemRegInfo *regionConfigTbl, uint8_t *extLinkTbl)
 Initialize QMSS for OpenMP.
static tomp_queue_t tomp_initFreeDesc (Qmss_MemRegInfo *memRegInfo, int32_t qid)
 Initialize the free queue.
static void tomp_resetQueues (void)
 Reset all queues used by OpenMP.
static bool tomp_openQueues (Qmss_MemRegInfo *memRegInfo)
 Open all queues required by OpenMP and populate the free queue.
void tomp_closeQueues (void)
 Close and reset all queues used by OpenMP.
bool tomp_initGlobalNRT (bool memRegionInitialized)
 Initializes the NRT (QMSS sub system) for OpenMP.
void tomp_exitGlobalNRT (void)
 Close queues and exit QMSS.
bool tomp_initLocalNRT (void)
 Per-core initialization for QMSS.
tomp_queue_t tomp_queueOpen (int32_t qid)
 Open a queue specified by qid.
void __TI_omp_get_qmss_memory_regions (Qmss_MemRegInfo *memRegions, int *memRegionCount)
 API to get information on Memory regions used by the OpenMP runtime.
void __TI_omp_update_qmss_memory_regions (Qmss_MemRegInfo *memRegions, int memRegionCount)
 API to update the OpenMP runtime with memRegion and startIndex allocated by the caller.

Variables

tomp_Queues tomp_queues
Qmss_MemRegInfo tomp_qmssMemRegInfo
uint8_t tomp_svEventBufMem [TOMP_EVENT_NUM *TOMP_EVENT_BUF_SIZE]
Qmss_GlobalConfigParams qmssGblCfgParams []

Detailed Description


Function Documentation

void tomp_exitGlobalNRT ( void  )

Close queues and exit QMSS.

Called by master core only

Here is the call graph for this function:

Here is the caller graph for this function:

bool tomp_initGlobalNRT ( bool  memRegionInitialized)

Initializes the NRT (QMSS sub system) for OpenMP.

Called by the master core only. Sets up the memory region, initializes QMSS (if required) and opens the queues required by OpenMP.

NOTE: This function must be called BEFORE tomp_dispatch_once is called on the worker cores.

Here is the call graph for this function:

Here is the caller graph for this function:

bool tomp_initQmss ( Qmss_MemRegInfo *  regionConfigTbl,
uint8_t *  extLinkTbl 
) [static]

Initialize QMSS for OpenMP.

If an external application or OpenCL has already initialized QMSS, this function is not called by the OpenMP runtime.

Here is the caller graph for this function:

void tomp_initRegionConfig ( Qmss_MemRegInfo *  memRegInfo,
bool  memRegionInitialized 
) [static]

Initialize QMSS memory region for OpenMP.

Parameters:
memRegInfopointer to memory region info
memRegionInitializedif true, indicated that the memRegion and startIndex have already been set and must not be initialized. Used in the mode where the application/OpenCL initializes QMSS

Here is the caller graph for this function:

tomp_queue_t tomp_queueOpen ( int32_t  qid)

Open a queue specified by qid.

If the queue is already open, report error

Here is the call graph for this function:

Here is the caller graph for this function:


Variable Documentation

Qmss_MemRegInfo tomp_qmssMemRegInfo

Memory region used by the OpenMP Runtime

Queues used by the OpenMP Runtime

uint8_t tomp_svEventBufMem[TOMP_EVENT_NUM *TOMP_EVENT_BUF_SIZE]

Buffer used for allocations

 All Classes Files Functions Variables Typedefs Enumerations Defines