From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 45F4B395C076; Wed, 2 Dec 2020 15:08:15 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 45F4B395C076 From: "jakub at redhat dot com" To: dwz@sourceware.org Subject: [Bug default/26987] GCC 11 Ada binaries contain unknown tags Date: Wed, 02 Dec 2020 15:08:15 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: dwz X-Bugzilla-Component: default X-Bugzilla-Version: unspecified X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: jakub at redhat dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: nobody at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: 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: dwz@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Dwz mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 02 Dec 2020 15:08:15 -0000 https://sourceware.org/bugzilla/show_bug.cgi?id=3D26987 --- Comment #14 from Jakub Jelinek --- >From DWARF POV, I think the right solution is to use DW_FORM_sdata or DW_FORM_udata depending on whether the value is signed or unsigned. Which means else /* Otherwise represent the bound as an unsigned value with the precision of its type. The precision and signedness of the type will be necessary to re-interpret it unambiguously. */ add_AT_wide (die, attr, wi::to_wide (value)); needs to be replaced by add_AT_{signed,unsigned}_wide with a new classes th= at will also have wide_int argument, but will emit DW_FORM_sdata or DW_FORM_ud= ata from the wide_int, and will be able to deal with values that don't fit into HOST_WIDE_INT/unsigned HOST_WIDE_INT. On the consumer side the question is if consumers will be able to cope with such large leb128 values. Another option (for DWARF4+ or non-strict DWARF2/3) is for these large constants in attributes that interpret in DWARF3 block class as a DWARF expression to use DW_FORM_block (DW_FORM_exprloc for DWARF4/5) and in there after the uleb128 size put DW_OP_implicit_value with operands the size of the constant and the constant. Yes, it will be 3 bytes larger, but it will not be invalid for DWARF3 and v= ery questionable extension for DWARF4+. --=20 You are receiving this mail because: You are on the CC list for the bug.=