[GOLD] powerpc assertion failure

A testcase with only ifuncs can result in no plt section (ifunc plt
entries might instead be in iplt), which means we can get to this code
without a static link.

	PR 27203
	* powerpc.cc (do_plt_fde_location): Remove doing_static_link
	assertion.

(cherry picked from commit a75a6a4164)
This commit is contained in:
Alan Modra 2021-01-19 13:19:18 +10:30
parent 4c899d5386
commit d235291c81
2 changed files with 6 additions and 1 deletions

View File

@ -1,3 +1,9 @@
2021-01-19 Alan Modra <amodra@gmail.com>
PR 27203
* powerpc.cc (do_plt_fde_location): Remove doing_static_link
assertion.
2021-01-18 H.J. Lu <hongjiu.lu@intel.com>
* testsuite/ifuncmain6pie.c: Remove non-JUMP_SLOT relocations

View File

@ -3946,7 +3946,6 @@ Target_powerpc<size, big_endian>::do_plt_fde_location(const Output_data* plt,
// See Output_data_glink::do_write() for glink contents.
if (len == 0)
{
gold_assert(parameters->doing_static_link());
// Static linking may need stubs, to support ifunc and long
// branches. We need to create an output section for
// .eh_frame early in the link process, to have a place to