x86: Correct unwind information for the second PLT

For i386, generate unwind information for the second PLT.  For x32,
correct alignment of .eh_frame section for the second PLT.

bfd/

	PR ld/22061
	* elf32-i386.c (elf_i386_link_setup_gnu_properties): Create
	.eh_frame section for the second PLT.
	* elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties): Correct
	alignment of .eh_frame section for the second PLT.

ld/

	PR ld/22061
	* testsuite/ld-i386/ibt-plt-1.d: Updated.
	* testsuite/ld-i386/ibt-plt-2a.d: Likewise.
	* testsuite/ld-i386/ibt-plt-2c.d: Likewise.
	* testsuite/ld-i386/ibt-plt-3a.d: Likewise.
	* testsuite/ld-i386/ibt-plt-3c.d: Likewise.
	* testsuite/ld-x86-64/ibt-plt-1-x32.d: Likewise.
	* testsuite/ld-x86-64/ibt-plt-2a-x32.d: Likewise.
	* testsuite/ld-x86-64/ibt-plt-2c-x32.d: Likewise.
	* testsuite/ld-x86-64/ibt-plt-3a-x32.d: Likewise.
	* testsuite/ld-x86-64/ibt-plt-3c-x32.d: Likewise.
	* testsuite/ld-i386/ibt-plt-2b.d: Pass --hash-style=sysv to ld
	and dump unwind information.
	* testsuite/ld-i386/ibt-plt-2d.d: Likewise.
	* testsuite/ld-i386/ibt-plt-3b.d: Likewise.
	* testsuite/ld-i386/ibt-plt-3d.d: Likewise.
	* testsuite/ld-x86-64/ibt-plt-2b-x32.d: Likewise.
	* testsuite/ld-x86-64/ibt-plt-2b.d: Likewise.
	* testsuite/ld-x86-64/ibt-plt-2d-x32.d: Likewise.
	* testsuite/ld-x86-64/ibt-plt-2d.d: Likewise.
	* testsuite/ld-x86-64/ibt-plt-3b-x32.d: Likewise.
	* testsuite/ld-x86-64/ibt-plt-3b.d: Likewise.
	* testsuite/ld-x86-64/ibt-plt-3d-x32.d: Likewise.
	* testsuite/ld-x86-64/ibt-plt-3d.d: Likewise.
This commit is contained in:
H.J. Lu 2017-09-01 06:11:54 -07:00
parent 1c5c938ad8
commit e10c9c620c
26 changed files with 574 additions and 51 deletions

View File

@ -1,3 +1,11 @@
2017-09-01 H.J. Lu <hongjiu.lu@intel.com>
PR ld/22061
* elf32-i386.c (elf_i386_link_setup_gnu_properties): Create
.eh_frame section for the second PLT.
* elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties): Correct
alignment of .eh_frame section for the second PLT.
2017-09-01 Nick Clifton <nickc@redhat.com>
PR 22059

View File

@ -6144,6 +6144,20 @@ error_alignment:
htab->plt_got_eh_frame = sec;
}
if (htab->plt_second != NULL)
{
sec = bfd_make_section_anyway_with_flags (dynobj,
".eh_frame",
flags);
if (sec == NULL)
info->callbacks->einfo (_("%F: failed to create the second PLT .eh_frame section\n"));
if (!bfd_set_section_alignment (dynobj, sec, 2))
goto error_alignment;
htab->plt_second_eh_frame = sec;
}
}
}

View File

@ -6737,9 +6737,10 @@ error_alignment:
".eh_frame",
flags);
if (sec == NULL)
info->callbacks->einfo (_("%F: failed to create BND PLT .eh_frame section\n"));
info->callbacks->einfo (_("%F: failed to create the second PLT .eh_frame section\n"));
if (!bfd_set_section_alignment (dynobj, sec, 3))
if (!bfd_set_section_alignment (dynobj, sec,
ABI_64_P (dynobj) ? 3 : 2))
goto error_alignment;
htab->plt_second_eh_frame = sec;

View File

@ -1,3 +1,30 @@
2017-09-01 H.J. Lu <hongjiu.lu@intel.com>
PR ld/22061
* testsuite/ld-i386/ibt-plt-1.d: Updated.
* testsuite/ld-i386/ibt-plt-2a.d: Likewise.
* testsuite/ld-i386/ibt-plt-2c.d: Likewise.
* testsuite/ld-i386/ibt-plt-3a.d: Likewise.
* testsuite/ld-i386/ibt-plt-3c.d: Likewise.
* testsuite/ld-x86-64/ibt-plt-1-x32.d: Likewise.
* testsuite/ld-x86-64/ibt-plt-2a-x32.d: Likewise.
* testsuite/ld-x86-64/ibt-plt-2c-x32.d: Likewise.
* testsuite/ld-x86-64/ibt-plt-3a-x32.d: Likewise.
* testsuite/ld-x86-64/ibt-plt-3c-x32.d: Likewise.
* testsuite/ld-i386/ibt-plt-2b.d: Pass --hash-style=sysv to ld
and dump unwind information.
* testsuite/ld-i386/ibt-plt-2d.d: Likewise.
* testsuite/ld-i386/ibt-plt-3b.d: Likewise.
* testsuite/ld-i386/ibt-plt-3d.d: Likewise.
* testsuite/ld-x86-64/ibt-plt-2b-x32.d: Likewise.
* testsuite/ld-x86-64/ibt-plt-2b.d: Likewise.
* testsuite/ld-x86-64/ibt-plt-2d-x32.d: Likewise.
* testsuite/ld-x86-64/ibt-plt-2d.d: Likewise.
* testsuite/ld-x86-64/ibt-plt-3b-x32.d: Likewise.
* testsuite/ld-x86-64/ibt-plt-3b.d: Likewise.
* testsuite/ld-x86-64/ibt-plt-3d-x32.d: Likewise.
* testsuite/ld-x86-64/ibt-plt-3d.d: Likewise.
2017-08-31 H.J. Lu <hongjiu.lu@intel.com>
PR ld/22048

