An application binary is loaded into RAM, which got compiled using GCC
Does this binary get virtual address (VA) starting from 0x0 or some other value?
(When i check the application binary, i couldn't see any VA in application)
An application binary is loaded into RAM, which got compiled using GCC
Does this binary get virtual address (VA) starting from 0x0 or some other value?
(When i check the application binary, i couldn't see any VA in application)
I read many articles and found an answer, which could address some of my questions.
GCC uses ELF format to create application binary. If you do "readelf -a app_binary", then it shows the entry point address of the application.
Application compiled using GCC, uses a starting virtual address 0x400000 in 64-bit and 0x804800 in 32-bit systems.
So, if we try access 0x0-0x3fffff, then segmentation fault will be seen. Since that virtual memory is not defined.
Please correct my answer, if it has any mistakes. :-)