PR ld/26018
	* testsuite/ld-i386/i386.exp: Add a -Bsymbolic-functions test.
	* testsuite/ld-x86-64/x86-64.exp: Likewise.
	* testsuite/ld-i386/pr26018.d: New file.
	* testsuite/ld-x86-64/pr26018.d: Likewise.
	* testsuite/ld-x86-64/pr26018.s: Likewise.
+2020-05-23  H.J. Lu  <hongjiu.lu@intel.com>
+
+       PR ld/26018
+       * testsuite/ld-i386/i386.exp: Add a -Bsymbolic-functions test.
+       * testsuite/ld-x86-64/x86-64.exp: Likewise.
+       * testsuite/ld-i386/pr26018.d: New file.
+       * testsuite/ld-x86-64/pr26018.d: Likewise.
+       * testsuite/ld-x86-64/pr26018.s: Likewise.
+
 2020-05-21  Alan Modra  <amodra@gmail.com>
 
        * deffilep.y: Replace "if (x) free (x)" with "free (x)" thoughout.
 
 run_dump_test "pr24322a"
 run_dump_test "pr24322b"
 run_dump_test "align-branch-1"
+run_dump_test "pr26018"
 
 if { !([istarget "i?86-*-linux*"]
        || [istarget "i?86-*-gnu*"]
 
--- /dev/null
+#source: ../ld-x86-64/pr26018.s
+#as: --32
+#ld: -shared -Bsymbolic-functions -melf_i386
+#objdump: -dw
+
+.*: +file format .*
+
+
+Disassembly of section .text:
+
+[0-9a-f]+ <_start>:
+ +[a-f0-9]+:   e8 00 00 00 00          call   [0-9a-f]+ <foo>
+
+[0-9a-f]+ <foo>:
+ +[a-f0-9]+:   c3                      ret    
+#pass
 
--- /dev/null
+#as: --64
+#ld: -shared -Bsymbolic-functions -melf_x86_64
+#objdump: -dw
+
+.*: +file format .*
+
+
+Disassembly of section .text:
+
+[0-9a-f]+ <_start>:
+ +[a-f0-9]+:   e8 00 00 00 00          callq  [0-9a-f]+ <foo>
+
+[0-9a-f]+ <foo>:
+ +[a-f0-9]+:   c3                      retq   
+#pass
 
--- /dev/null
+       .global _start, foo
+       .type foo, %function
+       .text
+_start:
+       call foo@PLT
+foo:
+       ret
 
 run_dump_test "pr25416-2b"
 run_dump_test "pr25416-3"
 run_dump_test "pr25416-4"
+run_dump_test "pr26018"
 
 if { ![istarget "x86_64-*-linux*"] && ![istarget "x86_64-*-nacl*"]} {
     return