command-line macros and macros for porting QP More...
Go to the source code of this file.
Namespaces | |
QP | |
namespace associated with the QP/C++ framework | |
Macros | |
#define | Q_NASSERT |
The preprocessor switch to disable checking assertions. More... | |
#define | Q_EVT_CTOR |
The preprocessor switch to activate the event-constructors and destructors. More... | |
#define | Q_SPY |
The preprocessor switch to activate the QS software tracing instrumentation in the code. More... | |
#define | Q_UTEST |
The preprocessor switch to activate the QUTest unit testing instrumentation in the code. More... | |
#define | QF_THREAD_TYPE void* |
This macro defines the type of the thread handle used for AOs. More... | |
#define | QF_EQUEUE_TYPE QEQueue |
This macro defines the type of the event-queue used for AOs. More... | |
#define | QF_OS_OBJECT_TYPE pthread_cond_t |
This macro defines the type of the OS-Object used for blocking. More... | |
#define | QACTIVE_EQUEUE_WAIT_(me_) Q_ASSERT((me_)->m_eQueue.m_frontEvt != nullptr) |
Platform-dependent macro defining how QF should block the calling task when the QF native queue is empty. More... | |
#define | QACTIVE_EQUEUE_SIGNAL_(me_) |
Platform-dependent macro defining how QF should signal the active object task that an event has just arrived. More... | |
#define | QF_EPOOL_TYPE_ QMPool |
This macro defines the type of the event pool used in this QF port. More... | |
#define | QK_ON_CONTEXT_SW |
This macro enables calling the QK context-switch callback QK_onContextSw() More... | |
#define | QXK_ON_CONTEXT_SW |
This macro enables calling the QXK context-switch callback QXK_onContextSw() More... | |
#define | QF_EPOOL_INIT_(p_, poolSto_, poolSize_, evtSize_) (p_).init((poolSto_), (poolSize_), static_cast<QMPoolSize>(evtSize_)) |
Platform-dependent macro defining the event pool initialization. More... | |
#define | QF_EPOOL_EVENT_SIZE_(p_) static_cast<uint32_t>((p_).getBlockSize()) |
Platform-dependent macro defining how QF should obtain the event pool block-size. More... | |
#define | QF_EPOOL_GET_(p_, e_, m_, qs_id_) ((e_) = static_cast<QEvt *>((p_).get((m_), (qs_id_)))) |
Platform-dependent macro defining how QF should obtain an event e_ from the event pool p_. More... | |
#define | QF_EPOOL_PUT_(p_, e_, qs_id_) ((p_).put((e_), (qs_id_))) |
Platform-dependent macro defining how QF should return an event e_ to the event pool p_. More... | |
#define | WIN32_GUI |
Macro that should be defined (typically on the compiler's command line) in the Win32-GUI applications that use the Win32 API (Windows) or Win32-QV (Windows with QV) ports. More... | |
command-line macros and macros for porting QP
Definition in file macros.hpp.
#define Q_NASSERT |
The preprocessor switch to disable checking assertions.
When defined, Q_NASSERT disables the following macros Q_ASSERT, Q_REQUIRE, Q_ENSURE, Q_INVARIANT, Q_ERROR as well as Q_ASSERT_ID, Q_REQUIRE_ID, Q_ENSURE_ID, Q_INVARIANT_ID, and Q_ERROR_ID do NOT evaluate the test condition passed as the argument to these macros.
Definition at line 17 of file macros.hpp.
#define Q_EVT_CTOR |
The preprocessor switch to activate the event-constructors and destructors.
When Q_EVT_CTOR is defined (typically in the qep_port.hpp header file), QP::QEvt becomes a class with constructor and virtual destructor. More importantly, the subclasses of QEvt (your custom events) can have non-default constructors and destructors. These constructors are then called when events are created (e.g., with Q_NEW()) and the destrucor is invoked before recycling the event with QP::QF::gc().
Definition at line 28 of file macros.hpp.
#define Q_SPY |
The preprocessor switch to activate the QS software tracing instrumentation in the code.
When defined, Q_SPY activates the QS software tracing instrumentation. When Q_SPY is not defined, the QS instrumentation in the code does not generate any code.
Definition at line 36 of file macros.hpp.
#define Q_UTEST |
The preprocessor switch to activate the QUTest unit testing instrumentation in the code.
Definition at line 43 of file macros.hpp.
#define QF_THREAD_TYPE void* |
This macro defines the type of the thread handle used for AOs.
Definition at line 46 of file macros.hpp.
#define QF_EQUEUE_TYPE QEQueue |
This macro defines the type of the event-queue used for AOs.
Definition at line 49 of file macros.hpp.
#define QF_OS_OBJECT_TYPE pthread_cond_t |
This macro defines the type of the OS-Object used for blocking.
Definition at line 61 of file macros.hpp.
#define QACTIVE_EQUEUE_WAIT_ | ( | me_ | ) | Q_ASSERT((me_)->m_eQueue.m_frontEvt != nullptr) |
Platform-dependent macro defining how QF should block the calling task when the QF native queue is empty.
Definition at line 71 of file macros.hpp.
#define QACTIVE_EQUEUE_SIGNAL_ | ( | me_ | ) |
Platform-dependent macro defining how QF should signal the active object task that an event has just arrived.
The macro is necessary only when the native QF event queue is used. The signaling of task involves unblocking the task if it is blocked.
Definition at line 87 of file macros.hpp.
#define QF_EPOOL_TYPE_ QMPool |
This macro defines the type of the event pool used in this QF port.
Definition at line 102 of file macros.hpp.
#define QK_ON_CONTEXT_SW |
This macro enables calling the QK context-switch callback QK_onContextSw()
Definition at line 106 of file macros.hpp.
#define QXK_ON_CONTEXT_SW |
This macro enables calling the QXK context-switch callback QXK_onContextSw()
Definition at line 110 of file macros.hpp.
#define QF_EPOOL_INIT_ | ( | p_, | |
poolSto_, | |||
poolSize_, | |||
evtSize_ | |||
) | (p_).init((poolSto_), (poolSize_), static_cast<QMPoolSize>(evtSize_)) |
Platform-dependent macro defining the event pool initialization.
Definition at line 117 of file macros.hpp.
#define QF_EPOOL_EVENT_SIZE_ | ( | p_ | ) | static_cast<uint32_t>((p_).getBlockSize()) |
Platform-dependent macro defining how QF should obtain the event pool block-size.
Definition at line 126 of file macros.hpp.
#define QF_EPOOL_GET_ | ( | p_, | |
e_, | |||
m_, | |||
qs_id_ | |||
) | ((e_) = static_cast<QEvt *>((p_).get((m_), (qs_id_)))) |
Platform-dependent macro defining how QF should obtain an event e_ from the event pool p_.
Definition at line 134 of file macros.hpp.
#define QF_EPOOL_PUT_ | ( | p_, | |
e_, | |||
qs_id_ | |||
) | ((p_).put((e_), (qs_id_))) |
Platform-dependent macro defining how QF should return an event e_ to the event pool p_.
Definition at line 143 of file macros.hpp.
#define WIN32_GUI |
Macro that should be defined (typically on the compiler's command line) in the Win32-GUI applications that use the Win32 API (Windows) or Win32-QV (Windows with QV) ports.
Definition at line 148 of file macros.hpp.