mirror of
https://github.com/VectorCamp/vectorscan.git
synced 2025-09-29 19:24:25 +03:00
Reduce unit test runtimes dramatically for debug builds
This commit is contained in:
@@ -157,7 +157,11 @@ TEST_P(HyperscanScanGigabytesMatch, StreamingMatch) {
|
||||
|
||||
// gb is the number of gigabytes to scan between pre-block and post-block
|
||||
// run over 1,2,4,8 gb
|
||||
#ifdef NDEBUG
|
||||
for (unsigned long long gb = 1; gb <= 8; gb *= 2) {
|
||||
#else
|
||||
for (unsigned long long gb = 1; gb <= 2; gb *= 2) {
|
||||
#endif
|
||||
SCOPED_TRACE(gb);
|
||||
|
||||
hs_stream_t *stream = nullptr;
|
||||
@@ -261,12 +265,12 @@ TEST_P(HyperscanScanGigabytesMatch, BlockMatch) {
|
||||
1*1024,
|
||||
#ifdef BIG_BLOCKS
|
||||
4*1024, 32*1024, 128*1024, 512*1024,
|
||||
#ifdef NDEBUG
|
||||
// gigabytes
|
||||
1024*1024,
|
||||
#ifdef ARCH_X86_64
|
||||
// big cases for big beefy machines
|
||||
2048*1024, 3072*1024
|
||||
#endif // ARCH_X86_64
|
||||
#endif // NDEBUG
|
||||
#endif // BIG_BLOCKS
|
||||
};
|
||||
|
||||
|
@@ -235,7 +235,11 @@ static const unsigned test_modes[] = {HS_MODE_BLOCK, HS_MODE_STREAM,
|
||||
static const unsigned test_flags[] = {0, HS_FLAG_SINGLEMATCH,
|
||||
HS_FLAG_SOM_LEFTMOST};
|
||||
|
||||
#ifdef NDEBUG
|
||||
static const unsigned test_sizes[] = {1, 10, 100, 500, 10000};
|
||||
#else
|
||||
static const unsigned test_sizes[] = {1, 10, 100, 500};
|
||||
#endif
|
||||
|
||||
static const pair<unsigned, unsigned> test_bounds[] = {{3u, 10u}, {10u, 100u}};
|
||||
|
||||
|
Reference in New Issue
Block a user