This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/34027] [4.3 regression] -Os code size nearly doubled
- From: "rguenth at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 12 Nov 2007 15:01:15 -0000
- Subject: [Bug tree-optimization/34027] [4.3 regression] -Os code size nearly doubled
- References: <bug-34027-9876@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #10 from rguenth at gcc dot gnu dot org 2007-11-12 15:01 -------
of course in the -O2 case I forgot to paste the rest of the fn in, here it is:
.p2align 4,,7
.p2align 3
.L5:
addl $-1000000000, %eax
adcl $-1, %edx
movl $1000000000, 8(%esp)
movl $0, 12(%esp)
movl %eax, (%esp)
movl %edx, 4(%esp)
call __umoddi3
leave
ret
so unfortunately the expanders don't deal with modulus the same way as with
the div/mul sequence.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34027