This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug libc/15407] New: Partial frame info in sysdeps/x86_64/start.S


http://sourceware.org/bugzilla/show_bug.cgi?id=15407

             Bug #: 15407
           Summary: Partial frame info in sysdeps/x86_64/start.S
           Product: glibc
           Version: 2.18
            Status: NEW
          Severity: normal
          Priority: P2
         Component: libc
        AssignedTo: unassigned@sourceware.org
        ReportedBy: hjl.tools@gmail.com
                CC: drepper.fsp@gmail.com, jan.kratochvil@redhat.com
    Classification: Unclassified


The commit:

commit 6a1bd2a100c958d30bbfe8c9b8f9071d24b7c3f4
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Mar 16 20:49:23 2012 +0100

      * sysdeps/x86_64/elf/start.S: Include <sysdep.h>.
      (_start): Add cfi_startproc, cfi_undefined for rip and cfi_endproc.

adds partial frame info in sysdeps/x86_64/start.S:

[hjl@gnu-6 build-x86_64-linux]$ objdump -drw csu/start.o

csu/start.o:     file format elf64-x86-64


Disassembly of section .text:

0000000000000000 <_start>:
   0:    31 ed                    xor    %ebp,%ebp
   2:    49 89 d1                 mov    %rdx,%r9
   5:    5e                       pop    %rsi
   6:    48 89 e2                 mov    %rsp,%rdx
   9:    48 83 e4 f0              and    $0xfffffffffffffff0,%rsp
   d:    50                       push   %rax
   e:    54                       push   %rsp
   f:    49 c7 c0 00 00 00 00     mov    $0x0,%r8    12: R_X86_64_32S   
__libc_csu_fini
  16:    48 c7 c1 00 00 00 00     mov    $0x0,%rcx    19: R_X86_64_32S   
__libc_csu_init
  1d:    48 c7 c7 00 00 00 00     mov    $0x0,%rdi    20: R_X86_64_32S    main
  24:    e8 00 00 00 00           callq  29 <_start+0x29>    25: R_X86_64_PC32 
  __libc_start_main-0x4
  29:    f4                       hlt    
[hjl@gnu-6 build-x86_64-linux]$ readelf -wf csu/start.o
Contents of the .eh_frame section:

00000000 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_undefined: r16 (rip)

00000018 00000014 0000001c FDE cie=00000000 pc=00000000..0000002a
  DW_CFA_nop
  DW_CFA_nop
  DW_CFA_nop
  DW_CFA_nop
  DW_CFA_nop
  DW_CFA_nop
  DW_CFA_nop

[hjl@gnu-6 build-x86_64-linux]$ 

Since it ignores stack ops, stack unwind fails in certain cases.
exception_static_test in gold is one example.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]