View File

@ -37,7 +37,7 @@ Disassembly of section .text:
0+200 <foo>:
+[a-f0-9]+: 53 push %ebx
+[a-f0-9]+: e8 18 00 00 00 call 21e <__x86.get_pc_thunk.bx>
+[a-f0-9]+: 81 c3 22 11 00 00 add \$0x1122,%ebx
+[a-f0-9]+: 81 c3 36 11 00 00 add \$0x1136,%ebx
+[a-f0-9]+: 83 ec 08 sub \$0x8,%esp
+[a-f0-9]+: e8 dc ff ff ff call 1f0 <bar2@plt>
+[a-f0-9]+: e8 c7 ff ff ff call 1e0 <bar1@plt>

View File

@ -38,7 +38,7 @@ Disassembly of section .text:
0+200 <foo>:
+[a-f0-9]+: 53 push %ebx
+[a-f0-9]+: e8 18 00 00 00 call 21e <__x86.get_pc_thunk.bx>
+[a-f0-9]+: 81 c3 22 11 00 00 add \$0x1122,%ebx
+[a-f0-9]+: 81 c3 36 11 00 00 add \$0x1136,%ebx
+[a-f0-9]+: 83 ec 08 sub \$0x8,%esp
+[a-f0-9]+: e8 dc ff ff ff call 1f0 <bar2@plt>
+[a-f0-9]+: e8 c7 ff ff ff call 1e0 <bar1@plt>

View File

@ -1,7 +1,52 @@
#source: ibt-plt-2.s
#as: --32
#ld: -shared -m elf_i386 -z ibtplt
#readelf: -n
#ld: -shared -m elf_i386 -z ibtplt --hash-style=sysv
#readelf: -n -wf
Contents of the .eh_frame section:
0+ 00000014 00000000 CIE
Version: 1
Augmentation: "zR"
Code alignment factor: 1
Data alignment factor: -4
Return address column: 8
Augmentation data: 1b
DW_CFA_def_cfa: r4 \(esp\) ofs 4
DW_CFA_offset: r8 \(eip\) at cfa-4
DW_CFA_nop
DW_CFA_nop
0+18 0000001c 0000001c FDE cie=00000000 pc=00000200..0000021e
DW_CFA_advance_loc: 1 to 00000201
DW_CFA_def_cfa_offset: 8
DW_CFA_offset: r3 \(ebx\) at cfa-8
DW_CFA_advance_loc: 14 to 0000020f
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 13 to 0000021c
DW_CFA_def_cfa_offset: 8
DW_CFA_advance_loc: 1 to 0000021d
DW_CFA_restore: r3 \(ebx\)
DW_CFA_def_cfa_offset: 4
0+38 00000010 0000003c FDE cie=00000000 pc=0000021e..00000222
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
0+4c 00000020 00000050 FDE cie=00000000 pc=000001b0..000001e0
DW_CFA_def_cfa_offset: 8
DW_CFA_advance_loc: 6 to 000001b6
DW_CFA_def_cfa_offset: 12
DW_CFA_advance_loc: 10 to 000001c0
DW_CFA_def_cfa_expression \(DW_OP_breg4 \(esp\): 4; DW_OP_breg8 \(eip\): 0; DW_OP_lit15; DW_OP_and; DW_OP_lit9; DW_OP_ge; DW_OP_lit2; DW_OP_shl; DW_OP_plus\)
0+70 00000010 00000074 FDE cie=00000000 pc=000001e0..00000200
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
Displaying notes found in: .note.gnu.property
Owner Data size Description

View File

@ -38,7 +38,7 @@ Disassembly of section .text:
0+200 <foo>:
+[a-f0-9]+: 53 push %ebx
+[a-f0-9]+: e8 18 00 00 00 call 21e <__x86.get_pc_thunk.bx>
+[a-f0-9]+: 81 c3 22 11 00 00 add \$0x1122,%ebx
+[a-f0-9]+: 81 c3 36 11 00 00 add \$0x1136,%ebx
+[a-f0-9]+: 83 ec 08 sub \$0x8,%esp
+[a-f0-9]+: e8 dc ff ff ff call 1f0 <bar2@plt>
+[a-f0-9]+: e8 c7 ff ff ff call 1e0 <bar1@plt>

View File

