From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 38A0A3858D20; Sun, 26 Feb 2023 14:58:03 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 38A0A3858D20 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1677423483; bh=xT79hff8j/H7JdXrHxmXd+xpREFs1rqvfs7tbU/XxfU=; h=From:To:Subject:Date:In-Reply-To:References:From; b=vYZwwq0hTK6v7hNkmq5sIVe+mb776XUa25xbTty/cD49vGfuVoCcrdGX4klIE/S28 GQIHLV5o9FgYP6WaPH/cIqAs574ez8RXL1H54vXONCFdRXAGpixFvGRDqd3WbePEv5 zVUqEnsxCDjp2xSYwL1SeQgoymWDxjhbxfmFMd2E= From: "mike at mnmoran dot org" To: gcc-bugs@gcc.gnu.org Subject: [Bug demangler/107884] H8/300: cp-demangle.c fix warning related demangle.h Date: Sun, 26 Feb 2023 14:58:02 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: demangler X-Bugzilla-Version: 12.2.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: mike at mnmoran dot org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.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://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D107884 --- Comment #10 from Michael N. Moran --- (In reply to SASANO Takayoshi from comment #9) > (In reply to Michael N. Moran from comment #8) > > I created a corresponding cp-demangle.s file and attached it > > https://gcc.gnu.org/bugzilla/attachment.cgi?id=3D54530 >=20 > Please read this thread carefully, currently this issue targets=20 > H8 advanced mode (24bit address). Your attachment says that > the code is compiled for H8 normal mode (16bit address). >=20 > > .file "cp-demangle.c" > > .h8300hn > > .section .text >=20 Indeed. It has been a long time since I looked a all of the modes for the H8/300. > But, we have to consider why the problem has occurred. >=20 > > .Ldebug_ranges3: > > .section .debug_line,"",@progbits > > .Ldebug_line0: > > .2byte 0, .LELT0-.LSLT0 > > .LSLT0: > > .2byte 0x5 > (snip) > >=20=20 > > .byte 0x1 > > .LELT0: > > .section .debug_str,"MS",@progbits,1 > > .LASF248: >=20 > (.LELT0 - .LSLT0) shows the size of .debug_line section. >=20 > The reported problem means "allocated bitwidth for .Ldebug_line0 > is insufficient to store the size of .debug_line section". >=20 > I think this is out of topic, should be handled at more suitable place. Yes, I divined this later and, after a lot of trial-and-error with various configuration options, found a configure incantation that seems to work. Among other things, this configuration used --disable-hosted-libstdcxx, whi= ch prevented the use of `cp-demangle.c` in the build. configure --target=3Dh8300-none-elf --with-newlib --disable-newlib-supplied-syscalls --enable-languages=3Dc,c++,lto --with-libstdcxx-zoneinfo=3Dn --disable-shared --disable-__cxa_atexit --disable-libstdcxx-verbose --disable-hosted-libstdcxx --disable-libstdcxx-= pch=