From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 3289A3865493; Thu, 23 Jul 2020 10:12:19 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 3289A3865493 From: "hi-angel at yandex dot ru" To: gdb-prs@sourceware.org Subject: [Bug gdb/26291] New: `find` is halted upon stumbling upon inaccessible memory region Date: Thu, 23 Jul 2020 10:12:19 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gdb X-Bugzilla-Component: gdb X-Bugzilla-Version: 9.2 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: hi-angel at yandex dot ru X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gdb-prs@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-prs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 23 Jul 2020 10:12:19 -0000 https://sourceware.org/bugzilla/show_bug.cgi?id=3D26291 Bug ID: 26291 Summary: `find` is halted upon stumbling upon inaccessible memory region Product: gdb Version: 9.2 Status: UNCONFIRMED Severity: normal Priority: P2 Component: gdb Assignee: unassigned at sourceware dot org Reporter: hi-angel at yandex dot ru Target Milestone: --- Trying to search in process memory may result in search getting halted beca= use gdb stumble upon an inaccessible memory region. Apparently, the workaround is for a user to manually find all such regions = and try to skip them. However not only it is tedious, the `find` gdb command doesn't even provide means for skipping memory addresses. So it looks like an omission in the `find` command, it would be great if se= arch was not getting halted because an inaccessible region was found, but instead the region would simply be skipped. # Steps to reproduce (in terms of terminal commands) $ gdb ls Reading symbols from ls... (No debugging symbols found in ls) gdb =CE=BB br write Function "write" not defined. Make breakpoint pending on future shared library load? (y or [n]) y Breakpoint 1 (write) pending. gdb =CE=BB r Starting program: /usr/bin/ls Breakpoint 1, 0x00007ffff7e77b40 in write () from /usr/lib/libc.so.6 gdb =CE=BB i proc map process 23816 Mapped address spaces: Start Addr End Addr Size Offset objfile 0x555555554000 0x555555558000 0x4000 0x0 /usr/bin/= ls 0x555555558000 0x55555556c000 0x14000 0x4000 /usr/bin/= ls 0x55555556c000 0x555555575000 0x9000 0x18000 /usr/bin/= ls 0x555555575000 0x555555577000 0x2000 0x20000 /usr/bin/= ls 0x555555577000 0x555555578000 0x1000 0x22000 /usr/bin/= ls 0x555555578000 0x55555559a000 0x22000 0x0 [heap] 0x7ffff7a9d000 0x7ffff7d84000 0x2e7000 0x0 /usr/lib/locale/locale-archive 0x7ffff7d84000 0x7ffff7d87000 0x3000 0x0 0x7ffff7d87000 0x7ffff7dac000 0x25000 0x0 /usr/lib/libc-2.31.so 0x7ffff7dac000 0x7ffff7ef9000 0x14d000 0x25000 /usr/lib/libc-2.31.so 0x7ffff7ef9000 0x7ffff7f43000 0x4a000 0x172000 /usr/lib/libc-2.31.so 0x7ffff7f43000 0x7ffff7f44000 0x1000 0x1bc000 /usr/lib/libc-2.31.so 0x7ffff7f44000 0x7ffff7f47000 0x3000 0x1bc000 /usr/lib/libc-2.31.so 0x7ffff7f47000 0x7ffff7f4a000 0x3000 0x1bf000 /usr/lib/libc-2.31.so 0x7ffff7f4a000 0x7ffff7f4e000 0x4000 0x0 0x7ffff7f4e000 0x7ffff7f50000 0x2000 0x0 /usr/lib/libcap.so.2.37 0x7ffff7f50000 0x7ffff7f54000 0x4000 0x2000 /usr/lib/libcap.so.2.37 0x7ffff7f54000 0x7ffff7f56000 0x2000 0x6000 /usr/lib/libcap.so.2.37 0x7ffff7f56000 0x7ffff7f57000 0x1000 0x7000 /usr/lib/libcap.so.2.37 0x7ffff7f57000 0x7ffff7f58000 0x1000 0x8000 /usr/lib/libcap.so.2.37 0x7ffff7f58000 0x7ffff7f5a000 0x2000 0x0 0x7ffff7fcb000 0x7ffff7fcf000 0x4000 0x0 [vvar] 0x7ffff7fcf000 0x7ffff7fd1000 0x2000 0x0 [vdso] 0x7ffff7fd1000 0x7ffff7fd3000 0x2000 0x0 /usr/lib/ld-2.31.so 0x7ffff7fd3000 0x7ffff7ff3000 0x20000 0x2000 /usr/lib/ld-2.31.so 0x7ffff7ff3000 0x7ffff7ffb000 0x8000 0x22000 /usr/lib/ld-2.31.so 0x7ffff7ffc000 0x7ffff7ffd000 0x1000 0x2a000 /usr/lib/ld-2.31.so 0x7ffff7ffd000 0x7ffff7ffe000 0x1000 0x2b000 /usr/lib/ld-2.31.so 0x7ffff7ffe000 0x7ffff7fff000 0x1000 0x0 0x7ffffffde000 0x7ffffffff000 0x21000 0x0 [stack] 0xffffffffff600000 0xffffffffff601000 0x1000 0x0 [vsyscall] gdb =CE=BB find 0x555555554000, 0x7ffffffff000, "foo" warning: Unable to access 16000 bytes of target memory at 0x55555559668= 3, halting search. Pattern not found. ## Expected Search is not halted upon stumbling upon inaccessible region, instead it is simply skipped. ## Actual Search is halted. --=20 You are receiving this mail because: You are on the CC list for the bug.=