23 lines
707 B
C++
23 lines
707 B
C++
#include "stagingBuffer.h"
|
|
#include <unistd.h>
|
|
|
|
namespace smo {
|
|
namespace stim_buff {
|
|
|
|
// Static defaults for io_uring
|
|
const StagingBuffer::IOEngineConstraints
|
|
StagingBuffer::IOEngineConstraints::ioUringConstraints(
|
|
static_cast<size_t>(sysconf(_SC_PAGE_SIZE)), // slotStartAlignmentByteVal (page alignment for DMA)
|
|
1472 // slotPadToNBytes (MTU 1500 - UDP/IP header 28)
|
|
);
|
|
|
|
// Static defaults for OpenCL input
|
|
const StagingBuffer::IOEngineConstraints
|
|
StagingBuffer::IOEngineConstraints::openClInputConstraints(
|
|
static_cast<size_t>(sysconf(_SC_PAGE_SIZE)), // slotStartAlignmentByteVal (page alignment)
|
|
sizeof(void *) // slotPadToNBytes (pointer size)
|
|
);
|
|
|
|
} // namespace stim_buff
|
|
} // namespace smo
|