Even more effective multu thred testing and dirty fix for paging slab stealing issue
This commit is contained in:
parent
fca2584d89
commit
e5a5ec13bb
@ -21,8 +21,8 @@
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
#define PT_PT_SLAB_MIN_SPACE 18
|
||||
#define PT_CHILDREN_SLAB_MIN_SPACE 12
|
||||
#define PT_PT_SLAB_MIN_SPACE 256
|
||||
#define PT_CHILDREN_SLAB_MIN_SPACE 256
|
||||
|
||||
#define PT_META_MAX_SIZE MAX(sizeof(struct pt_t), sizeof(struct pt_vaddr_reg_t))
|
||||
#define PT_PT_SLAB_INITIAL_SPACE SLAB_STATIC_SIZE(PT_PT_SLAB_MIN_SPACE, PT_META_MAX_SIZE)
|
||||
|
||||
@ -27,8 +27,6 @@ static struct thread* threads[NUM_THREADS];
|
||||
|
||||
__attribute__((__used__))
|
||||
static int test_large_buffer(void * __args) {
|
||||
barrelfish_usleep(rand() % 50 * 100000);
|
||||
|
||||
//allocate a 256 MiB buffer
|
||||
debug_printf("allocating 256MiB buffer\n");
|
||||
char * big_buf = malloc(1<<28);
|
||||
@ -36,6 +34,7 @@ static int test_large_buffer(void * __args) {
|
||||
|
||||
//only write to a small part of the large buffer
|
||||
for (int i = 0; i < (1 << 16); i += (1 << 12)) {
|
||||
barrelfish_usleep(rand() % 10 * 100000);
|
||||
big_buf[i] = 'b';
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user