This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC 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 c/31396] Inline code performance much worse than out-of-line



------- Comment #1 from jamagallon at ono dot com  2007-03-29 23:17 -------
Created an attachment (id=13298)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=13298&action=view)
testcase

Simple test case with a loop in main() and a call to a function.
Both just calculate the sum of all elements on a vector.
The code in main() is muuch slower that the function.
If the function is inlined (-DINLINE), it becomes equally slower.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31396


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