@ -1,7 +1,52 @@
#source: ibt-plt-2.s
#as: --32
#ld: -shared -m elf_i386 -z ibt
#readelf: -n
#ld: -shared -m elf_i386 -z ibt --hash-style=sysv
#readelf: -n -wf
Contents of the .eh_frame section:
0+ 00000014 00000000 CIE
Version: 1
Augmentation: "zR"
Code alignment factor: 1
Data alignment factor: -4
Return address column: 8
Augmentation data: 1b
DW_CFA_def_cfa: r4 \(esp\) ofs 4
DW_CFA_offset: r8 \(eip\) at cfa-4
DW_CFA_nop
DW_CFA_nop
0+18 0000001c 0000001c FDE cie=00000000 pc=00000200..0000021e
DW_CFA_advance_loc: 1 to 00000201
DW_CFA_def_cfa_offset: 8
DW_CFA_offset: r3 \(ebx\) at cfa-8
DW_CFA_advance_loc: 14 to 0000020f
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 13 to 0000021c
DW_CFA_def_cfa_offset: 8
DW_CFA_advance_loc: 1 to 0000021d
DW_CFA_restore: r3 \(ebx\)
DW_CFA_def_cfa_offset: 4
0+38 00000010 0000003c FDE cie=00000000 pc=0000021e..00000222
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
0+4c 00000020 00000050 FDE cie=00000000 pc=000001b0..000001e0
DW_CFA_def_cfa_offset: 8
DW_CFA_advance_loc: 6 to 000001b6
DW_CFA_def_cfa_offset: 12
DW_CFA_advance_loc: 10 to 000001c0
DW_CFA_def_cfa_expression \(DW_OP_breg4 \(esp\): 4; DW_OP_breg8 \(eip\): 0; DW_OP_lit15; DW_OP_and; DW_OP_lit9; DW_OP_ge; DW_OP_lit2; DW_OP_shl; DW_OP_plus\)
0+70 00000010 00000074 FDE cie=00000000 pc=000001e0..00000200
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
Displaying notes found in: .note.gnu.property
Owner Data size Description

View File

@ -38,7 +38,7 @@ Disassembly of section .text:
0+1e0 <foo>:
+[a-f0-9]+: 53 push %ebx
+[a-f0-9]+: e8 18 00 00 00 call 1fe <__x86.get_pc_thunk.bx>
+[a-f0-9]+: 81 c3 06 11 00 00 add \$0x1106,%ebx
+[a-f0-9]+: 81 c3 1a 11 00 00 add \$0x111a,%ebx
+[a-f0-9]+: 83 ec 08 sub \$0x8,%esp
+[a-f0-9]+: e8 dc ff ff ff call 1d0 <bar2@plt>
+[a-f0-9]+: e8 c7 ff ff ff call 1c0 <bar1@plt>

View File

@ -1,5 +1,49 @@
#source: ibt-plt-3.s
#as: --32
#ld: -shared -m elf_i386 -z ibtplt
#readelf: -n
#ld: -shared -m elf_i386 -z ibtplt --hash-style=sysv
#readelf: -wf -n
Contents of the .eh_frame section:
0+ 00000014 00000000 CIE
Version: 1
Augmentation: "zR"
Code alignment factor: 1
Data alignment factor: -4
Return address column: 8
Augmentation data: 1b
DW_CFA_def_cfa: r4 \(esp\) ofs 4
DW_CFA_offset: r8 \(eip\) at cfa-4
DW_CFA_nop
DW_CFA_nop
0+18 0000001c 0000001c FDE cie=00000000 pc=000001e0..000001fe
DW_CFA_advance_loc: 1 to 000001e1
DW_CFA_def_cfa_offset: 8
DW_CFA_offset: r3 \(ebx\) at cfa-8
DW_CFA_advance_loc: 14 to 000001ef
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 13 to 000001fc
DW_CFA_def_cfa_offset: 8
DW_CFA_advance_loc: 1 to 000001fd
DW_CFA_restore: r3 \(ebx\)
DW_CFA_def_cfa_offset: 4
0+38 00000010 0000003c FDE cie=00000000 pc=000001fe..00000202
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
0+4c 00000020 00000050 FDE cie=00000000 pc=00000190..000001c0
DW_CFA_def_cfa_offset: 8
DW_CFA_advance_loc: 6 to 00000196
DW_CFA_def_cfa_offset: 12
DW_CFA_advance_loc: 10 to 000001a0
DW_CFA_def_cfa_expression \(DW_OP_breg4 \(esp\): 4; DW_OP_breg8 \(eip\): 0; DW_OP_lit15; DW_OP_and; DW_OP_lit9; DW_OP_ge; DW_OP_lit2; DW_OP_shl; DW_OP_plus\)
0+70 00000010 00000074 FDE cie=00000000 pc=000001c0..000001e0
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop

View File

@ -38,7 +38,7 @@ Disassembly of section .text:
0+1e0 <foo>:
+[a-f0-9]+: 53 push %ebx
+[a-f0-9]+: e8 18 00 00 00 call 1fe <__x86.get_pc_thunk.bx>
+[a-f0-9]+: 81 c3 06 11 00 00 add \$0x1106,%ebx
+[a-f0-9]+: 81 c3 1a 11 00 00 add \$0x111a,%ebx
+[a-f0-9]+: 83 ec 08 sub \$0x8,%esp
+[a-f0-9]+: e8 dc ff ff ff call 1d0 <bar2@plt>
+[a-f0-9]+: e8 c7 ff ff ff call 1c0 <bar1@plt>

View File

@ -1,7 +1,52 @@
#source: ibt-plt-3.s
#as: --32
#ld: -shared -m elf_i386 -z ibt
#readelf: -n
#ld: -shared -m elf_i386 -z ibt --hash-style=sysv
#readelf: -wf -n
Contents of the .eh_frame section:
0+ 00000014 00000000 CIE
Version: 1
Augmentation: "zR"
Code alignment factor: 1
Data alignment factor: -4
Return address column: 8
Augmentation data: 1b
DW_CFA_def_cfa: r4 \(esp\) ofs 4
DW_CFA_offset: r8 \(eip\) at cfa-4
DW_CFA_nop
DW_CFA_nop
0+18 0000001c 0000001c FDE cie=00000000 pc=00000200..0000021e
DW_CFA_advance_loc: 1 to 00000201
DW_CFA_def_cfa_offset: 8
DW_CFA_offset: r3 \(ebx\) at cfa-8
DW_CFA_advance_loc: 14 to 0000020f
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 13 to 0000021c
DW_CFA_def_cfa_offset: 8
DW_CFA_advance_loc: 1 to 0000021d
DW_CFA_restore: r3 \(ebx\)
DW_CFA_def_cfa_offset: 4
0+38 00000010 0000003c FDE cie=00000000 pc=0000021e..00000222
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
0+4c 00000020 00000050 FDE cie=00000000 pc=000001b0..000001e0
DW_CFA_def_cfa_offset: 8
DW_CFA_advance_loc: 6 to 000001b6
DW_CFA_def_cfa_offset: 12
DW_CFA_advance_loc: 10 to 000001c0
DW_CFA_def_cfa_expression \(DW_OP_breg4 \(esp\): 4; DW_OP_breg8 \(eip\): 0; DW_OP_lit15; DW_OP_and; DW_OP_lit9; DW_OP_ge; DW_OP_lit2; DW_OP_shl; DW_OP_plus\)
0+70 00000010 00000074 FDE cie=00000000 pc=000001e0..00000200
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
Displaying notes found in: .note.gnu.property
Owner Data size Description

View File

@ -9,8 +9,8 @@
Disassembly of section .plt:
0+1c0 <.plt>:
+[a-f0-9]+: ff 35 6a 01 20 00 pushq 0x20016a\(%rip\) # 200330 <_GLOBAL_OFFSET_TABLE_\+0x8>
+[a-f0-9]+: ff 25 6c 01 20 00 jmpq \*0x20016c\(%rip\) # 200338 <_GLOBAL_OFFSET_TABLE_\+0x10>
+[a-f0-9]+: ff 35 62 01 20 00 pushq 0x200162\(%rip\) # 200328 <_GLOBAL_OFFSET_TABLE_\+0x8>
+[a-f0-9]+: ff 25 64 01 20 00 jmpq \*0x200164\(%rip\) # 200330 <_GLOBAL_OFFSET_TABLE_\+0x10>
+[a-f0-9]+: 0f 1f 40 00 nopl 0x0\(%rax\)
+[a-f0-9]+: f3 0f 1e fa endbr64
+[a-f0-9]+: 68 00 00 00 00 pushq \$0x0
@ -25,12 +25,12 @@ Disassembly of section .plt.sec:
0+1f0 <bar1@plt>:
+[a-f0-9]+: f3 0f 1e fa endbr64
+[a-f0-9]+: ff 25 46 01 20 00 jmpq \*0x200146\(%rip\) # 200340 <bar1>
+[a-f0-9]+: ff 25 3e 01 20 00 jmpq \*0x20013e\(%rip\) # 200338 <bar1>
+[a-f0-9]+: 66 0f 1f 44 00 00 nopw 0x0\(%rax,%rax,1\)
0+200 <bar2@plt>:
+[a-f0-9]+: f3 0f 1e fa endbr64
+[a-f0-9]+: ff 25 3e 01 20 00 jmpq \*0x20013e\(%rip\) # 200348 <bar2>
+[a-f0-9]+: ff 25 36 01 20 00 jmpq \*0x200136\(%rip\) # 200340 <bar2>
+[a-f0-9]+: 66 0f 1f 44 00 00 nopw 0x0\(%rax,%rax,1\)
Disassembly of section .text:

View File

@ -9,8 +9,8 @@
Disassembly of section .plt:
0+1c0 <.plt>:
+[a-f0-9]+: ff 35 6a 01 20 00 pushq 0x20016a\(%rip\) # 200330 <_GLOBAL_OFFSET_TABLE_\+0x8>
+[a-f0-9]+: ff 25 6c 01 20 00 jmpq \*0x20016c\(%rip\) # 200338 <_GLOBAL_OFFSET_TABLE_\+0x10>
+[a-f0-9]+: ff 35 62 01 20 00 pushq 0x200162\(%rip\) # 200328 <_GLOBAL_OFFSET_TABLE_\+0x8>
+[a-f0-9]+: ff 25 64 01 20 00 jmpq \*0x200164\(%rip\) # 200330 <_GLOBAL_OFFSET_TABLE_\+0x10>
+[a-f0-9]+: 0f 1f 40 00 nopl 0x0\(%rax\)
+[a-f0-9]+: f3 0f 1e fa endbr64
+[a-f0-9]+: 68 00 00 00 00 pushq \$0x0
@ -25,12 +25,12 @@ Disassembly of section .plt.sec:
0+1f0 <bar1@plt>:
+[a-f0-9]+: f3 0f 1e fa endbr64
+[a-f0-9]+: ff 25 46 01 20 00 jmpq \*0x200146\(%rip\) # 200340 <bar1>
+[a-f0-9]+: ff 25 3e 01 20 00 jmpq \*0x20013e\(%rip\) # 200338 <bar1>
+[a-f0-9]+: 66 0f 1f 44 00 00 nopw 0x0\(%rax,%rax,1\)
0+200 <bar2@plt>:
+[a-f0-9]+: f3 0f 1e fa endbr64
+[a-f0-9]+: ff 25 3e 01 20 00 jmpq \*0x20013e\(%rip\) # 200348 <bar2>
+[a-f0-9]+: ff 25 36 01 20 00 jmpq \*0x200136\(%rip\) # 200340 <bar2>
+[a-f0-9]+: 66 0f 1f 44 00 00 nopw 0x0\(%rax,%rax,1\)
Disassembly of section .text:

View File

@ -1,7 +1,42 @@
#source: ibt-plt-2.s
#as: --x32
#ld: -shared -m elf32_x86_64 -z ibtplt
#readelf: -n
#ld: -shared -m elf32_x86_64 -z ibtplt --hash-style=sysv
#readelf: -n -wf
Contents of the .eh_frame section:
0+ 00000014 00000000 CIE
Version: 1
Augmentation: "zR"
Code alignment factor: 1
Data alignment factor: -8
Return address column: 16
Augmentation data: 1b
DW_CFA_def_cfa: r7 \(rsp\) ofs 8
DW_CFA_offset: r16 \(rip\) at cfa-8
DW_CFA_nop
DW_CFA_nop
0+18 00000014 0000001c FDE cie=00000000 pc=00000210..00000222
DW_CFA_advance_loc: 4 to 00000214
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 9 to 0000021d
DW_CFA_def_cfa_offset: 8
DW_CFA_nop
0+30 00000020 00000034 FDE cie=00000000 pc=000001c0..000001f0
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 6 to 000001c6
DW_CFA_def_cfa_offset: 24
DW_CFA_advance_loc: 10 to 000001d0
DW_CFA_def_cfa_expression \(DW_OP_breg7 \(rsp\): 8; DW_OP_breg16 \(rip\): 0; DW_OP_lit15; DW_OP_and; DW_OP_lit9; DW_OP_ge; DW_OP_lit3; DW_OP_shl; DW_OP_plus\)
0+54 00000010 00000058 FDE cie=00000000 pc=000001f0..00000210
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
Displaying notes found in: .note.gnu.property
Owner Data size Description

View File

@ -1,7 +1,46 @@
#source: ibt-plt-2.s
#as: --64 -defsym __64_bit__=1
#ld: -shared -m elf_x86_64 -z ibtplt
#readelf: -n
#ld: -shared -m elf_x86_64 -z ibtplt --hash-style=sysv
#readelf: -wf -n
Contents of the .eh_frame section:
0+ 0000000000000014 00000000 CIE
Version: 1
Augmentation: "zR"
Code alignment factor: 1
Data alignment factor: -8
Return address column: 16
Augmentation data: 1b
DW_CFA_def_cfa: r7 \(rsp\) ofs 8
DW_CFA_offset: r16 \(rip\) at cfa-8
DW_CFA_nop
DW_CFA_nop
0+18 0000000000000014 0000001c FDE cie=00000000 pc=00000000000002e0..00000000000002f2
DW_CFA_advance_loc: 4 to 00000000000002e4
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 9 to 00000000000002ed
DW_CFA_def_cfa_offset: 8
DW_CFA_nop
0+30 0000000000000024 00000034 FDE cie=00000000 pc=0000000000000290..00000000000002c0
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 6 to 0000000000000296
DW_CFA_def_cfa_offset: 24
DW_CFA_advance_loc: 10 to 00000000000002a0
DW_CFA_def_cfa_expression \(DW_OP_breg7 \(rsp\): 8; DW_OP_breg16 \(rip\): 0; DW_OP_lit15; DW_OP_and; DW_OP_lit10; DW_OP_ge; DW_OP_lit3; DW_OP_shl; DW_OP_plus\)
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
0+58 0000000000000010 0000005c FDE cie=00000000 pc=00000000000002c0..00000000000002e0
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
Displaying notes found in: .note.gnu.property
Owner Data size Description

View File

