From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 86092 invoked by alias); 23 May 2018 14:17:07 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 85586 invoked by uid 89); 23 May 2018 14:17:06 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-3.9 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=cleaner, Hx-languages-length:2113, talk X-HELO: gateway30.websitewelcome.com Received: from gateway30.websitewelcome.com (HELO gateway30.websitewelcome.com) (192.185.194.16) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 23 May 2018 14:17:04 +0000 Received: from cm17.websitewelcome.com (cm17.websitewelcome.com [100.42.49.20]) by gateway30.websitewelcome.com (Postfix) with ESMTP id 393F6272E3 for ; Wed, 23 May 2018 09:17:02 -0500 (CDT) Received: from box5379.bluehost.com ([162.241.216.53]) by cmsmtp with SMTP id LUZafxn6GPvAdLUZafD9QV; Wed, 23 May 2018 09:17:02 -0500 X-Authority-Reason: nr=8 Received: from 174-29-44-154.hlrn.qwest.net ([174.29.44.154]:34952 helo=pokyo) by box5379.bluehost.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.89_1) (envelope-from ) id 1fLUZZ-000k4C-Vv; Wed, 23 May 2018 09:17:02 -0500 From: Tom Tromey To: Pedro Alves Cc: Tom Tromey , gdb-patches@sourceware.org Subject: Re: [RFA 0/9] Radically simplify the complaint system References: <20180522050704.10845-1-tom@tromey.com> <190d88e2-35a5-9dc2-8b28-4a8c37e0617a@redhat.com> Date: Wed, 23 May 2018 15:08:00 -0000 In-Reply-To: <190d88e2-35a5-9dc2-8b28-4a8c37e0617a@redhat.com> (Pedro Alves's message of "Wed, 23 May 2018 14:35:42 +0100") Message-ID: <87d0xmfodf.fsf@tromey.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-BWhitelist: no X-Source-L: No X-Exim-ID: 1fLUZZ-000k4C-Vv X-Source-Sender: 174-29-44-154.hlrn.qwest.net (pokyo) [174.29.44.154]:34952 X-Source-Auth: tom+tromey.com X-Email-Count: 2 X-Source-Cap: ZWx5bnJvYmk7ZWx5bnJvYmk7Ym94NTM3OS5ibHVlaG9zdC5jb20= X-Local-Domain: yes X-SW-Source: 2018-05/txt/msg00626.txt.bz2 >>>>> "Pedro" == Pedro Alves writes: Pedro> Can you give an example case of when do we still need or want Pedro> the ISOLATED_MESSAGE vs SHORT_FIRST_MESSAGE distinction? Sure. You can see it using: $ ./gdb -nx (gdb) set complaints 1 (gdb) file ./gdb I get: Reading symbols from ./gdb...DW_AT_low_pc 0x0 is zero for DIE at 0x1717ad8 [in module /home/tromey/gdb/build/gdb/gdb]....debug_line address at offset 0xa6284 is 0 [in module /home/tromey/gdb/build/gdb/gdb]...done. ... stuff here ... During symbol reading, unsupported tag: 'DW_TAG_unspecified_type'. During symbol reading, const value length mismatch for 'std::ratio<1, 1000000000>::num', got 8, expected 0. What's happening here is that the SHORT_FIRST_MESSAGE stuff is printed during the "Reading symbols...", and then once psymtabs are read, we hit a call to clear_complaints. Any subsequent complaints -- say, during psymtab expansion -- are issued as ISOLATED_MESSAGE. I have some more patches to try to clean some of this up as well, but I thought it would be better to submit this series as a simple complaint cleanup rather than trying to change the output at the same time. What I have so far still preserves this distinction, so this would be a good time to talk about what should be done. All I really did is add some newlines and remove the "done." text, so that the "Reading symbols" output is cleaner, like: Reading symbols from ./gdb... DW_AT_low_pc 0x0 is zero for DIE at 0x1717ad8 [in module /home/tromey/gdb/build/gdb/gdb] debug_line address at offset 0xa6284 is 0 [in module /home/tromey/gdb/build/gdb/gdb] This is a bit weird sometimes still, because some of the complaints are rather uninformative, e.g.: complaint (&symfile_complaints, _("location description stack overflow")); I do think it would be good to be able to remove the *_MESSAGE constants, I'm just not sure exactly what to print. Probably I'm just overthinking it since I doubt anyone except gdb developers enable complaints. Pedro> Note: git am showed: I'll fix that. Tom