I need a clue about process memory layout, and am hoping someone can
provide it. I wrote a program to discover what address ranges mmap() can
handle (trying to hack growable stacks into libc_r), and came up with the
following output (annotations in `[]'):
----
FreeBSD donner 4.0-CURRENT FreeBSD 4.0-CURRENT #2: Fri Jul 2 19:25:07
PDT 1999 toor@donner:/usr/src/sys/compile/CUSTOM_donner i386
text data bss dec hex filename
2464 220 272 2956 b8c ./brute_stack
initialized global: 0x08049a90
uninitialized global: 0x08049c74
main() function: 0x08048604
main() stack: ~0xbfbfd90c (grows down)
stack size: 0x1000 bytes
bad: 0x00000000 --> 0x00000fff, 0x00001000 bytes
good: 0x00001000 --> 0x08047fff, 0x08047000 bytes [???]
bad: 0x08048000 --> 0x280e3fff, 0x2009c000 bytes [text->data->bss->heap->]
good: 0x280e4000 --> 0xbfbddfff, 0x97afa000 bytes [-><-]
bad: 0xbfbde000 --> 0xffffffff, 0x40422000 bytes [<-stack, env]
malloc()ed stack: 0x0804b000
----
Some questions about the above:
1) What is the ??? range for? (The loader?)
2) Where exactly is the stack on the x86?
3) Where is the stack on the Alpha?
4) Where is the code that I should have read instead of bothering you? The
rtld-elf code mentions the expectation that the "SVR4 ABI specification,
Intel 386 Processor Supplement" is adhered to, but I couldn't find
anything more specific.
Thanks,
Jason
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message