[[TracNav(WARPLab/TOC)]] = WARPLab: Sample Buffer Sizes = WARPLab 7.5 (and later versions of WARPLab) for WARP v3 supports sample storage in the board's 2GB DDR3 DRAM. As a result WARPLab 7.5 can be used with much longer waveforms than previous releases, which were limited to the FPGA's on-chip BRAM. Unfortunately, due to hardware limitations, WARP v2 can only support the same number of samples as previous WARPLab versions. The table below summarizes the maximum Tx and Rx waveform lengths for WARP v3. ||= '''WARPLab Ver''' =||= '''Tx Samps''' =||= '''Tx Time''' =||= '''Rx Samps''' =||= '''Rx Time''' =|| || 7.5 (2RF) || 112M || 2.93 sec || 128M || 3.35 sec || || 7.5 (4RF) || 56M || 1.46 sec || 64M || 1.67 sec || || 7.4 || 32k || 819.2 µsec || 32k || 819.2 µsec || The table below summarizes the maximum Tx and Rx waveform lengths for WARP v2. ||= '''WARPLab Ver''' =||= '''Tx Samps''' =||= '''Tx Time''' =||= '''Rx Samps''' =||= '''Rx Time''' =|| || 7.5 || 16k || 409.6 µsec || 16k || 409.6 µsec || || 7.4 || 16k || 409.6 µsec || 16k || 409.6 µsec || Notes: * The waveform durations above assume 40MHz sampling at the ADCs and DACs, the default in the WARPLab 7.5 reference design hardware * The '''k''' and '''M''' prefixes represent factors of 2^10^ and 2^20^, respectively == Performance Considerations == With the extra buffer space that the hardware design is capable of, the chief limitation on usable buffer sizes shifts burden to the user's PC. Each sample is represented as a complex double precision floating point number in a MATLAB, occupying 16 bytes in memory. The table below shows the storage size of various sample vectors, up to the new maximum vector lengths in WARPLab 7.5. Note these sizes are how much RAM is required to store each vector in the MATLAB workspace. Retrieving the vector and processing the vector requires additional RAM. Depending on the amount of RAM on the host PC and what other programs are currently running, a user should limit the number of samples they are working with to stay under the total available memory. If MATLAB's memory utilization rises too far, it is common that the MATLAB application will stall while the OS swaps memory to disk. On Windows the MATLAB {{{memory}}} command will summarize the available RAM and largest supported array size in your MATLAB instance. ||= Sample Vector Length =||= Occupied Memory =|| || 32 kSamp || 512 kByte || || 256 kSamp || 4 MByte || || 2 MSamp || 32 MByte || || 16 MSamp || 256 MByte || || 128 MSamp || 2 GByte || One thing to note is that these are steady state memory figures for a request of a single interface. Peak memory usages may be greater than this due to MATLAB's internal memory management when building a matrix of samples retrieved from multiple RF interfaces. The worst-case memory usage in WARPLab 7.5 occurs during a {{{read_iq}}} command when reading samples from multiple RF interfaces. The peak memory usage (during command execution) and stead-state (after the command returns) are functions of the number of RF interfaces being processed. * Peak memory usage = (Num Interfaces + N) * (Occupied Memory for the Sample Vector Length) * N = 0 for 1 RF interface * N = 1 for >1 RF interface * Steady state memory usage = (Num Interfaces) * (Occupied Memory for the Sample Vector Length) For example, when reading 32M samples from 4 interfaces, the final memory usage would be 2 GBytes (4 Interfaces * 512 MBytes / Interface) and a peak memory usage of 2.5 GBytes during the {{{read_iq}}} command execution. A future (API-compatible) revision of the WARPLab mex transport implementation will reduce the peak memory usage to the steady state level.