nn::nex::PacketBufferManager::GetSimpleUnitHeapParam Member Function

Syntax

static qBool GetSimpleUnitHeapParam(
     qUnsignedInt32 poolSize,
     qUnsignedInt32 avgSendSize,
     qVector< UnitHeapParam > & param
);

Parameters

Name Description
in poolSize Specifies the size of the packet buffer pool.
in avgSendSize Average size of the data sent by the application.
out param Returns the structural information for the unit heap for the payload.

Return Values



Value Description
true Unit heap structure calculation succeeded.
false The average send data size is 0 or exceeds 1364, or the pool size is too small.

Description

Calculates and returns the simple structure for the unit heap based on the packet buffer pool size and the average send data size.

Simple structures are calculated to fit in a size of a packet buffer pool for which the memory totals for the unit heaps for the payload and for the packet management objects were specified. Half of the memory used by the unit heap for payloads is allocated as a unit heap the size of the average send data, and the remaining half is allocated as an unit heap of the maximum size (1364). Note that the unit size takes the header attached inside NEX, and the average send data send size is increased by 80 and is revised to a value that is a multiple of 4.

Because only packet buffers of 1364 bytes or less are allocated by the packet buffer pool, give an average send data size that excludes send data that exceeds 1364 bytes.

Perform tuning matching the application based on the structure obtained with this function. The pool size must be set to 64 bytes or higher.

Revision History

2012/11/27
Initial version.

CONFIDENTIAL