More conservative setting for /test/unit/background_thread_enable.
Lower the thread and arena count to avoid resource exhaustion on 32-bit.
This commit is contained in:
parent
5fd55837bb
commit
97b313c7d4
@ -1,6 +1,6 @@
|
|||||||
#include "test/jemalloc_test.h"
|
#include "test/jemalloc_test.h"
|
||||||
|
|
||||||
const char *malloc_conf = "background_thread:false,narenas:1,max_background_threads:20";
|
const char *malloc_conf = "background_thread:false,narenas:1,max_background_threads:8";
|
||||||
|
|
||||||
static unsigned
|
static unsigned
|
||||||
max_test_narenas(void) {
|
max_test_narenas(void) {
|
||||||
@ -12,12 +12,9 @@ max_test_narenas(void) {
|
|||||||
* approximation.
|
* approximation.
|
||||||
*/
|
*/
|
||||||
unsigned ret = 10 * ncpus;
|
unsigned ret = 10 * ncpus;
|
||||||
/* Limit the max to avoid VM exhaustion on 32-bit . */
|
|
||||||
if (ret > 512) {
|
|
||||||
ret = 512;
|
|
||||||
}
|
|
||||||
|
|
||||||
return ret;
|
/* Limit the max to avoid VM exhaustion on 32-bit . */
|
||||||
|
return ret > 256 ? 256 : ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
TEST_BEGIN(test_deferred) {
|
TEST_BEGIN(test_deferred) {
|
||||||
|
Loading…
Reference in New Issue
Block a user