1#! /bin/sh 2# Copyright (C) 2020 Red Hat, Inc. 3# This file is part of elfutils. 4# 5# This file is free software; you can redistribute it and/or modify 6# it under the terms of the GNU General Public License as published by 7# the Free Software Foundation; either version 3 of the License, or 8# (at your option) any later version. 9# 10# elfutils is distributed in the hope that it will be useful, but 11# WITHOUT ANY WARRANTY; without even the implied warranty of 12# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13# GNU General Public License for more details. 14# 15# You should have received a copy of the GNU General Public License 16# along with this program. If not, see <http://www.gnu.org/licenses/>. 17 18. $srcdir/test-subr.sh 19 20# See run-readelf-n.sh 21testfiles testfile-gnu-property-note-aarch64 22 23testrun_compare ${abs_top_builddir}/src/readelf --debug-dump=frames testfile-gnu-property-note-aarch64 <<\EOF 24 25Call frame search table section [17] '.eh_frame_hdr': 26 version: 1 27 eh_frame_ptr_enc: 0x1b (sdata4 pcrel) 28 fde_count_enc: 0x3 (udata4) 29 table_enc: 0x3b (sdata4 datarel) 30 eh_frame_ptr: 0x44 (offset: 0x758) 31 fde_count: 7 32 Table: 33 0xfffffe70 (offset: 0x580) -> 0x5c fde=[ 14] 34 0xfffffea0 (offset: 0x5b0) -> 0x70 fde=[ 28] 35 0xfffffee0 (offset: 0x5f0) -> 0x84 fde=[ 3c] 36 0xffffff20 (offset: 0x630) -> 0xac fde=[ 64] 37 0xffffff28 (offset: 0x638) -> 0xc0 fde=[ 78] 38 0xffffff40 (offset: 0x650) -> 0xd8 fde=[ 90] 39 0xffffffc0 (offset: 0x6d0) -> 0x110 fde=[ c8] 40 41Call frame information section [18] '.eh_frame' at offset 0x758: 42 43 [ 0] CIE length=16 44 CIE_id: 0 45 version: 1 46 augmentation: "zR" 47 code_alignment_factor: 4 48 data_alignment_factor: -8 49 return_address_register: 30 50 Augmentation data: 0x1b (FDE address encoding: sdata4 pcrel) 51 52 Program: 53 def_cfa r31 (sp) at offset 0 54 55 [ 14] FDE length=16 cie=[ 0] 56 CIE_pointer: 24 57 initial_location: 0x0000000000400580 (offset: 0x580) 58 address_range: 0x30 (end offset: 0x5b0) 59 60 Program: 61 nop 62 nop 63 nop 64 65 [ 28] FDE length=16 cie=[ 0] 66 CIE_pointer: 44 67 initial_location: 0x00000000004005b0 (offset: 0x5b0) 68 address_range: 0x3c (end offset: 0x5ec) 69 70 Program: 71 nop 72 nop 73 nop 74 75 [ 3c] FDE length=36 cie=[ 0] 76 CIE_pointer: 64 77 initial_location: 0x00000000004005f0 (offset: 0x5f0) 78 address_range: 0x38 (end offset: 0x628) 79 80 Program: 81 advance_loc 1 to 0x5f4 82 AARCH64_negate_ra_state 83 advance_loc 1 to 0x5f8 84 def_cfa_offset 32 85 offset r29 (x29) at cfa-32 86 offset r30 (x30) at cfa-24 87 advance_loc 2 to 0x600 88 offset r19 (x19) at cfa-16 89 advance_loc 8 to 0x620 90 restore r30 (x30) 91 restore r29 (x29) 92 restore r19 (x19) 93 def_cfa_offset 0 94 advance_loc 1 to 0x624 95 AARCH64_negate_ra_state 96 nop 97 nop 98 nop 99 100 [ 64] FDE length=16 cie=[ 0] 101 CIE_pointer: 104 102 initial_location: 0x0000000000400630 (offset: 0x630) 103 address_range: 0x8 (end offset: 0x638) 104 105 Program: 106 nop 107 nop 108 nop 109 110 [ 78] FDE length=20 cie=[ 0] 111 CIE_pointer: 124 112 initial_location: 0x0000000000400638 (offset: 0x638) 113 address_range: 0xc (end offset: 0x644) 114 115 Program: 116 nop 117 nop 118 nop 119 nop 120 nop 121 nop 122 nop 123 124 [ 90] FDE length=52 cie=[ 0] 125 CIE_pointer: 148 126 initial_location: 0x0000000000400650 (offset: 0x650) 127 address_range: 0x80 (end offset: 0x6d0) 128 129 Program: 130 advance_loc 1 to 0x654 131 AARCH64_negate_ra_state 132 advance_loc 1 to 0x658 133 def_cfa_offset 64 134 offset r29 (x29) at cfa-64 135 offset r30 (x30) at cfa-56 136 advance_loc 2 to 0x660 137 offset r19 (x19) at cfa-48 138 offset r20 (x20) at cfa-40 139 advance_loc 3 to 0x66c 140 offset r21 (x21) at cfa-32 141 offset r22 (x22) at cfa-24 142 advance_loc 5 to 0x680 143 offset r23 (x23) at cfa-16 144 offset r24 (x24) at cfa-8 145 advance_loc 18 to 0x6c8 146 restore r30 (x30) 147 restore r29 (x29) 148 restore r23 (x23) 149 restore r24 (x24) 150 restore r21 (x21) 151 restore r22 (x22) 152 restore r19 (x19) 153 restore r20 (x20) 154 def_cfa_offset 0 155 advance_loc 1 to 0x6cc 156 AARCH64_negate_ra_state 157 nop 158 nop 159 160 [ c8] FDE length=16 cie=[ 0] 161 CIE_pointer: 204 162 initial_location: 0x00000000004006d0 (offset: 0x6d0) 163 address_range: 0x8 (end offset: 0x6d8) 164 165 Program: 166 nop 167 nop 168 nop 169 170 [ dc] Zero terminator 171EOF 172 173exit 0 174