@ -9,8 +9,8 @@
Disassembly of section .plt:
0+1c0 <.plt>:
+[a-f0-9]+: ff 35 6a 01 20 00 pushq 0x20016a\(%rip\) # 200330 <_GLOBAL_OFFSET_TABLE_\+0x8>
+[a-f0-9]+: ff 25 6c 01 20 00 jmpq \*0x20016c\(%rip\) # 200338 <_GLOBAL_OFFSET_TABLE_\+0x10>
+[a-f0-9]+: ff 35 62 01 20 00 pushq 0x200162\(%rip\) # 200328 <_GLOBAL_OFFSET_TABLE_\+0x8>
+[a-f0-9]+: ff 25 64 01 20 00 jmpq \*0x200164\(%rip\) # 200330 <_GLOBAL_OFFSET_TABLE_\+0x10>
+[a-f0-9]+: 0f 1f 40 00 nopl 0x0\(%rax\)
+[a-f0-9]+: f3 0f 1e fa endbr64
+[a-f0-9]+: 68 00 00 00 00 pushq \$0x0
@ -25,12 +25,12 @@ Disassembly of section .plt.sec:
0+1f0 <bar1@plt>:
+[a-f0-9]+: f3 0f 1e fa endbr64
+[a-f0-9]+: ff 25 46 01 20 00 jmpq \*0x200146\(%rip\) # 200340 <bar1>
+[a-f0-9]+: ff 25 3e 01 20 00 jmpq \*0x20013e\(%rip\) # 200338 <bar1>
+[a-f0-9]+: 66 0f 1f 44 00 00 nopw 0x0\(%rax,%rax,1\)
0+200 <bar2@plt>:
+[a-f0-9]+: f3 0f 1e fa endbr64
+[a-f0-9]+: ff 25 3e 01 20 00 jmpq \*0x20013e\(%rip\) # 200348 <bar2>
+[a-f0-9]+: ff 25 36 01 20 00 jmpq \*0x200136\(%rip\) # 200340 <bar2>
+[a-f0-9]+: 66 0f 1f 44 00 00 nopw 0x0\(%rax,%rax,1\)
Disassembly of section .text:

View File

@ -1,7 +1,42 @@
#source: ibt-plt-2.s
#as: --x32
#ld: -shared -m elf32_x86_64 -z ibt
#readelf: -n
#ld: -shared -m elf32_x86_64 -z ibt --hash-style=sysv
#readelf: -n -wf
Contents of the .eh_frame section:
0+ 00000014 00000000 CIE
Version: 1
Augmentation: "zR"
Code alignment factor: 1
Data alignment factor: -8
Return address column: 16
Augmentation data: 1b
DW_CFA_def_cfa: r7 \(rsp\) ofs 8
DW_CFA_offset: r16 \(rip\) at cfa-8
DW_CFA_nop
DW_CFA_nop
0+18 00000014 0000001c FDE cie=00000000 pc=00000210..00000222
DW_CFA_advance_loc: 4 to 00000214
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 9 to 0000021d
DW_CFA_def_cfa_offset: 8
DW_CFA_nop
0+30 00000020 00000034 FDE cie=00000000 pc=000001c0..000001f0
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 6 to 000001c6
DW_CFA_def_cfa_offset: 24
DW_CFA_advance_loc: 10 to 000001d0
DW_CFA_def_cfa_expression \(DW_OP_breg7 \(rsp\): 8; DW_OP_breg16 \(rip\): 0; DW_OP_lit15; DW_OP_and; DW_OP_lit9; DW_OP_ge; DW_OP_lit3; DW_OP_shl; DW_OP_plus\)
0+54 00000010 00000058 FDE cie=00000000 pc=000001f0..00000210
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
Displaying notes found in: .note.gnu.property
Owner Data size Description

View File

@ -1,7 +1,46 @@
#source: ibt-plt-2.s
#as: --64 -defsym __64_bit__=1
#ld: -shared -m elf_x86_64 -z ibt
#readelf: -n
#ld: -shared -m elf_x86_64 -z ibt --hash-style=sysv
#readelf: -wf -n
Contents of the .eh_frame section:
0+ 0000000000000014 00000000 CIE
Version: 1
Augmentation: "zR"
Code alignment factor: 1
Data alignment factor: -8
Return address column: 16
Augmentation data: 1b
DW_CFA_def_cfa: r7 \(rsp\) ofs 8
DW_CFA_offset: r16 \(rip\) at cfa-8
DW_CFA_nop
DW_CFA_nop
0+18 0000000000000014 0000001c FDE cie=00000000 pc=00000000000002e0..00000000000002f2
DW_CFA_advance_loc: 4 to 00000000000002e4
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 9 to 00000000000002ed
DW_CFA_def_cfa_offset: 8
DW_CFA_nop
0+30 0000000000000024 00000034 FDE cie=00000000 pc=0000000000000290..00000000000002c0
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 6 to 0000000000000296
DW_CFA_def_cfa_offset: 24
DW_CFA_advance_loc: 10 to 00000000000002a0
DW_CFA_def_cfa_expression \(DW_OP_breg7 \(rsp\): 8; DW_OP_breg16 \(rip\): 0; DW_OP_lit15; DW_OP_and; DW_OP_lit10; DW_OP_ge; DW_OP_lit3; DW_OP_shl; DW_OP_plus\)
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
0+58 0000000000000010 0000005c FDE cie=00000000 pc=00000000000002c0..00000000000002e0
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
Displaying notes found in: .note.gnu.property
Owner Data size Description

View File

