https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107884

--- Comment #10 from Michael N. Moran <mike at mnmoran dot org> ---
(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=54530
> 
> Please read this thread carefully, currently this issue targets 
> H8 advanced mode (24bit address). Your attachment says that
> the code is compiled for H8 normal mode (16bit address).
> 
> >         .file   "cp-demangle.c"
> >         .h8300hn
> >         .section .text
> 

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.
> 
> > .Ldebug_ranges3:
> >         .section        .debug_line,"",@progbits
> > .Ldebug_line0:
> >         .2byte  0, .LELT0-.LSLT0
> > .LSLT0:
> >         .2byte  0x5
> (snip)
> >  
> >         .byte   0x1
> > .LELT0:
> >         .section        .debug_str,"MS",@progbits,1
> > .LASF248:
> 
> (.LELT0 - .LSLT0) shows the size of .debug_line section.
> 
> The reported problem means "allocated bitwidth for .Ldebug_line0
> is insufficient to store the size of .debug_line section".
> 
> 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, which
prevented the use of `cp-demangle.c` in the build.

configure --target=h8300-none-elf --with-newlib
--disable-newlib-supplied-syscalls --enable-languages=c,c++,lto
--with-libstdcxx-zoneinfo=n --disable-shared --disable-__cxa_atexit
--disable-libstdcxx-verbose --disable-hosted-libstdcxx --disable-libstdcxx-pch

Reply via email to