[PATCH] PR 38201: -mfma/-mavx and -msse5/-msse4a don't work together

Michael Meissner meissner@linux.vnet.ibm.com
Wed Dec 10 20:07:00 GMT 2008

On Tue, Dec 09, 2008 at 06:01:20PM -0800, H.J. Lu wrote:
> Mixing SSE4 with SSE5 are different from choosing between Intel FMA and
> SSE5.

It is similar to choosing to use an INC or an ADD $1 instruction to add by
one.  If a machine supports both instructions, it will produce the same result
no matter which instruction is generated.  When you use -mfma -msse5 you
promise that the machine has both instructions.  Obviously in a combo machine,
there may be a favored instruction sequence, but this is similar to choosing
INC vs. ADD $1 on a micro-level, and sooner or later an appropriate -mtune=
target will be generated.  However, the correct code will be generated.

Michael Meissner, IBM
4 Technology Place Drive, MS 2203A, Westford, MA, 01886, USA

More information about the Gcc-patches mailing list