How can i use 'freorder-functions'?

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

 



Dear gcc members,


I'm Jungsoo Son

The reason that I send this mail to you is that I want to know how to use
'freorder-functions' using 'fprofile-arcs'.
I've tried several times but it was fail on my test. 
The function location was not reordered. Function location was same with 'no
freorder-fuctions'
Should I set attribute to each function as "__attribute__
((section(".text.hot)))" ? 

The following is my test sequence:
1. compile sample code with '-fprofile-arcs' (gcc -o sample sample.c ->
fprofile-arcs)
2. run sample program (./sample) 
  --> i got a file profiled sample.gcda 
3. recompile sample code with 'freorder-functions' (gcc -o sample sample.c
-> freorder-functions)
  --> I thought that the gcc use gcda when source files  are compiled. But
there is no difference from original binary (gcc -o sample sample.c)
 
Please let me know how to use '-freorder-functions'.
 
Regards,

Jungsoo





[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