framesync64/bench: cleaning up benchmark, reducing verbosity
@@ -40,7 +40,6 @@ static int callback(unsigned char * _header,
framesyncstats_s _stats,
void * _userdata)
{
- //printf("callback invoked, payload valid: %s\n", _payload_valid ? "yes" : "no");
framedata * fd = (framedata*) _userdata;
fd->num_frames_detected += 1;
fd->num_frames_valid += _payload_valid ? 1 : 0;
@@ -57,7 +56,6 @@ void benchmark_framesync64(
unsigned long int i;
framegen64 fg = framegen64_create();
- framegen64_print(fg);
// frame data
unsigned char header[8] = {0, 1, 2, 3, 4, 5, 6, 7};
@@ -69,7 +67,6 @@ void benchmark_framesync64(
// create framesync64 object
framesync64 fs = framesync64_create(callback,(void*)&fd);
- framesync64_print(fs);
// generate the frame
//unsigned int frame_len = framegen64_getframelen(fg);
@@ -81,23 +78,21 @@ void benchmark_framesync64(
for (i=0; i<frame_len; i++)
frame[i] += 0.01f*(randnf() + _Complex_I*randnf()) * M_SQRT1_2;
- //
// start trials
- //
getrusage(RUSAGE_SELF, _start);
for (i=0; i<(*_num_iterations); i++) {
framesync64_execute(fs, frame, frame_len);
}
getrusage(RUSAGE_SELF, _finish);
-
+ framegen64_destroy(fg);
+ framesync64_destroy(fs);
+#if 0
fd.num_frames_tx = *_num_iterations;
printf(" frames detected/valid/transmitted : %6u / %6u / %6u\n",
fd.num_frames_detected,
fd.num_frames_valid,
fd.num_frames_tx);
-
- framegen64_destroy(fg);
- framesync64_destroy(fs);
+#endif
}
