6 #ifndef _JOINALGO_NPJ_NPJ_H_
7 #define _JOINALGO_NPJ_NPJ_H_
39 size_t sLen = 0, rLen = 0;
41 MultiThreadHashTablePtr table =
nullptr;
43 BarrierPtr buildBar =
nullptr;
44 std::shared_ptr<std::thread> threadPtr;
69 MultiThreadHashTablePtr _table,
83 void waitBuildBar(
void) {
85 buildBar->arrive_and_wait();
97 vector<NPJ_thread> workers;
145 typedef std::shared_ptr<NPJ> NPJPtr;
146 #define newNPJ() make_shared<NPJ>()
203 typedef std::shared_ptr<NPJSingle> NPJSinglePtr;
204 #define newNPJSingle() make_shared<NPJSingle>()
The base class and abstraction of C++20 thread, and it can be derived into other threads.
Definition: AbstractC20Thread.h:28
The abstraction to describe a join algorithm, providing virtual function of join.
Definition: AbstractJoinAlgo.h:28
void setAlgoName(string name)
set the name of algorithm
Definition: AbstractJoinAlgo.h:101
The top class package of single threadNPJ, providing a "join function".
Definition: NPJ.h:152
The thread used by NPJ.
Definition: NPJ.h:36
The top class package of NPJ, providing a "join function".
Definition: NPJ.h:94
std::shared_ptr< class Tuple > TuplePtr
The class to describe a shared pointer to Tuple.
Definition: Types.h:150
std::shared_ptr< INTELLI::SPSCQueue< INTELLI::TuplePtr > > TuplePtrQueue
To describe a queue of TuplePtr under SPSCQueue.
Definition: Types.h:228
virtual size_t join(TuplePtrQueue ts, TuplePtrQueue tr, int threads=1)
The function to execute join.
void inlineMain()
The 'main' function of NPJ thread.
virtual size_t join(TuplePtrQueue ts, TuplePtr tr, int threads=1)
The function to execute join, batch of one, tuple of another.
virtual size_t join(TuplePtr *ts, TuplePtr tr, size_t tsLen, int threads=1)
The function to execute join, batch of one, tuple of another.
virtual size_t join(TuplePtr *ts, TuplePtr *tr, size_t tsLen, size_t trLen, int threads=1)
The function to execute join, legacy way.
virtual size_t join(TuplePtrQueue ts, TuplePtrQueue tr, int threads=1)
The function to execute join.
virtual size_t join(TuplePtr *ts, TuplePtr *tr, size_t tsLen, size_t trLen, int threads=1)
The function to execute join, legacy way.
void init(TuplePtr *_ts, TuplePtr *_tr, size_t _sLen, size_t _rLen, int _cpu, MultiThreadHashTablePtr _table, BarrierPtr bar)
THe init function.
Definition: NPJ.h:64
virtual size_t join(TuplePtrQueue ts, TuplePtr tr, int threads=1)
The function to execute join, batch of one, tuple of another.
virtual size_t join(TuplePtr *ts, TuplePtr tr, size_t tsLen, int threads=1)
The function to execute join, batch of one, tuple of another.
Definition: DatasetTool.h:10