Using valgrind I run the following code:
#include <stdio.h>
#include <stdlib.h>
int main(int argc, char** argv){
printf("Hello World!");
return EXIT_SUCCESS;
}
The valgrind output is:
HEAP SUMMARY:
==22613== in use at exit: 0 bytes in 0 blocks
==22613== total heap usage: 1 allocs, 1 frees, 1,024 bytes allocated
Why does the printf statement allocate 1,024 bytes on the heap?