Bug 589495

Summary: Backport DW_FORM_ref_addr fix
Product: [Fedora] Fedora Reporter: Jan Kratochvil <jan.kratochvil>
Component: fpcAssignee: Joost van der Sluis <joost>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: low Docs Contact:
Priority: low    
Version: 14CC: joost, tbzatek
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-04-28 09:49:56 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Jan Kratochvil 2010-05-06 10:23:12 UTC
Description of problem:
Discussed at:
Size of DW_FORM_ref_addr in DWARF 3 and thearcher-jankratochvil-fedora13 branch
http://sourceware.org/ml/archer/2010-q2/msg00013.html
Fedora tools (at least the Rawhide ones) use the fixed form of DW_FORM_ref_addr.  fpc-HEAD also uses the fixed form.  Just fpc-2.4.0 still uses the wrong size as it has been in use by GDB before the Tom Tromey's fix e3fa87d5f376db4523a844acc01199785d11b582.

Version-Release number of selected component (if applicable):
fpc-2.4.0-1.fc14

How reproducible:
Always.

Steps to Reproduce:
1. In gdb/testsuite: runtest gdb.pascal/arrays.exp
2. readelf -wi gdb.pascal/arrays

Actual results:
 <1><93>: Abbrev Number: 2 (DW_TAG_variable)
    <94>   DW_AT_name        : StatArrInt
    <9f>   DW_AT_location    : 9 byte block: 3 b0 51 65 0 0 0 0 0       (DW_OP_addr: 6551b0)
    <a9>   DW_AT_type        : <0x279>
 <-3><ad>: Abbrev Number: 3 (DW_TAG_variable)
  ^^

Expected results:
 <1><93>: Abbrev Number: 2 (DW_TAG_variable)
    <94>   DW_AT_name        : StatArrInt
    <9f>   DW_AT_location    : 9 byte block: 3 b0 51 65 0 0 0 0 0       (DW_OP_addr: 6551b0)
    <a9>   DW_AT_type        : <0x279>
 <1><ad>: Abbrev Number: 3 (DW_TAG_variable)

Additional info:
fpc SVN commit:
------------------------------------------------------------------------
r15038 | joost | 2010-03-23 13:11:19 +0100 (Tue, 23 Mar 2010) | 1 line

 * Since Dwarf 3 the length of a DW_FORM_ref_addr is dependent on the used debug-format (32 or 64 bit), not on the target platform pointer size.
------------------------------------------------------------------------

Comment 1 Joost van der Sluis 2010-05-19 14:46:00 UTC
Version 2.4.2rc-1 will be available within a week. I'll wait for that version, if that's ok.

Comment 2 Bug Zapper 2010-07-30 11:33:41 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 14 development cycle.
Changing version to '14'.

More information and reason for this action is here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping