summaryrefslogtreecommitdiff
path: root/userspace/bigmem.c
blob: 5d474aa3ce381275bc64d471d12cdc86227dbb6d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#include <stdio.h>
#include <stdlib.h>

int main()
{
    for(int i=1;i<100;i++)
    {
        printf("allocating memory: %d byte\n",i*1024*1024);
        char *mem=calloc(i*1024*1024,1);
        printf("OK (addr=0x%08X)",mem);
    }

    return EXIT_SUCCESS;
}