From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 100827 invoked by alias); 29 Jan 2020 05:44:39 -0000 Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org Received: (qmail 100818 invoked by uid 89); 29 Jan 2020 05:44:39 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-4.2 required=5.0 tests=AWL,BAYES_00,FREEMAIL_ENVFROM_END_DIGIT,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=no version=3.3.1 spammy=1064, greeting X-HELO: mail-io1-f41.google.com Received: from mail-io1-f41.google.com (HELO mail-io1-f41.google.com) (209.85.166.41) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 29 Jan 2020 05:44:38 +0000 Received: by mail-io1-f41.google.com with SMTP id t26so17244373ioi.13 for ; Tue, 28 Jan 2020 21:44:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=m6uDq2lmVEbHhzYYdVtYbR1Z5Qm03PgQ4odrUEhpF7g=; b=nwGHpfwlUegZOV3iTj53gjc+ROKM8ev5G6o4sGxu9XeET8rQZVCjPNRcTI7JeqHXhN Bdl0c/u6g2YzA5FNbYnKUkVl7FgfNRKKeNM+vwCMQXhQzezwzPNJ9ANlxl9+pEEJzKoY Pq1I2lymQ0leA1kpKYiZxehBGVVdJQgj2okSf7qJXhmNePgn5BGJX8R4oBukdFgURwsx EEuZM68uTHbAdQ2o3n52+TeE9TmGwN6sc0KA/gdzkBFrr9Gy52DN4AfZv1/69ra8jICS EGrrFiX6dIIMo3hIXsN0nVoA4JePDUpfKeR8GpHusRtmJHrFwzeLbnuTqzxsTYZzEKW2 i6TA== MIME-Version: 1.0 From: Nan Xiao Date: Wed, 29 Jan 2020 05:44:00 -0000 Message-ID: Subject: The newest gdb 8.3 crash on OpenBSD To: gdb@sourceware.org Content-Type: text/plain; charset="UTF-8" X-IsSubscribed: yes X-SW-Source: 2020-01/txt/msg00076.txt.bz2 Hi gdb community, Greeting from me! I am building the newest gdb 8.3 on OpenBSD 6.6 server (Virtual machine, amd64). The build is OK, but the gdb will crash when I tried to use it to debug program: (gdb) bt #0 0x0000000000000000 in ?? () #1 0x00000ec41fa1c506 in x86_dr_stopped_data_address (state=0xec6da0e4010, addr_p=0x7f7ffffbde70) at ../../gdb/nat/x86-dregs.c:608 #2 0x00000ec41fa1c7a3 in x86_dr_stopped_by_watchpoint (state=0xec6da0e4010) at ../../gdb/nat/x86-dregs.c:650 #3 0x00000ec41f82ae47 in x86_nat_target::stopped_by_watchpoint (this=0xec6da0e4010) at ../../gdb/x86-nat.h:100 #4 0x00000ec41f84ff71 in watchpoints_triggered (ws=) at ../../gdb/breakpoint.c:4727 #5 0x00000ec41f9ccb70 in handle_signal_stop (ecs=0x7f7ffffbe2f0) at ../../gdb/infrun.c:5605 #6 0x00000ec41f9c1eeb in handle_inferior_event (ecs=0x7f7ffffbe2f0) at ../../gdb/infrun.c:5178 #7 0x00000ec41f9c329b in fetch_inferior_event (client_data=) at ../../gdb/infrun.c:3753 #8 0x00000ec41f95ce59 in gdb_do_one_event () at ../../gdb/event-loop.c:1064 #9 0x00000ec41f95d42d in start_event_loop () at ../../gdb/event-loop.c:371 #10 0x00000ec41f9f3392 in captured_command_loop () at ../../gdb/main.c:331 #11 0x00000ec41f9f2e13 in captured_main (data=) at ../../gdb/main.c:1182 #12 gdb_main (args=) at ../../gdb/main.c:1198 #13 0x00000ec41f7fc378 in main (argc=, argv=0x7f7ffffbde70) at ../../gdb/gdb.c:32 (gdb) frame 1 #1 0x00000ec41fa1c506 in x86_dr_stopped_data_address (state=0xec6da0e4010, addr_p=0x7f7ffffbde70) at ../../gdb/nat/x86-dregs.c:608 608 status = x86_dr_low_get_status (); I tried to step-in debug it, and found it seems to access an invalid function address: (top-gdb) display /i $pc 1: x/i $pc => 0x76de4af4f5 : mov 0x394874(%rip),%r12 # 0x76de843d70 (top-gdb) ni 0x00000076de4af4fc 608 status = x86_dr_low_get_status (); 1: x/i $pc => 0x76de4af4fc : mov 0x18(%r12),%r11 (top-gdb) 0x00000076de4af501 608 status = x86_dr_low_get_status (); 1: x/i $pc => 0x76de4af501 : callq 0x76de28f150 <__llvm_retpoline_r11> (top-gdb) Program received signal SIGSEGV, Segmentation fault. 0x0000000000000000 in ?? () 1: x/i $pc => 0x0: I checked the source code, but can't figure out the reasons. Anyone can give some clues? Thanks very much in advance! Best Regards Nan Xiao