/proc/<PID>/maps in openSUSE 11.2 ?

Hi all,

I recently installed openSUSE 11.2 32 bits, and when comparing different versions of Linux, I noticed openSUSE is giving me results I don’t understand for cat /proc/<PID>/maps (related to the top command here in the example).

Normally, there should be 2 or 3 entries per shared library (text, data and bss segments), but for some libraries (not all, some have 3 entries) I get 4 entries in openSUSE (and nowhere else)

An exemple for libncurses.so.5.6 :
b76ab000-b76e1000 r-xp 00000000 08:02 127570 /lib/libncurses.so.5.6
b76e1000-b76e2000 —p 00036000 08:02 127570 /lib/libncurses.so.5.6
b76e2000-b76e4000 r–p 00036000 08:02 127570 /lib/libncurses.so.5.6
b76e4000-b76e8000 rw-p 00038000 08:02 127570 /lib/libncurses.so.5.6
:X

Tough question

– Stéphane

So maybe there’s a 4th kind of segment. Heap?

I won’t bet on the heap. There is a unique line in /proc/<PID>/maps for the heap, and I believe all the heap is there, right?

I checked on a Kubuntu 9.10, which has about the same release of the kernel than openSUSE 11.2 has (2.6.31)
… and same result

I never got any four lines on older Linuxes (based on kernel 2.6.28 etc)

Seems a new feature, but wtf is this 4th line, that has rights set to “—p”: cannot be read, written, executed…

Cannot be heap, anonymous block (mmap), vdso …

Let us know what you find out. I’m curious too.