bfd/
authorH.J. Lu <hjl.tools@gmail.com>
Thu, 4 Dec 2003 22:43:36 +0000 (22:43 +0000)
committerH.J. Lu <hjl.tools@gmail.com>
Thu, 4 Dec 2003 22:43:36 +0000 (22:43 +0000)
2003-12-04  H.J. Lu  <hongjiu.lu@intel.com>

* elfxx-ia64.c (elfNN_ia64_relax_section): Use the
need_relax_finalize field in link_info instead of
relax_finalizing to check if the relax finalize pass is being
done.

include/

2003-12-04  H.J. Lu  <hongjiu.lu@intel.com>

* bfdlink.h (bfd_link_info): Change relax_finalizing to
need_relax_finalize.

ld/

2003-12-04  H.J. Lu  <hongjiu.lu@intel.com>

* emultempl/ia64elf.em (gld${EMULATION_NAME}_after_parse): Set
link_info.need_relax_finalize to TRUE.

* ldlang.c (lang_process): Use link_info.need_relax_finalize
instead of link_info.relax_finalizing.
* ldmain.c (main): Likewise.

bfd/ChangeLog
bfd/elfxx-ia64.c
include/ChangeLog
include/bfdlink.h
ld/ChangeLog
ld/emultempl/ia64elf.em
ld/ldlang.c
ld/ldmain.c

index 48ebc5e8890b4e6357fe1985b955c43fd422f8cd..b889b255e6ea6d554fa1c0056cb7a13574409298 100644 (file)
@@ -1,3 +1,10 @@
+2003-12-04  H.J. Lu  <hongjiu.lu@intel.com>
+
+       * elfxx-ia64.c (elfNN_ia64_relax_section): Use the
+       need_relax_finalize field in link_info instead of
+       relax_finalizing to check if the relax finalize pass is being
+       done.
+
 2003-12-04  Dmitry Semyonov  <Dmitry.Semyonov@oktet.ru>
 
        * coff-arm.c (coff_arm_relocate_section, bfd_arm_process_before_allocation):
index c9da05fd547343dadbe530cd4ed1cd0041b3357b..aba571a415ed05af102ffe33578a6aa8d9d56f04 100644 (file)
@@ -714,7 +714,7 @@ elfNN_ia64_relax_section (abfd, sec, link_info, again)
      the relax finalize pass.  */
   if ((sec->flags & SEC_RELOC) == 0
       || sec->reloc_count == 0
-      || (link_info->relax_finalizing
+      || (!link_info->need_relax_finalize
          && sec->need_finalize_relax == 0))
     return TRUE;
 
@@ -765,14 +765,14 @@ elfNN_ia64_relax_section (abfd, sec, link_info, again)
        case R_IA64_PCREL21BI:
        case R_IA64_PCREL21M:
        case R_IA64_PCREL21F:
-         if (link_info->relax_finalizing)
+         if (!link_info->need_relax_finalize)
            continue;
          is_branch = TRUE;
          break;
 
        case R_IA64_LTOFF22X:
        case R_IA64_LDXMOV:
-         if (!link_info->relax_finalizing)
+         if (link_info->need_relax_finalize)
            {
              sec->need_finalize_relax = 1;
              continue;
@@ -1073,7 +1073,7 @@ elfNN_ia64_relax_section (abfd, sec, link_info, again)
       /* ??? Resize .rela.got too.  */
     }
 
-  if (link_info->relax_finalizing)
+  if (!link_info->need_relax_finalize)
     sec->need_finalize_relax = 0;
 
   *again = changed_contents || changed_relocs;
index d7c752be505844e66b1e00c11cb738b36d97108b..4328b98a45c753da660f5a89f7c2f68f55cb4271 100644 (file)
@@ -1,3 +1,8 @@
+2003-12-04  H.J. Lu  <hongjiu.lu@intel.com>
+
+       * bfdlink.h (bfd_link_info): Change relax_finalizing to
+       need_relax_finalize.
+
 2003-12-03  Alan Modra  <amodra@bigpond.net.au>
 
        * bfdlink.h (struct bfd_link_hash_entry): Rename "next" to "und_next".
index f31046dfd1ca869f3a6a534d79d126279fe5b746..a989f64f4ca07f708e71a6e9949ac0c8f79634b4 100644 (file)
@@ -285,8 +285,8 @@ struct bfd_link_info
   /* TRUE if global symbols in discarded sections should be stripped.  */
   unsigned int strip_discarded: 1;
 
-  /* TRUE if relaxation is being finalized.  */
-  unsigned int relax_finalizing: 1;
+  /* TRUE if the final relax pass is needed.  */
+  unsigned int need_relax_finalize: 1;
 
   /* TRUE if generating a position independent executable.  */
   unsigned int pie: 1;
index 60571026fd743b0149358b83aa56b7963d59296c..bf844d1e3b0cd05d4f14c0c4028a4e4d5d9240b5 100644 (file)
@@ -1,3 +1,12 @@
+2003-12-04  H.J. Lu  <hongjiu.lu@intel.com>
+
+       * emultempl/ia64elf.em (gld${EMULATION_NAME}_after_parse): Set
+       link_info.need_relax_finalize to TRUE.
+
+       * ldlang.c (lang_process): Use link_info.need_relax_finalize
+       instead of link_info.relax_finalizing.
+       * ldmain.c (main): Likewise.
+       
 2003-12-04  Dmitry Semyonov  <Dmitry.Semyonov@oktet.ru>
 
        * armpe.sh (RELOCATEABLE_OUTPUT_FORMAT): Define.
index 396405902a3e716fe55cc90a1d82d827ce7c1297..eee467b0809552850143f9f40bec6ce1b9989b61 100644 (file)
@@ -32,6 +32,7 @@ static int itanium = 0;
 static void
 gld${EMULATION_NAME}_after_parse (void)
 {
+  link_info.need_relax_finalize = TRUE;
   bfd_elf${ELFSIZE}_ia64_after_parse (itanium);
 }
 
index 3353f9852ddf3a862d369ebe2d9a08603675033d..e37140451be5445480ed49e3c5a27e17c740de55 100644 (file)
@@ -4262,9 +4262,9 @@ lang_process (void)
 
          /* If the normal relax is done and the relax finalize pass
             is not performed yet, we perform another relax pass.  */
-         if (!relax_again && !link_info.relax_finalizing)
+         if (!relax_again && link_info.need_relax_finalize)
            {
-             link_info.relax_finalizing = TRUE;
+             link_info.need_relax_finalize = FALSE;
              relax_again = TRUE;
            }
        }
index 51e8b8adaf490bf659958ef3149729281eeabe6d..bbafcdb2c59fd15369745abac2c1eaa84f862bad 100644 (file)
@@ -321,7 +321,7 @@ main (int argc, char **argv)
   link_info.spare_dynamic_tags = 5;
   link_info.flags = 0;
   link_info.flags_1 = 0;
-  link_info.relax_finalizing = FALSE;
+  link_info.need_relax_finalize = FALSE;
 
   ldfile_add_arch ("");