views:

220

answers:

2

I'd like to test the correctness and the completeness of an implementation of the BSP API. The test set has to be cross-compiled for an ARM sam7x.

+1  A: 

I don't know if this would be of any interest to you, but here are two links to presentations from NYC BSD Conference 2008: Detecting TCP regressions with tcpdiff (FreeBSD) and An introduction to the Automated Testing Framework (ATF) for NetBSD. Both were pretty good.

Nikolai N Fetissov
A: 

There is a public domain Benchmarking tool for TCP and UDP performance measurement.

It has a some amount of control available. You might be able to use it for testing.
Remember, this is not testing the API, but the implementation performance, you will need more than this.

The PCATTCP tool includes several options that are controlled by parameters passed on the command line when the program is started. To see the available options, run the PCATTCP application with the "-h" option. Here is what you would see:

pcattcp -h
PCAUSA Test TCP Utility V2.01.01.08

Usage: pcattcp -t [-options] host [ < in ]
   pcattcp -r [-options > out]

Common options:
-l ##  length of bufs read from or written to network (default 8192)
-u     use UDP instead of TCP
-p ##  port number to send to or listen at (default 5001)
-s     toggle sinkmode (enabled by default)

        sinkmode enabled:
           -t: source (transmit) fabricated pattern
           -r: sink (discard) all received data
        sinkmode disabled:
           -t: reads data to be transmitted from stdin
           -r: writes received data to stdout

-A     align the start of buffers to this modulus (default 16384)
-O     start buffers at this offset from the modulus (default 0)
-v     verbose: print more statistics
-d     set SO_DEBUG socket option
-b ##  set socket buffer size (if supported)
-f X   format for rate: k,K = kilo{bit,byte}; m,M = mega; g,G = giga
-c       -t: send continuously
         -r: accept multiple connections sequentially
-R     concurrent TCP/UDP multithreaded receiver

.

Options specific to -t:
-n ##  number of source bufs written to network (default 2048)
-D     don't buffer TCP writes (sets TCP_NODELAY socket option)
-w ##  milliseconds of delay before each write (default 0)
-L ##  desired transmit data rate in bytes/second


Options specific to -r:
-B     for -s, only output full blocks as specified by -l (for TAR)
-T     "touch": access each byte as it's read
nik