Re:How JavaScript works: memory management and common memory...
by phyllostachys on Wednesday September 13, 2017 @04:49PM
(#15242509)
After looking at that default linker script dump, I noticed it didn't have the stuff I saw in the ARM linker script that I'm used to. So I attached one for a Silicon Labs EFM32 part. It's below the x86-64 linker script and is a little easier to read.
Re:How JavaScript works: memory management and common memory...
by phyllostachys on Wednesday September 13, 2017 @05:04PM
(#15242661)
After a little investigation[1][2], it seems things get weird with an OS, as would be expected with virtual memory, et al.
[1] - https://stackoverflow.com/questions/16360620/find-out-whethe...
[2] - http://duartes.org/gustavo/blog/post/anatomy-of-a-program-in...
[1] - .rodata section in gcc
[2] - I think this is in the .data and .bss sections, where .data is copied from the file and .bss is zero initialized before calling main by the crt. If you peak into a linker script, or dump one by passing --verbose to ld, you can even see where it puts all the C++ bits and pieces. A dump I did on Debian with g++ is here: https://gist.github.com/Phyllostachys/0682a3bda13ef9c6b49d04...