Date: Wed, 20 Sep 2023 21:20:55 +0000 From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 273956] KERN_PROC_VMMAP does not read all mapped files Message-ID: <bug-273956-227-XENLYER2Ts@https.bugs.freebsd.org/bugzilla/> In-Reply-To: <bug-273956-227@https.bugs.freebsd.org/bugzilla/> References: <bug-273956-227@https.bugs.freebsd.org/bugzilla/>
next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D273956 --- Comment #10 from Ed Maste <emaste@freebsd.org> --- Interesting - I made a little program that uses KERN_PROC_VMMAP and dumps i= ts own map. When I run it normally I see the 4th PT_LOAD as swap: $ ./a.out 1 0x0000000000200000 - 0x0000000000201000 (0x00001000) r-- vnode File: /usr/home/emaste/src/freebsd-git/main/a.out 2 0x0000000000201000 - 0x0000000000202000 (0x00001000) r-x vnode File: /usr/home/emaste/src/freebsd-git/main/a.out 3 0x0000000000202000 - 0x0000000000203000 (0x00001000) r-- vnode File: /usr/home/emaste/src/freebsd-git/main/a.out 4 0x0000000000203000 - 0x0000000000204000 (0x00001000) rw- swap 5 0x0000000800dca000 - 0x0000000820daa000 (0x1ffe0000) --- guard 6 0x0000000820daa000 - 0x0000000820dca000 (0x00020000) rw- swap If I use rtld's exec mode the PT_LOAD is vnode: $ /libexec/ld-elf.so.1 ./a.out=20 1 0x0000000000200000 - 0x0000000000201000 (0x00001000) r-- vnode File: /usr/home/emaste/src/freebsd-git/main/a.out 2 0x0000000000201000 - 0x0000000000202000 (0x00001000) r-x vnode File: /usr/home/emaste/src/freebsd-git/main/a.out 3 0x0000000000202000 - 0x0000000000203000 (0x00001000) r-- vnode File: /usr/home/emaste/src/freebsd-git/main/a.out 4 0x0000000000203000 - 0x0000000000204000 (0x00001000) rw- vnode File: /usr/home/emaste/src/freebsd-git/main/a.out 5 0x000039b4b379c000 - 0x000039b4b37a2000 (0x00006000) r-- vnode File: /libexec/ld-elf.so.1 6 0x000039b4b37a2000 - 0x000039b4b37ba000 (0x00018000) r-x vnode File: /libexec/ld-elf.so.1 ... --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-273956-227-XENLYER2Ts>