From: Eli Zaretskii <eliz@gnu.org>
To: Hannes Domani <ssbssa@yahoo.de>
Cc: brobecker@adacore.com, gdb-patches@sourceware.org
Subject: Re: GDB 16.0.90 available for testing
Date: Sun, 29 Dec 2024 17:33:26 +0200 [thread overview]
Message-ID: <86zfkepkqh.fsf@gnu.org> (raw)
In-Reply-To: <745538212.4148266.1735485100440@mail.yahoo.com> (message from Hannes Domani on Sun, 29 Dec 2024 15:11:40 +0000 (UTC))
> Date: Sun, 29 Dec 2024 15:11:40 +0000 (UTC)
> From: Hannes Domani <ssbssa@yahoo.de>
> Cc: "gdb-patches@sourceware.org" <gdb-patches@sourceware.org>
>
> Am Sonntag, 29. Dezember 2024 um 13:55:25 MEZ hat Eli Zaretskii <eliz@gnu.org> Folgendes geschrieben:
>
> > 1. A compilation error in readline/input.c, due to lack of 'alarm'
> > function. I have reported that several months ago to the upstream
> > Readline developers, but the solution they installed only works for
> > MinGW64. For mingw.org we need the following patch:
> >
> > --- readline/readline/input.c~0 2024-12-29 04:50:07.000000000 +0200
> > +++ readline/readline/input.c 2024-12-29 12:32:04.196630800 +0200
> > @@ -151,6 +151,14 @@ win32_isatty (int fd)
> > # define RL_TIMEOUT_USE_SELECT
> > #else
> > # define RL_TIMEOUT_USE_SIGALRM
> > +# ifdef __MINGW32_MAJOR_VERSION
> > +/* mingw.org's MinGW doesn't have 'alarm'. */
> > +unsigned int
> > +alarm (unsigned int seconds)
> > +{
> > + return 0;
> > +}
> > +# endif
> > #endif
> >
> > int rl_set_timeout (unsigned int, unsigned int);
>
> I wonder why readline doesn't disable the whole stuff where alarm is used
> on windows, since it doesn't work there anyways.
Chet said that's what he did, but I saw no evidence of that in the
current Readline (assuming I was looking at the correct branch in the
Git repository). See
https://lists.gnu.org/archive/html/bug-readline/2024-12/msg00003.html
> > 3. Running GDB on itself produces the following error message:
> >
> > warning: BFD: error: d:\gnu\gdb-16.0.90\gdb\gdb.exe(.debug_macro) is too large (0x9f585e077fdeba bytes)
> > warning: Can't read data for section '.debug_macro' in file 'd:\gnu\gdb-16.0.90\gdb\gdb.exe'
> > During symbol reading: missing .debug_macro section
> >
> > The size of the section is obviously bogus; the real size is 0x77fdeba
> > bytes, which is more than 128 MBytes, and so fails malloc. I tracked
> > the bogus print value to this code in bfd:
> >
> > /* PR 20801: Provide a more helpful error message. */
> > if (bfd_get_error () == bfd_error_no_memory)
> > _bfd_error_handler
> > /* xgettext:c-format */
> > (_("error: %pB(%pA) is too large (%#" PRIx64 " bytes)"),
> > abfd, sec, (uint64_t) allocsz);
> >
> > It sounds like uint64_t values are not printed correctly by BFD in
> > this 32-bit build? I ended up using the following kludge:
> >
> > if (sizeof (allocsz ) > sizeof (int))
> > _bfd_error_handler
> > /* xgettext:c-format */
> > (_("error: %pB(%pA) is too large (%#" PRIx64 " bytes)"),
> > abfd, sec, (uint64_t) allocsz);
> > else
> > _bfd_error_handler
> > /* xgettext:c-format */
> > (_("error: %pB(%pA) is too large (%#" PRIx32 " bytes)"),
> > abfd, sec, allocsz);
>
> Doesn't the (uint64_t) cast already make sure the allocsz value matches
> PRIx64, so why does it not work here?
>
> What does PRIx64 expand to for you, "llx" or "I64x"?
> _bfd_print can only handle llx as far as I can tell, and in my build this is
> automatically enabled by the __USE_MINGW_ANSI_STDIO define.
AFAICT, llx didn't help, either (I tried), and __USE_MINGW_ANSI_STDIO
is the default anyway. It's very strange what I saw there, using llx
I got printed values like 0x77fdeba00000000, which seem like the value
was interpreted as big-endian or something? You are welcome to try,
maybe I was confused or something.
next prev parent reply other threads:[~2024-12-29 15:34 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-29 3:31 Joel Brobecker
2024-12-29 12:54 ` Eli Zaretskii
2024-12-29 15:11 ` Hannes Domani
2024-12-29 15:33 ` Eli Zaretskii [this message]
2025-01-01 13:12 ` Eli Zaretskii
2025-01-02 1:59 ` Joel Brobecker
2025-01-02 6:12 ` Eli Zaretskii
2025-01-02 6:48 ` Joel Brobecker
2025-01-02 17:33 ` Eli Zaretskii
2025-01-02 17:38 ` Eli Zaretskii
2025-01-03 4:48 ` Joel Brobecker
2025-01-04 10:29 ` Eli Zaretskii
2025-01-02 17:40 ` Eli Zaretskii
2025-01-03 10:05 ` Luis Machado
2025-01-04 10:30 ` Eli Zaretskii
2025-01-04 11:00 ` Tom de Vries
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=86zfkepkqh.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=brobecker@adacore.com \
--cc=gdb-patches@sourceware.org \
--cc=ssbssa@yahoo.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox