finstrument-functions dual instrumentation problem

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,
Thank you in advance for your help. This is my first time using the mailing
list. Please notify me if this is not the proper place for these types of
questions.

I am working with gcc and the ?finstrument-functions option. I have been
trying to instrument both kerbose ftp and putty sfpt. I have noticed an
unusual event. It seems that gcc is instrumenting the function entry and
exit twice.  Has anyone experienced this? Any ideas on what might be causing
this?

Here is the results of objdump on main.o after a compile with
?finstrument-functions. Notice that a call to
?__cyg_profile_func_enter+0xfffffffffffffffc? happens twice in the code. 

0000000000000000 <makeargv>:
   0:         55                           push   %rbp
   1:         bf 00 00 00 00                     mov    $0x0,%edi
                                                2:
R_X86_64_32                makeargv
   6:         bd 00 00 00 00                    mov    $0x0,%ebp
                                                7:
R_X86_64_32                margv
   b:         53                           push   %rbx
   c:          48 83 ec 08                          sub    $0x8,%rsp
  10:        48 8b 74 24 18                    mov    0x18(%rsp),%rsi
  15:        e8 00 00 00 00                    callq  1a <makeargv+0x1a>
                                                16: R_X86_64_PC32       
__cyg_profile_func_enter+0xfffffffffffffffc
  1a:        c7 05 00 00 00 00 00          movl   $0x0,0(%rip)        # 24
<makeargv+0x24>
  21:        00 00 00 
                                                1c: R_X86_64_PC32        
margc+0xfffffffffffffff8
  24:        48 c7 05 00 00 00 00          movq   $0x0,0(%rip)        # 2f
<makeargv+0x2f>
  2b:        00 00 00 00 
                                                27: R_X86_64_PC32       
stringbase+0xfffffffffffffff8
                                                2b: R_X86_64_32S          
line
  2f:         48 c7 05 00 00 00 00          movq   $0x0,0(%rip)        # 3a
<makeargv+0x3a>
  36:        00 00 00 00 
                                                32: R_X86_64_PC32       
argbase+0xfffffffffffffff8
                                                36: R_X86_64_32S          
argbuf
  3a:        c7 05 00 00 00 00 00          movl   $0x0,0(%rip)        # 44
<makeargv+0x44>
  41:        00 00 00 
                                                3c: R_X86_64_PC32        
slrflag+0xfffffffffffffff8
  44:        48 8b 74 24 18                    mov    0x18(%rsp),%rsi
  49:        bf 00 00 00 00                     mov    $0x0,%edi
                                                4a: R_X86_64_32             
makeargv
  4e:        e8 00 00 00 00                    callq  53 <makeargv+0x53>
                                                4f: R_X86_64_PC32        
__cyg_profile_func_enter+0xfffffffffffffffc
  53:        48 8b 0d 00 00 00 00         mov    0(%rip),%rcx        # 5a
<makeargv+0x5a>
                                                56: R_X86_64_PC32       
stringbase+0xfffffffffffffffc
  5a:        48 8b 1d 00 00 00 00         mov    0(%rip),%rbx        # 61
<makeargv+0x61>
                                                5d: R_X86_64_PC32       
argbase+0xfffffffffffffffc
  61:        0f b6 11                movzbl (%rcx),%edx
  64:        80 fa 21                 cmp    $0x21,%dl
  67:        74 49                      je     b2 <makeargv+0xb2>
  69:        80 fa 24                 cmp    $0x24,%dl
  6c:        74 44                      je     b2 <makeargv+0xb2>


Dale Reese
Computer Measurnment Laboratory




[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux