function createBenchmark( iter, len ) {
	var tmp;
	var out;
	var sa;
	var sb;
	var a;
	var b;
	var x;
	var i;
	var j;

	a = 1.0;
	b = 10.0;

	x = [];
	for ( i = 0; i < iter; i++ ) {
		tmp = new Float64Array( len );
		for ( j = 0; j < len; j++ ) {
			sa = (b-a) * (j/len);
			sb = sa / 2.0;
			tmp[ j ] = floor( uniform( a+sa, b+sb ) );
		}
		x.push( tmp );
	}
	out = new Float64Array( len );

	return benchmark;

	function benchmark( b ) {
		var xc;
		var y;
		var i;

		xc = x.slice();
		for ( i = 0; i < iter; i++ ) {
			xc[ i ] = dcopy( len, x[ i ], 1, new Float64Array( len ), 1 );
		}
		b.tic();
		for ( i = 0; i < b.iterations; i++ ) {
			y = dsort2hp( len, 1, xc[ i ], 1, out, 1 );
			if ( isnan( y[ i%len ] ) ) {
				b.fail( 'should not return NaN' );
			}
		}
		b.toc();
		if ( isnan( y[ i%len ] ) ) {
			b.fail( 'should not return NaN' );
		}
		b.pass( 'benchmark finished' );
		b.end();
	}
}
Create a benchmark function.

@private
@param {PositiveInteger} iter - number of iterations
@param {PositiveInteger} len - array length
@returns {Function} benchmark function