finding out where the text/bss sits
josef Moellers
josef at nixpbe.nixdorf.de
Thu Jan 17 19:11:23 AEST 1991
In <3295 at unisoft.UUCP> aegl at unisoft.UUCP (Tony Luck) writes:
>If you don't have "/proc", then this little program will tell you where
>things are attached in your address space (its up to you to guess which
>things are text, data, bss, stack etc. ... but you get some clues ... like
>whether the area is read-only or read-write).
[ description of program and program text deleted ]
Rather than bus-error-ing, how about a look at ye olde symboltable?
usually
_start sits at the very beginning of the program code
etext sits at the end of the program code
edata sits at the end of the initialized data
end sits at the end of the uninitialized data (bss)
--
| Josef Moellers | c/o Siemens Nixdorf Informationssysteme AG |
| USA: mollers.pad at nixdorf.com | Abt. STO-XS 113 |
| !USA: mollers.pad at nixdorf.de | Heinz-Nixdorf-Ring |
| Phone: (+49) 5251 104662 | D-4790 Paderborn |
More information about the Comp.unix.internals
mailing list