@ -9,8 +9,8 @@
Disassembly of section .plt:
0+1a0 <.plt>:
+[a-f0-9]+: ff 35 52 01 20 00 pushq 0x200152\(%rip\) # 2002f8 <_GLOBAL_OFFSET_TABLE_\+0x8>
+[a-f0-9]+: ff 25 54 01 20 00 jmpq \*0x200154\(%rip\) # 200300 <_GLOBAL_OFFSET_TABLE_\+0x10>
+[a-f0-9]+: ff 35 4a 01 20 00 pushq 0x20014a\(%rip\) # 2002f0 <_GLOBAL_OFFSET_TABLE_\+0x8>
+[a-f0-9]+: ff 25 4c 01 20 00 jmpq \*0x20014c\(%rip\) # 2002f8 <_GLOBAL_OFFSET_TABLE_\+0x10>
+[a-f0-9]+: 0f 1f 40 00 nopl 0x0\(%rax\)
+[a-f0-9]+: f3 0f 1e fa endbr64
+[a-f0-9]+: 68 00 00 00 00 pushq \$0x0
@ -25,12 +25,12 @@ Disassembly of section .plt.sec:
0+1d0 <bar1@plt>:
+[a-f0-9]+: f3 0f 1e fa endbr64
+[a-f0-9]+: ff 25 2e 01 20 00 jmpq \*0x20012e\(%rip\) # 200308 <bar1>
+[a-f0-9]+: ff 25 26 01 20 00 jmpq \*0x200126\(%rip\) # 200300 <bar1>
+[a-f0-9]+: 66 0f 1f 44 00 00 nopw 0x0\(%rax,%rax,1\)
0+1e0 <bar2@plt>:
+[a-f0-9]+: f3 0f 1e fa endbr64
+[a-f0-9]+: ff 25 26 01 20 00 jmpq \*0x200126\(%rip\) # 200310 <bar2>
+[a-f0-9]+: ff 25 1e 01 20 00 jmpq \*0x20011e\(%rip\) # 200308 <bar2>
+[a-f0-9]+: 66 0f 1f 44 00 00 nopw 0x0\(%rax,%rax,1\)
Disassembly of section .text:

View File

@ -1,5 +1,39 @@
#source: ibt-plt-3.s
#as: --x32
#ld: -shared -m elf32_x86_64 -z ibtplt
#readelf: -n
#ld: -shared -m elf32_x86_64 -z ibtplt --hash-style=sysv
#readelf: -wf -n
Contents of the .eh_frame section:
0+ 00000014 00000000 CIE
Version: 1
Augmentation: "zR"
Code alignment factor: 1
Data alignment factor: -8
Return address column: 16
Augmentation data: 1b
DW_CFA_def_cfa: r7 \(rsp\) ofs 8
DW_CFA_offset: r16 \(rip\) at cfa-8
DW_CFA_nop
DW_CFA_nop
0+18 00000014 0000001c FDE cie=00000000 pc=000001f0..00000202
DW_CFA_advance_loc: 4 to 000001f4
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 9 to 000001fd
DW_CFA_def_cfa_offset: 8
DW_CFA_nop
0+30 00000020 00000034 FDE cie=00000000 pc=000001a0..000001d0
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 6 to 000001a6
DW_CFA_def_cfa_offset: 24
DW_CFA_advance_loc: 10 to 000001b0
DW_CFA_def_cfa_expression \(DW_OP_breg7 \(rsp\): 8; DW_OP_breg16 \(rip\): 0; DW_OP_lit15; DW_OP_and; DW_OP_lit9; DW_OP_ge; DW_OP_lit3; DW_OP_shl; DW_OP_plus\)
0+54 00000010 00000058 FDE cie=00000000 pc=000001d0..000001f0
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop

View File

@ -1,5 +1,43 @@
#source: ibt-plt-3.s
#as: --64 -defsym __64_bit__=1
#ld: -shared -m elf_x86_64 -z ibtplt
#readelf: -n
#ld: -shared -m elf_x86_64 -z ibtplt --hash-style=sysv
#readelf: -wf -n
Contents of the .eh_frame section:
0+ 0000000000000014 00000000 CIE
Version: 1
Augmentation: "zR"
Code alignment factor: 1
Data alignment factor: -8
Return address column: 16
Augmentation data: 1b
DW_CFA_def_cfa: r7 \(rsp\) ofs 8
DW_CFA_offset: r16 \(rip\) at cfa-8
DW_CFA_nop
DW_CFA_nop
0+18 0000000000000014 0000001c FDE cie=00000000 pc=00000000000002a0..00000000000002b2
DW_CFA_advance_loc: 4 to 00000000000002a4
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 9 to 00000000000002ad
DW_CFA_def_cfa_offset: 8
DW_CFA_nop
0+30 0000000000000024 00000034 FDE cie=00000000 pc=0000000000000250..0000000000000280
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 6 to 0000000000000256
DW_CFA_def_cfa_offset: 24
DW_CFA_advance_loc: 10 to 0000000000000260
DW_CFA_def_cfa_expression \(DW_OP_breg7 \(rsp\): 8; DW_OP_breg16 \(rip\): 0; DW_OP_lit15; DW_OP_and; DW_OP_lit10; DW_OP_ge; DW_OP_lit3; DW_OP_shl; DW_OP_plus\)
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
0+58 0000000000000010 0000005c FDE cie=00000000 pc=0000000000000280..00000000000002a0
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop

View File

@ -9,8 +9,8 @@
Disassembly of section .plt:
0+1c0 <.plt>:
+[a-f0-9]+: ff 35 6a 01 20 00 pushq 0x20016a\(%rip\) # 200330 <_GLOBAL_OFFSET_TABLE_\+0x8>
+[a-f0-9]+: ff 25 6c 01 20 00 jmpq \*0x20016c\(%rip\) # 200338 <_GLOBAL_OFFSET_TABLE_\+0x10>
+[a-f0-9]+: ff 35 62 01 20 00 pushq 0x200162\(%rip\) # 200328 <_GLOBAL_OFFSET_TABLE_\+0x8>
+[a-f0-9]+: ff 25 64 01 20 00 jmpq \*0x200164\(%rip\) # 200330 <_GLOBAL_OFFSET_TABLE_\+0x10>
+[a-f0-9]+: 0f 1f 40 00 nopl 0x0\(%rax\)
+[a-f0-9]+: f3 0f 1e fa endbr64
+[a-f0-9]+: 68 00 00 00 00 pushq \$0x0
@ -25,12 +25,12 @@ Disassembly of section .plt.sec:
0+1f0 <bar1@plt>:
+[a-f0-9]+: f3 0f 1e fa endbr64
+[a-f0-9]+: ff 25 46 01 20 00 jmpq \*0x200146\(%rip\) # 200340 <bar1>
+[a-f0-9]+: ff 25 3e 01 20 00 jmpq \*0x20013e\(%rip\) # 200338 <bar1>
+[a-f0-9]+: 66 0f 1f 44 00 00 nopw 0x0\(%rax,%rax,1\)
0+200 <bar2@plt>:
+[a-f0-9]+: f3 0f 1e fa endbr64
+[a-f0-9]+: ff 25 3e 01 20 00 jmpq \*0x20013e\(%rip\) # 200348 <bar2>
+[a-f0-9]+: ff 25 36 01 20 00 jmpq \*0x200136\(%rip\) # 200340 <bar2>
+[a-f0-9]+: 66 0f 1f 44 00 00 nopw 0x0\(%rax,%rax,1\)
Disassembly of section .text:

View File

@ -1,7 +1,42 @@
#source: ibt-plt-3.s
#as: --x32
#ld: -shared -m elf32_x86_64 -z ibt
#readelf: -n
#ld: -shared -m elf32_x86_64 -z ibt --hash-style=sysv
#readelf: -wf -n
Contents of the .eh_frame section:
0+ 00000014 00000000 CIE
Version: 1
Augmentation: "zR"
Code alignment factor: 1
Data alignment factor: -8
Return address column: 16
Augmentation data: 1b
DW_CFA_def_cfa: r7 \(rsp\) ofs 8
DW_CFA_offset: r16 \(rip\) at cfa-8
DW_CFA_nop
DW_CFA_nop
0+18 00000014 0000001c FDE cie=00000000 pc=00000210..00000222
DW_CFA_advance_loc: 4 to 00000214
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 9 to 0000021d
DW_CFA_def_cfa_offset: 8
DW_CFA_nop
0+30 00000020 00000034 FDE cie=00000000 pc=000001c0..000001f0
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 6 to 000001c6
DW_CFA_def_cfa_offset: 24
DW_CFA_advance_loc: 10 to 000001d0
DW_CFA_def_cfa_expression \(DW_OP_breg7 \(rsp\): 8; DW_OP_breg16 \(rip\): 0; DW_OP_lit15; DW_OP_and; DW_OP_lit9; DW_OP_ge; DW_OP_lit3; DW_OP_shl; DW_OP_plus\)
0+54 00000010 00000058 FDE cie=00000000 pc=000001f0..00000210
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
Displaying notes found in: .note.gnu.property
Owner Data size Description

View File

@ -1,7 +1,46 @@
#source: ibt-plt-3.s
#as: --64 -defsym __64_bit__=1
#ld: -shared -m elf_x86_64 -z ibt
#readelf: -n
#ld: -shared -m elf_x86_64 -z ibt --hash-style=sysv
#readelf: -wf -n
Contents of the .eh_frame section:
0+ 0000000000000014 00000000 CIE
Version: 1
Augmentation: "zR"
Code alignment factor: 1
Data alignment factor: -8
Return address column: 16
Augmentation data: 1b
DW_CFA_def_cfa: r7 \(rsp\) ofs 8
DW_CFA_offset: r16 \(rip\) at cfa-8
DW_CFA_nop
DW_CFA_nop
0+18 0000000000000014 0000001c FDE cie=00000000 pc=00000000000002e0..00000000000002f2
DW_CFA_advance_loc: 4 to 00000000000002e4
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 9 to 00000000000002ed
DW_CFA_def_cfa_offset: 8
DW_CFA_nop
0+30 0000000000000024 00000034 FDE cie=00000000 pc=0000000000000290..00000000000002c0
DW_CFA_def_cfa_offset: 16
DW_CFA_advance_loc: 6 to 0000000000000296
DW_CFA_def_cfa_offset: 24
DW_CFA_advance_loc: 10 to 00000000000002a0
DW_CFA_def_cfa_expression \(DW_OP_breg7 \(rsp\): 8; DW_OP_breg16 \(rip\): 0; DW_OP_lit15; DW_OP_and; DW_OP_lit10; DW_OP_ge; DW_OP_lit3; DW_OP_shl; DW_OP_plus\)
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
0+58 0000000000000010 0000005c FDE cie=00000000 pc=00000000000002c0..00000000000002e0
DW_CFA_nop
DW_CFA_nop
DW_CFA_nop
Displaying notes found in: .note.gnu.property
Owner Data size Description