From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 54665 invoked by alias); 16 Mar 2015 09:10:39 -0000 Mailing-List: contact gdb-prs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-prs-owner@sourceware.org Received: (qmail 54626 invoked by uid 48); 16 Mar 2015 09:10:39 -0000 From: "qiyao at gcc dot gnu.org" To: gdb-prs@sourceware.org Subject: [Bug server/18130] New: gdbserver event loop is terminated by exception Date: Mon, 16 Mar 2015 09:17:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gdb X-Bugzilla-Component: server X-Bugzilla-Version: HEAD X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: qiyao at gcc dot gnu.org X-Bugzilla-Status: NEW 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 Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2015-q1/txt/msg00435.txt.bz2 https://sourceware.org/bugzilla/show_bug.cgi?id=18130 Bug ID: 18130 Summary: gdbserver event loop is terminated by exception Product: gdb Version: HEAD Status: NEW Severity: normal Priority: P2 Component: server Assignee: unassigned at sourceware dot org Reporter: qiyao at gcc dot gnu.org On arm-linux, when I set hardware watchpoint on some address which doesn't meet the kernel alignment requirement, like this, (gdb) ./gdb -ex "target remote arm-linux:2346" -ex "b main" -ex "c" -ex "watch *(buf.byte + 1 + 1)@1" -ex "stepi" -ex "quit" gdb/testsuite/gdb.base/watchpoint-reuse-slot the gdbserver is terminated like this: Killing process(es): 9846 input_interrupt, count = 1 c = 36 ('$') Can't determine port: Bad file descriptor. Exiting in gdbserver/linux-arm-low.c:arm_prepare_to_resume, hardware debugging registers are updated by ptrace (PTRACE_SETHBPREGS), and if something is wrong, exception is thrown out by perror_with_name. if (ptrace (PTRACE_SETHBPREGS, pid, (PTRACE_TYPE_ARG3) -((i << 1) + 2), &proc_info->wpts[i].control) < 0) perror_with_name ("Unexpected error setting watchpoint"); } The exception isn't caught and event loop is terminated as a result. -- You are receiving this mail because: You are on the CC list for the bug.