use 256k for large allocation tests

This commit is contained in:
Daniel Micay 2022-01-03 16:11:03 -05:00
parent 5f59ee3935
commit 16c991b8f7
7 changed files with 10 additions and 10 deletions

View File

@ -3,7 +3,7 @@
#include "../test_util.h"
OPTNONE int main(void) {
void *p = malloc(128 * 1024);
void *p = malloc(256 * 1024);
if (!p) {
return 1;
}

View File

@ -3,11 +3,11 @@
#include "../test_util.h"
OPTNONE int main(void) {
void *p = malloc(128 * 1024);
void *p = malloc(256 * 1024);
if (!p) {
return 1;
}
void *q = malloc(128 * 1024);
void *q = malloc(256 * 1024);
if (!q) {
return 1;
}

View File

@ -5,13 +5,13 @@
#include "../test_util.h"
OPTNONE int main(void) {
char *p = malloc(128 * 1024);
char *p = malloc(256 * 1024);
if (!p) {
return 1;
}
memset(p, 'a', 16);
free(p);
for (size_t i = 0; i < 128 * 1024; i++) {
for (size_t i = 0; i < 256 * 1024; i++) {
printf("%x\n", p[i]);
if (p[i] != '\0') {
return 1;

View File

@ -3,7 +3,7 @@
#include "../test_util.h"
OPTNONE int main(void) {
char *p = malloc(128 * 1024);
char *p = malloc(256 * 1024);
if (!p) {
return 1;
}

View File

@ -3,7 +3,7 @@
#include "../test_util.h"
OPTNONE int main(void) {
char *p = malloc(128 * 1024);
char *p = malloc(256 * 1024);
for (unsigned i = 0; i < 8; i++) {
if (p[i] != 0) {
return 1;

View File

@ -4,7 +4,7 @@
#include "../test_util.h"
OPTNONE int main(void) {
char *p = malloc(128 * 1024);
char *p = malloc(256 * 1024);
if (!p) {
return 1;
}

View File

@ -4,12 +4,12 @@
#include "../test_util.h"
OPTNONE int main(void) {
char *p = malloc(128 * 1024);
char *p = malloc(256 * 1024);
if (!p) {
return 1;
}
free(p);
char *q = malloc(128 * 1024);
char *q = malloc(256 * 1024);
p[64 * 1024 + 1] = 'a';
return 0;
}