What steps will reproduce the problem?
1. Create data rate > 500Mbps on ethX
2. Start tool and monitor ethX
3. Overflow will randomly occur, resulting in negative throughput
What is the expected output? What do you see instead?
Correct throughput
What version of the product are you using? On what operating system?
Latest
Please provide any additional information below.
Fix:
Instead of this:
long readBytes( char* fname, FILE* fp )
{
//TODO: see setbuf, setvbuf se possono migliorare le performances.
static int nb;
//fseek ( fp , 0 , SEEK_SET ); //rewind
freopen( fname, "r", fp );
fscanf( fp, "%i", &nb );
return nb;
}
Use:
long readBytes( char* fname, FILE* fp )
{
//TODO: see setbuf, setvbuf se possono migliorare le performances.
static long long nb;
//fseek ( fp , 0 , SEEK_SET ); //rewind
freopen( fname, "r", fp );
fscanf( fp, "%lld", &nb );
return nb;
}