------- Additional Comments From dirkjan at magma-da dot com 2006-04-07 06:24 ------- Subject: Re: gprof reads executable 10x slower on opteron/x86_64
Note that the real problem is not stabs or not. But 10x slowdown on opteron64 bit when gprof reads the executable. Adding -gstab1 then solves the problem. Also I noticed the resolves in gprof are done via a function with stabs and not the one with dwarf. using a gcc4.0.2 compiler and binutils 2.16.1 on linux72: main.cxx: #include "iostream.h" int main(){ cout<<"Hello world"; } g++ main.cxx objdump a.out .... Sections: Idx Name Size VMA LMA File off Algn 0 .interp 00000013 08048114 08048114 00000114 2**0 CONTENTS, ALLOC, LOAD, READONLY, DATA 1 .note.ABI-tag 00000020 08048128 08048128 00000128 2**2 CONTENTS, ALLOC, LOAD, READONLY, DATA 2 .hash 00000048 08048148 08048148 00000148 2**2 CONTENTS, ALLOC, LOAD, READONLY, DATA 3 .dynsym 000000d0 08048190 08048190 00000190 2**2 CONTENTS, ALLOC, LOAD, READONLY, DATA 4 .dynstr 0000016d 08048260 08048260 00000260 2**0 CONTENTS, ALLOC, LOAD, READONLY, DATA 5 .gnu.version 0000001a 080483ce 080483ce 000003ce 2**1 CONTENTS, ALLOC, LOAD, READONLY, DATA 6 .gnu.version_r 00000070 080483e8 080483e8 000003e8 2**2 CONTENTS, ALLOC, LOAD, READONLY, DATA 7 .rel.dyn 00000010 08048458 08048458 00000458 2**2 CONTENTS, ALLOC, LOAD, READONLY, DATA 8 .rel.plt 00000038 08048468 08048468 00000468 2**2 CONTENTS, ALLOC, LOAD, READONLY, DATA 9 .init 00000018 080484a0 080484a0 000004a0 2**2 CONTENTS, ALLOC, LOAD, READONLY, CODE 10 .plt 00000080 080484b8 080484b8 000004b8 2**2 CONTENTS, ALLOC, LOAD, READONLY, CODE 11 .text 000001e4 08048540 08048540 00000540 2**4 CONTENTS, ALLOC, LOAD, READONLY, CODE 12 .fini 0000001e 08048724 08048724 00000724 2**2 CONTENTS, ALLOC, LOAD, READONLY, CODE 13 .rodata 00000014 08048744 08048744 00000744 2**2 CONTENTS, ALLOC, LOAD, READONLY, DATA 14 .eh_frame 000000b0 08048758 08048758 00000758 2**2 CONTENTS, ALLOC, LOAD, READONLY, DATA 15 .ctors 0000000c 08049808 08049808 00000808 2**2 CONTENTS, ALLOC, LOAD, DATA 16 .dtors 0000000c 08049814 08049814 00000814 2**2 CONTENTS, ALLOC, LOAD, DATA 17 .jcr 00000004 08049820 08049820 00000820 2**2 CONTENTS, ALLOC, LOAD, DATA 18 .dynamic 000000e0 08049824 08049824 00000824 2**2 CONTENTS, ALLOC, LOAD, DATA 19 .got 00000004 08049904 08049904 00000904 2**2 CONTENTS, ALLOC, LOAD, DATA 20 .got.plt 00000028 08049908 08049908 00000908 2**2 CONTENTS, ALLOC, LOAD, DATA 21 .data 0000000c 08049930 08049930 00000930 2**2 CONTENTS, ALLOC, LOAD, DATA 22 .bss 000000b0 0804993c 0804993c 0000093c 2**3 ALLOC 23 .stab 000007a4 00000000 00000000 0000093c 2**2 CONTENTS, READONLY, DEBUGGING 24 .stabstr 00001985 00000000 00000000 000010e0 2**0 CONTENTS, READONLY, DEBUGGING 25 .comment 000000e7 00000000 00000000 00002a65 2**0 CONTENTS, READONLY 26 .note 0000003c 00000000 00000000 00002b4c 2**0 CONTENTS, READONLY Dirk-Jan bje at sources dot redhat dot com wrote: > ------- Additional Comments From bje at sources dot redhat dot com > 2006-04-07 00:36 ------- > You should not be seeing a .stabs section in an x86 Linux binary, either. > Can you please attach some example binaries to this bug report? > -- "CONFIDENTIALITY NOTICE: This e-mail may contain information that is confidential and proprietary to Magma, and Magma hereby designates the information in this e-mail as confidential. The information is intended only for the use of the individual or entity named above. If you are not the intended recipient, you are hereby notified that any disclosure, copying, distribution or use of any of the information contained in this transmission is strictly prohibited and that you should immediately destroy this e-mail and its contents and notify Magma." ------- Additional Comments From dirkjan at magma-da dot com 2006-04-07 06:24 ------- Created an attachment (id=958) --> (http://sourceware.org/bugzilla/attachment.cgi?id=958&action=view) -- http://sourceware.org/bugzilla/show_bug.cgi?id=2335 ------- You are receiving this mail because: ------- You are on the CC list for the bug, or are watching someone who is. _______________________________________________ bug-binutils mailing list bug-binutils@gnu.org http://lists.gnu.org/mailman/listinfo/bug-binutils