This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/41868] cell microcode instruction (addic.) is generated for a trivial loop with -O2 optimizations, hurting performance badly
- From: "pinskia at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 2 Nov 2009 17:08:54 -0000
- Subject: [Bug target/41868] cell microcode instruction (addic.) is generated for a trivial loop with -O2 optimizations, hurting performance badly
- References: <bug-41868-14457@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #5 from pinskia at gcc dot gnu dot org 2009-11-02 17:08 -------
In fact doing the following diff to the -Os assembly:
--- t5.Os.s 2009-11-02 23:18:52.000000000 +0900
+++ t5.Os.dot.s 2009-11-02 23:20:19.000000000 +0900
@@ -29,9 +29,9 @@ x:
.L4:
bl y
.L3:
- cmpwi 7,31,0
- addi 31,31,-1
- bne 7,.L4
+# cmpwi 7,31,0
+ addic. 31,31,-1
+ bne .L4
addi 11,1,16
b _restgpr_31_x
.size x,.-x
produces the same result as -Os on the trunk.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41868