fix to get better heap location

This commit is contained in:
Remzi Arpaci-Dusseau
2019-05-19 17:21:22 -05:00
parent 9bff66d2ca
commit 3c237adcd0

View File

@@ -2,10 +2,10 @@
#include <stdlib.h>
int main(int argc, char *argv[]) {
printf("location of code : %p\n", main);
printf("location of heap : %p\n", malloc(1));
printf("location of code : %p\n", main);
printf("location of heap : %p\n", malloc(100000000));
int x = 3;
printf("location of stack : %p\n", &x);
printf("location of stack: %p\n", &x);
return 0;
}