Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Andrew Cagney <ac131313@redhat.com>
To: Kris Warkentin <kewarken@qnx.com>
Cc: gdb@sources.redhat.com
Subject: Re: How to know which processor I'm targetting at runtime
Date: Fri, 14 Feb 2003 13:46:00 -0000	[thread overview]
Message-ID: <3E4C4336.1080706@redhat.com> (raw)
In-Reply-To: <034301c2d208$ec67eb80$0202040a@catdog>

> I have some ugly code that relies on a define from one of our
> config/arch/tm*.h files.  Essentially we're just doing:
> 
> #define SOLIB_PROCESSOR [x86|mips|arm....]
> 
> so that we can do some setup elsewhere.  Is there a nice way to get which
> architecture I'm running at runtime?  I'd like to get rid of our tm files if
> possible.

gdbarch_bfd_arch_info (current_gdbarch) returns a `struct bfd_arch_info' 
which contains everything you need.

Andrew



      reply	other threads:[~2003-02-14 13:46 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-02-11 20:05 Kris Warkentin
2003-02-14 13:46 ` Andrew Cagney [this message]

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=3E4C4336.1080706@redhat.com \
    --to=ac131313@redhat.com \
    --cc=gdb@sources.redhat.com \
    --cc=kewarken@qnx.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