This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/31396] Inline code performance much worse than out-of-line
- From: "jamagallon at ono dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 29 Mar 2007 22:17:31 -0000
- Subject: [Bug c/31396] Inline code performance much worse than out-of-line
- References: <bug-31396-14334@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- 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