From: "Serge Nikulin" <nikulin@actsw.amat.com>
To: <binutils@sourceware.cygnus.com>
Cc: <mark_golden@amat.com>
Subject: Bug in gas: frags.c @ frag_align (absolute section alignment)
Date: Fri, 21 Jul 2000 17:17:00 -0000 [thread overview]
Message-ID: <001601bff350$a2801720$35758798@mis.amat.com> (raw)
Hi,
As I reported already, I had a problem with alignment in absolute section.
I found the bug in frags.c file in frag_align function.
Old buggy code:
---------
new_off = ((abs_section_offset + alignment - 1)
&~ ((1 << alignment) - 1));
---------
When abs_section_offset == 1 and alignment == 1 then new_off should be == 2
In the above code new_off == 0
The proposed new code:
-------------------
if ((abs_section_offset & ((1 << alignment) - 1)) != 0)
new_off = ((abs_section_offset >> alignment) + 1) << alignment;
else
new_off = abs_section_offset; /* aligned already */
-------------------
Serge
reply other threads:[~2000-07-21 17:17 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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='001601bff350$a2801720$35758798@mis.amat.com' \
--to=nikulin@actsw.amat.com \
--cc=binutils@sourceware.cygnus.com \
--cc=mark_golden@amat.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).