NeoPZ
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
TPZDohrAssembleList< TVar > Struct Template Reference

List of items to assembling using Dohrmann algorithm. More...

#include <tpzdohrassemblelist.h>

Collaboration diagram for TPZDohrAssembleList< TVar >:
[legend]

Public Member Functions

 TPZDohrAssembleList (int numitems, TPZFMatrix< TVar > &output, TPZAutoPointer< TPZDohrAssembly< TVar > > assembly)
 Constructor indicating the number of items that will be assembled and the target matrix. More...
 
 ~TPZDohrAssembleList ()
 destructor More...
 
void AddItem (TPZAutoPointer< TPZDohrAssembleItem< TVar > > assembleItem)
 Add an item to the list in a thread safe way. More...
 
TPZAutoPointer< TPZDohrAssembleItem< TVar > > PopItem ()
 Remove an item from the list. More...
 

Static Public Member Functions

static void * Assemble (void *voidptr)
 Procedure which performs the assembly process. More...
 

Public Attributes

int fNumItems
 The number of items that will be assembled before returning. More...
 
TPZSemaphore fSemaphore
 Semaphore (to wake up assembly thread) More...
 
pthread_mutex_t fListAccessLock
 This is the mutex which controls the access to the list. More...
 
pthread_mutex_t fAssemblyLock
 This is the mutex which controls the assembly. More...
 
std::list< TPZAutoPointer< TPZDohrAssembleItem< TVar > > > fWork
 List of objects needed to be assembled. More...
 
TPZAutoPointer< TPZDohrAssembly< TVar > > fAssembleIndexes
 Assembly indexes. More...
 
TPZFMatrix< TVar > * fOutput
 Target Matrix. More...
 

Detailed Description

template<class TVar>
struct TPZDohrAssembleList< TVar >

List of items to assembling using Dohrmann algorithm.

Definition at line 44 of file tpzdohrassemblelist.h.

Constructor & Destructor Documentation

◆ TPZDohrAssembleList()

template<class TVar >
TPZDohrAssembleList< TVar >::TPZDohrAssembleList ( int  numitems,
TPZFMatrix< TVar > &  output,
TPZAutoPointer< TPZDohrAssembly< TVar > >  assembly 
)

Constructor indicating the number of items that will be assembled and the target matrix.

Definition at line 11 of file tpzdohrassemblelist.cpp.

References TPZDohrAssembleList< TVar >::fAssemblyLock, TPZDohrAssembleList< TVar >::fListAccessLock, and PZ_PTHREAD_MUTEX_INIT.

◆ ~TPZDohrAssembleList()

template<class TVar >
TPZDohrAssembleList< TVar >::~TPZDohrAssembleList ( )

Member Function Documentation

◆ AddItem()

template<class TVar >
void TPZDohrAssembleList< TVar >::AddItem ( TPZAutoPointer< TPZDohrAssembleItem< TVar > >  assembleItem)

◆ Assemble()

template<class TVar >
void * TPZDohrAssembleList< TVar >::Assemble ( void *  voidptr)
static

◆ PopItem()

template<class TVar >
TPZAutoPointer< TPZDohrAssembleItem< TVar > > TPZDohrAssembleList< TVar >::PopItem ( )

Member Data Documentation

◆ fAssembleIndexes

template<class TVar>
TPZAutoPointer<TPZDohrAssembly<TVar> > TPZDohrAssembleList< TVar >::fAssembleIndexes

Assembly indexes.

Definition at line 64 of file tpzdohrassemblelist.h.

Referenced by TPZDohrAssembleList< TVar >::Assemble().

◆ fAssemblyLock

template<class TVar>
pthread_mutex_t TPZDohrAssembleList< TVar >::fAssemblyLock

◆ fListAccessLock

template<class TVar>
pthread_mutex_t TPZDohrAssembleList< TVar >::fListAccessLock

◆ fNumItems

template<class TVar>
int TPZDohrAssembleList< TVar >::fNumItems

The number of items that will be assembled before returning.

Definition at line 50 of file tpzdohrassemblelist.h.

Referenced by TPZDohrAssembleList< TVar >::Assemble(), and TPZDohrAssembleList< TVar >::PopItem().

◆ fOutput

template<class TVar>
TPZFMatrix<TVar>* TPZDohrAssembleList< TVar >::fOutput

Target Matrix.

Definition at line 66 of file tpzdohrassemblelist.h.

Referenced by TPZDohrAssembleList< TVar >::Assemble().

◆ fSemaphore

template<class TVar>
TPZSemaphore TPZDohrAssembleList< TVar >::fSemaphore

Semaphore (to wake up assembly thread)

Definition at line 52 of file tpzdohrassemblelist.h.

Referenced by TPZDohrAssembleList< TVar >::AddItem(), and TPZDohrAssembleList< TVar >::Assemble().

◆ fWork

template<class TVar>
std::list<TPZAutoPointer<TPZDohrAssembleItem<TVar> > > TPZDohrAssembleList< TVar >::fWork

List of objects needed to be assembled.

Definition at line 58 of file tpzdohrassemblelist.h.

Referenced by TPZDohrAssembleList< TVar >::AddItem(), and TPZDohrAssembleList< TVar >::PopItem().


The documentation for this struct was generated from the following files: