Closed mewais closed 2 years ago
For completeness, the data structure Message
is as follows:
class Message
{
public:
uint32_t destination;
uint32_t source;
uint32_t process;
uint32_t tag;
MessageType type; // This is just an enum
MessageDirection direction; // an enum too
uint32_t size;
void* data;
// constructor
Message(uint32_t host, uint32_t process, uint32_t tag, MessageType type, MessageDirection direction,
uint32_t size, void* data);
// constructor
Message(uint32_t source, uint32_t process, uint32_t tag, MessageType type);
};
Allocator needs to be supplied like this:
template <typename T,
typename Allocator = mpmc::AlignedAllocator<mpmc::Slot
On Fri, Jul 30, 2021 at 4:28 PM Mohammad Ewais @.***> wrote:
For completeness, the data structure Message is as follows:
class Message { public: uint32_t destination; uint32_t source; uint32_t process; uint32_t tag; MessageType type; // This is just an enum MessageDirection direction; // an enum too uint32_t size; void* data;
// constructor Message(uint32_t host, uint32_t process, uint32_t tag, MessageType type, MessageDirection direction, uint32_t size, void* data); // constructor Message(uint32_t source, uint32_t process, uint32_t tag, MessageType type);
};
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/rigtorp/MPMCQueue/issues/30#issuecomment-889931089, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABLO25YG2YR7TOTZLXZSSTT2KZKLANCNFSM5BH7QMZQ .
Hi, I am trying to use MPMCQueue with a custom allocator. But I am getting the two following errors:
This is how I define the allocator and pass it to MPMCQueue:
Then inside one of my classes I actually use it like so:
I don't actually use the queues yet (so no pushing or popping), I am getting these errors directly from this simple use.
Is there something I am missing or is this a bug?I am using Linux, gcc/g++ 11.1.0, and this is being compiled as C++17.