public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Simon Marchi <simon.marchi@polymtl.ca>
To: Eli Zaretskii <eliz@gnu.org>,
	Christian Biesinger <cbiesinger@google.com>,
	Tom Tromey <tromey@adacore.com>,
	Joel Brobecker <brobecker@adacore.com>
Cc: gdb-patches@sourceware.org
Subject: Re: Building today's snapshot of GDB with MinGW
Date: Tue, 30 Jun 2020 18:24:11 -0400	[thread overview]
Message-ID: <56f26808-dfb0-6703-6f1f-9818c35946dd@polymtl.ca> (raw)
In-Reply-To: <83wo3ozlvn.fsf@gnu.org>

On 2020-06-30 10:09 a.m., Eli Zaretskii wrote:
>>> 4. Running "maint selftests" produces several warnings and failures:
>>>
>>>   warning: A handler for the OS ABI "Windows" is not built into this configuration of GDB.  Attempting to continue with the default i386:x86-64 settings.
>>
>> Possibly related to
>> https://sourceware.org/pipermail/gdb-patches/2020-March/166678.html ?
> 
> Simon, any chance you could look into this, or instruct me how to
> investigate?

I built a GDB on Linux with a MinGW target and ran the self tests.  I got:

  warning: A handler for the OS ABI "Windows" is not built into this configuration
  of GDB.  Attempting to continue with the default i386:x64-32 settings.

  warning: A handler for the OS ABI "Windows" is not built into this configuration
  of GDB.  Attempting to continue with the default i8086 settings.

  warning: A handler for the OS ABI "Windows" is not built into this configuration
  of GDB.  Attempting to continue with the default i386:x64-32:intel settings.

These are pretty much expected.  For the "gdbarch selftests", we run some test using
all the arches known to BFD.  When initializing the gdbarch for these architectures,
the default osabi for that version of GDB is assumed (in gdbarch_info_fill).  In your
GDB or the GDB I compiled, the default osabi is Windows.

When trying to initialize that gdbarch, GDB just complains that it doesn't have support
for debugging Windows programs running on i386:x64-32, i386:x64-32:intel and i8086.  This
is expected, as i386:x64-32 is an ABI not supported by Windows.  And I presume i8086 is
the very old Intel architecture, which obviously does not support Windows.

However, some of the warnings you get are not expected:

  warning: A handler for the OS ABI "Windows" is not built into this configuration of GDB.  Attempting to continue with the default i386:x86-64 settings.
  warning: A handler for the OS ABI "Windows" is not built into this configuration of GDB.  Attempting to continue with the default i386:x64-32 settings.
  warning: A handler for the OS ABI "Windows" is not built into this configuration of GDB.  Attempting to continue with the default i8086 settings.
  warning: A handler for the OS ABI "Windows" is not built into this configuration of GDB.  Attempting to continue with the default i386:x86-64:intel settings.
  warning: A handler for the OS ABI "Windows" is not built into this configuration of GDB.  Attempting to continue with the default i386:x64-32:intel settings.
  warning: A handler for the OS ABI "Windows" is not built into this configuration of GDB.  Attempting to continue with the default i386:x86-64:nacl settings.
  warning: A handler for the OS ABI "Windows" is not built into this configuration of GDB.  Attempting to continue with the default i386:x64-32:nacl settings.

We would not expect GDB to complain for Windows on i386:x86-64.

The first thing I would do is make sure that the function _initialize_amd64_windows_tdep
gets executed at startup in your GDB.  This is the function that registers a handler for
the tuple (i386:x86-64, Windows).

Simon

  reply	other threads:[~2020-06-30 22:24 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-29 18:27 Eli Zaretskii
2020-06-29 20:36 ` Christian Biesinger
2020-06-30 14:09   ` Eli Zaretskii
2020-06-30 22:24     ` Simon Marchi [this message]
2020-07-01 15:09       ` Eli Zaretskii
2020-07-02 13:50         ` Eli Zaretskii
2020-07-02 14:25           ` Simon Marchi
2020-07-02 14:30             ` Simon Marchi
2020-07-02 17:47               ` Eli Zaretskii
2020-07-02 14:40             ` Pedro Alves
2020-07-02 17:46               ` Eli Zaretskii
2020-07-02 18:21                 ` Pedro Alves
2020-07-02 18:33                   ` Eli Zaretskii
2020-07-02 18:34                     ` Pedro Alves
2020-07-01 15:20       ` Eli Zaretskii
2020-07-01 19:25         ` Christian Biesinger
2020-07-02  2:29           ` Eli Zaretskii
2020-07-02 10:18             ` Hannes Domani
2020-07-02 13:20               ` Eli Zaretskii
2020-07-06 10:39                 ` Hannes Domani
2020-07-06 16:35                   ` Eli Zaretskii
2020-07-01 19:25     ` Joel Brobecker
2020-07-02 13:46       ` Eli Zaretskii
2020-06-30 16:18 ` Eli Zaretskii
2020-06-30 18:21   ` Christian Biesinger
2020-06-30 18:28     ` Eli Zaretskii
2020-07-01 19:29   ` Joel Brobecker
2020-07-02  2:31     ` Eli Zaretskii
2020-07-01 19:30   ` Joel Brobecker
2020-07-02 13:39     ` Eli Zaretskii
2020-07-03 15:25       ` Joel Brobecker
2020-07-27  9:49         ` Tom de Vries
2020-07-27 10:05           ` Tom de Vries
2020-07-27 10:26             ` Tom de Vries
2020-07-27 11:48               ` [committed][gdb/build] Fix typo sys/sockets.h -> sys/socket.h Tom de Vries
2020-07-27 12:51                 ` Joel Brobecker
2020-07-27 14:18               ` Building today's snapshot of GDB with MinGW Eli Zaretskii
2020-07-02 14:12 ` Eli Zaretskii
2020-07-03 15:08   ` Eli Zaretskii

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=56f26808-dfb0-6703-6f1f-9818c35946dd@polymtl.ca \
    --to=simon.marchi@polymtl.ca \
    --cc=brobecker@adacore.com \
    --cc=cbiesinger@google.com \
    --cc=eliz@gnu.org \
    --cc=gdb-patches@sourceware.org \
    --cc=tromey@adacore.com \
    /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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).