diff options
author | Ken Raeburn <raeburn@cygnus> | 1995-05-03 18:08:09 +0000 |
---|---|---|
committer | Ken Raeburn <raeburn@cygnus> | 1995-05-03 18:08:09 +0000 |
commit | fa9dea803d66ea892ac9b5b22784c9be55cf1200 (patch) | |
tree | ccb4f689933ef5a9f8ae0e7f753eb2152a6f87ff /ld/ldlang.c | |
parent | 8a71f0f3d5c362da77ed3c469fe17c7fd517ba4f (diff) | |
download | gdb-fa9dea803d66ea892ac9b5b22784c9be55cf1200.zip gdb-fa9dea803d66ea892ac9b5b22784c9be55cf1200.tar.gz gdb-fa9dea803d66ea892ac9b5b22784c9be55cf1200.tar.bz2 |
* ldlang.c (print_output_section_statement): Check subsection_alignment,
instead of checking section_alignment twice. Noticed by Alan Modra
<alan@spri.levels.unisa.edu.au>.
Diffstat (limited to 'ld/ldlang.c')
-rw-r--r-- | ld/ldlang.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/ld/ldlang.c b/ld/ldlang.c index 61ad502..f7847d3 100644 --- a/ld/ldlang.c +++ b/ld/ldlang.c @@ -1236,7 +1236,7 @@ print_output_section_statement (output_section_statement) fprintf (config.map_file, "Output address %08x\n", b); } if (output_section_statement->section_alignment >= 0 - || output_section_statement->section_alignment >= 0) + || output_section_statement->subsection_alignment >= 0) { fprintf (config.map_file, "\t\t\t\t\tforced alignment "); if (output_section_statement->section_alignment >= 0) @@ -2259,9 +2259,9 @@ lang_common () bfd_link_hash_traverse (link_info.hash, lang_one_common, (PTR) NULL); else { - unsigned int power; + int power; - for (power = 1; power < 4; power++) + for (power = 4; power >= 0; power--) bfd_link_hash_traverse (link_info.hash, lang_one_common, (PTR) &power); } @@ -2285,8 +2285,7 @@ lang_one_common (h, info) power_of_two = h->u.c.p->alignment_power; if (config.sort_common - && power_of_two < *(unsigned int *) info - && *(unsigned int *) info < 4) + && power_of_two < *(int *) info) return true; section = h->u.c.p->section; |