From: Daniel Jacobowitz <drow@mvista.com>
To: Sivaguru Sankaridurg <siva@eternal-systems.com>
Cc: binutils@sources.redhat.com
Subject: Re: Structure Alignment
Date: Fri, 11 Oct 2002 11:47:00 -0000 [thread overview]
Message-ID: <20021011184703.GA19920@nevyn.them.org> (raw)
In-Reply-To: <000b01c27156$47877120$21a8a8c0@sirius>
On Fri, Oct 11, 2002 at 11:44:48AM -0700, Sivaguru Sankaridurg wrote:
> Hi,
>
> If I have a program that defines a structure ( say struct node { char c; int
> i; } ), is there any way that I can get the alignment information for this
> structure from objdump OR by using BFD api ?
>
> Note:
> * I dont want to use alignof() builtin function, bcos all I have is the name
> of the structure as a char*. For example think that I am writing a function
> "int GetAlignment(char *typename)", that accepts the typename ("node" in
> this case) and returns the alignment required for the type (4 -- in this
> case).
Nope. This information is generally not encoded in debug information
at all; you're out of luck.
--
Daniel Jacobowitz
MontaVista Software Debian GNU/Linux Developer
prev parent reply other threads:[~2002-10-11 18:47 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-10-11 11:42 Sivaguru Sankaridurg
2002-10-11 11:47 ` Daniel Jacobowitz [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=20021011184703.GA19920@nevyn.them.org \
--to=drow@mvista.com \
--cc=binutils@sources.redhat.com \
--cc=siva@eternal-systems.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).