This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Fix sh_entsize field of .plt section on x86_64


Paul Pluzhnikov noticed that the sh_entsize field of the .plt section
was incorrect on x86_64 when using gold.  This dates back to when
x86_64.cc was created as a copy of i386.cc.  I committed this patch to
fix the problem.

Ian


2009-04-27  Ian Lance Taylor  <iant@google.com>

	* x86_64.cc (do_adjust_output_section): Set entsize to
	plt_entry_size.


Index: x86_64.cc
===================================================================
RCS file: /cvs/src/src/gold/x86_64.cc,v
retrieving revision 1.81
diff -p -u -r1.81 x86_64.cc
--- x86_64.cc	27 Mar 2009 18:19:09 -0000	1.81
+++ x86_64.cc	27 Apr 2009 16:23:37 -0000
@@ -601,9 +601,7 @@ Output_data_plt_x86_64::Output_data_plt_
 void
 Output_data_plt_x86_64::do_adjust_output_section(Output_section* os)
 {
-  // UnixWare sets the entsize of .plt to 4, and so does the old GNU
-  // linker, and so do we.
-  os->set_entsize(4);
+  os->set_entsize(plt_entry_size);
 }
 
 // Add an entry to the PLT.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]