http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51835
Mikael Pettersson <mikpe at it dot uu.se> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |mikpe at it dot uu.se --- Comment #5 from Mikael Pettersson <mikpe at it dot uu.se> 2012-02-05 14:07:49 UTC --- (In reply to comment #2) > This is only applicable to the 4.6 branch and trunk since support for the > Cortex M4 wasn't added till 4.6. > > cheers > Ramana Maybe the Cortex M4 wasn't added until 4.6, but the other options are permitted by 4.5 and I can easily get 4.5 to produce wrong-looking code. With -O2 -mfloat-abi=hard -mfpu=fpv4-sp-d16 -march=armv7-a -marm I see the following code generation difference between 4.5 and 4.6: @@ -22,8 +22,9 @@ @ frame_needed = 0, uses_anonymous_args = 0 stmfd sp!, {r3, lr} bl __aeabi_f2d + fmrrd r0, r1, d0 bl __aeabi_d2iz ldmfd sp!, {r3, pc} .size func, .-func - .ident "GCC: (GNU) 4.5.4 20120126 (prerelease)" + .ident "GCC: (GNU) 4.6.3 20120203 (prerelease)" .section .note.GNU-stack,"",%progbits Backporting r183734 from 4.6 to 4.5 makes 4.5 generate the same code as 4.6, i.e., with the fmrrd between the two calls.