Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Mike Frysinger <vapier@gentoo.org>
To: Eli Zaretskii <eliz@gnu.org>
Cc: gdb-patches@sourceware.org
Subject: Re: [patch/rfc] gdb: clean up x86 cpuid implementations
Date: Mon, 06 May 2013 20:30:00 -0000	[thread overview]
Message-ID: <201305061630.27822.vapier@gentoo.org> (raw)
In-Reply-To: <831u9jgagk.fsf@gnu.org>

[-- Attachment #1: Type: Text/Plain, Size: 1748 bytes --]

On Monday 06 May 2013 15:44:11 Eli Zaretskii wrote:
> From: Mike Frysinger <vapier@gentoo.org>
> > We've currently got 3 files doing open coded implementations of cpuid.
> > Each has its own set of workarounds and varying levels of how well
> > they're written and are generally hardcoded to specific cpuid functions.
> > If you try to build the latest gdb as a PIE on an i386 system, the build
> > will fail because one of them lacks PIC workarounds (wrt ebx).
> 
> Sorry, I don't follow: what workarounds, and why are they needed?

with i386 targets, ebx cannot be an output when building as PIC.  if you build 
gdb as a PIE, the build fails because some of the code in gdb does exactly 
that.

if you look at the test header, you'll see various other workarounds for 
different gcc versions and assemblers.

> And what's PIE got to do with the go32 target?

nothing.  it just has its own open-coded implementation of cpuid which i 
cleaned up to use the new common header.

> The current code in go32-nat.c was tested to work in all the
> environments supported by that target, without GPFaulting or
> triggering any other disasters.  I don't think we have the resources
> to repeat all that testing with the new code, which tries to detect
> newer CPUs, and so could trigger SIGILL.  So I'd like to leave
> go32-nat.c alone, if possible.

on the flip side, if the new common header was tested, go32-nat (and any other 
DOS like target) wouldn't have to do anymore work, and would be easy to use 
cpuid in more places.

but in the end, i don't care about dead things like DOS, so if people prefer 
to leave the cruft in that one file, i can look the other way while still 
cleaning up everything else.
-mike

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

  reply	other threads:[~2013-05-06 20:30 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-06 18:51 Mike Frysinger
2013-05-06 19:44 ` Eli Zaretskii
2013-05-06 20:30   ` Mike Frysinger [this message]
2013-05-07  2:41     ` Eli Zaretskii
2013-05-07  4:26       ` Doug Evans
2013-05-07 15:56         ` Eli Zaretskii
2013-05-07 13:29 ` [PATCH v2] " Mike Frysinger
2013-05-07 14:08   ` Pedro Alves
2013-05-07 14:19     ` Pedro Alves
2013-05-07 14:31       ` Mike Frysinger
2013-05-07 14:49         ` Pedro Alves
2013-05-07 15:05           ` Mike Frysinger
2013-05-07 15:21             ` Pedro Alves
2013-05-07 15:11 ` [PATCH v3] " Mike Frysinger
2013-06-17  6:16   ` Mike Frysinger
2013-06-17 17:52     ` Pedro Alves
2013-06-18 17:53       ` Mike Frysinger
2013-06-18 18:32         ` Pedro Alves
2013-06-18 23:37           ` Joel Brobecker
2013-06-19  3:12           ` Mike Frysinger
2013-06-19 12:11             ` Pedro Alves
2013-06-19 15:06               ` Mike Frysinger
2013-06-19 15:16                 ` Pedro Alves
2013-06-19 15:50                   ` Mike Frysinger
2013-06-19 16:59                     ` Pedro Alves
2013-06-19 17:35 ` [PATCH v4] " Mike Frysinger
2013-06-19 17:42   ` Pedro Alves
2013-06-19 22:45     ` Mike Frysinger
2013-06-21 11:42       ` Regression for btrace [Re: [PATCH v4] gdb: clean up x86 cpuid implementations] Jan Kratochvil
2013-06-21 15:36         ` Mike Frysinger
2013-06-21 15:41           ` Pedro Alves
2013-06-21 15:51             ` [commit] " Jan Kratochvil

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=201305061630.27822.vapier@gentoo.org \
    --to=vapier@gentoo.org \
    --cc=eliz@gnu.org \
    --cc=gdb-patches@sourceware.org \
    /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