Rename remaining members of buildsym_compunit to start with "m_"
[deliverable/binutils-gdb.git] / ld / emultempl / ppc64elf.em
index 62c298ccf31d3e894bc5c68611889f2932238b56..60bc8bdffa21a5a4814b3f6cbd9f75b40d123be0 100644 (file)
@@ -55,6 +55,9 @@ static int no_tls_opt = 0;
 /* Whether to run opd optimization.  */
 static int no_opd_opt = 0;
 
+/* Whether to convert inline PLT calls to direct.  */
+static int no_inline_opt = 0;
+
 /* Whether to run toc optimization.  */
 static int no_toc_opt = 0;
 
@@ -282,6 +285,15 @@ ppc_before_allocation (void)
          && !ppc64_elf_edit_opd (&link_info))
        einfo (_("%X%P: can not edit %s: %E\n"), "opd");
 
+      if (!no_inline_opt
+         && !bfd_link_relocatable (&link_info))
+       {
+         prelim_size_sections ();
+
+         if (!ppc64_elf_inline_plt (&link_info))
+           einfo (_("%X%P: inline PLT: %E\n"));
+       }
+
       if (ppc64_elf_tls_setup (&link_info)
          && !no_tls_opt)
        {
@@ -706,6 +718,7 @@ enum ppc64_opt
   OPTION_TLS_GET_ADDR_OPT,
   OPTION_NO_TLS_GET_ADDR_OPT,
   OPTION_NO_OPD_OPT,
+  OPTION_NO_INLINE_OPT,
   OPTION_NO_TOC_OPT,
   OPTION_NO_MULTI_TOC,
   OPTION_NO_TOC_SORT,
@@ -733,6 +746,7 @@ PARSE_AND_LIST_LONGOPTS=${PARSE_AND_LIST_LONGOPTS}'
   { "tls-get-addr-optimize", no_argument, NULL, OPTION_TLS_GET_ADDR_OPT },
   { "no-tls-get-addr-optimize", no_argument, NULL, OPTION_NO_TLS_GET_ADDR_OPT },
   { "no-opd-optimize", no_argument, NULL, OPTION_NO_OPD_OPT },
+  { "no-inline-optimize", no_argument, NULL, OPTION_NO_INLINE_OPT },
   { "no-toc-optimize", no_argument, NULL, OPTION_NO_TOC_OPT },
   { "no-multi-toc", no_argument, NULL, OPTION_NO_MULTI_TOC },
   { "no-toc-sort", no_argument, NULL, OPTION_NO_TOC_SORT },
@@ -810,6 +824,9 @@ PARSE_AND_LIST_OPTIONS=${PARSE_AND_LIST_OPTIONS}'
   --no-opd-optimize           Don'\''t optimize the OPD section\n"
                   ));
   fprintf (file, _("\
+  --no-inline-optimize        Don'\''t convert inline PLT to direct calls\n"
+                  ));
+  fprintf (file, _("\
   --no-toc-optimize           Don'\''t optimize the TOC section\n"
                   ));
   fprintf (file, _("\
@@ -915,6 +932,10 @@ PARSE_AND_LIST_ARGS_CASES=${PARSE_AND_LIST_ARGS_CASES}'
       no_opd_opt = 1;
       break;
 
+    case OPTION_NO_INLINE_OPT:
+      no_inline_opt = 1;
+      break;
+
     case OPTION_NO_TOC_OPT:
       no_toc_opt = 1;
       break;
This page took 0.023707 seconds and 4 git commands to generate.