gold: Increment plt_offset after setting TLSDESC PLT entry

Increment plt_offset after setting the reserved TLSDESC PLT entry.

	PR gold/25872
	* x86_64.cc (Output_data_plt_x86_64_bnd::do_write): Increment
	plt_offset after setting the reserved TLSDESC PLT entry.
	(Output_data_plt_x86_64_ibt<size>::do_write): Likewise.
This commit is contained in:
H.J. Lu 2020-05-01 09:00:14 -07:00
parent e977e74712
commit 48bc218262
2 changed files with 9 additions and 0 deletions

View File

@ -1,3 +1,10 @@
2020-05-01 H.J. Lu <hongjiu.lu@intel.com>
PR gold/25872
* x86_64.cc (Output_data_plt_x86_64_bnd::do_write): Increment
plt_offset after setting the reserved TLSDESC PLT entry.
(Output_data_plt_x86_64_ibt<size>::do_write): Likewise.
2020-05-01 H.J. Lu <hongjiu.lu@intel.com>
PR gold/25872

View File

@ -2736,6 +2736,7 @@ Output_data_plt_x86_64_bnd::do_write(Output_file* of)
this->fill_tlsdesc_entry(pov, got_address, plt_address, got_base,
tlsdesc_got_offset, plt_offset);
pov += this->get_plt_entry_size();
plt_offset += plt_entry_size;
}
// Write the additional PLT.
@ -2831,6 +2832,7 @@ Output_data_plt_x86_64_ibt<size>::do_write(Output_file* of)
this->fill_tlsdesc_entry(pov, got_address, plt_address, got_base,
tlsdesc_got_offset, plt_offset);
pov += this->get_plt_entry_size();
plt_offset += plt_entry_size;
}
// Write the additional PLT.