FCMOV

FCMOV

FCMOV is a floating point conditional move opcode of the Intel x86 architecture, first introduced in Pentium Pro processors. It copies the contents of one of the floating point stack register, depending on the contents of EFLAGS integer flag register, to the ST(0) (top of stack) register. There are 8 variants of the instruction, differing by the condition codes that need be set for the instruction to perform the move.

Similarly to the CMOV instruction, FCMOV allows to perform some conditional operations without the usual branching overhead."Intel® Architecture Software Developer Manual, Volume 2: Instruction Set Reference." Available for download at [http://www.intel.com/design/intarch/manuals/243191.htm] ] However, it has a higher latency than conditional branch instructions.Fog, A: "Optimizing subroutines in assembly language. An optimization guide for x86 platforms." Available for download at [http://www.agner.org/optimize/] ] Therefore, it is most useful for simple, but unpredictable comparison or conditional operations, where it can provide substantial performance gains.

The instruction is usually used with the FCOMI instruction or the FCOM-FSTSW-SAHF idiom to set the relevant conditions codes based on the result of a floating point comparison.

Variants

This table shows the variants of the FCMOV instructions. In the Opcode column, i denotes the number of the floating point stack register used as the second operand (the first is always the ST(o) register - the top of the stack). Add it to the given number to obtain the corresponding opcode.

References

External links

* [http://www.x86.org/secrets/opcodes/fcmov.htm Free Dr. Dobb's Microprocessor Resources]
* [http://www.agner.org/optimize/ Software Optimization Resources]
* [http://www.intel.com/design/intarch/manuals/243191.htm Intel's official instruction set reference download page]


Wikimedia Foundation. 2010.

Игры ⚽ Поможем решить контрольную работу

Look at other dictionaries:

  • X86 instruction listings — The x86 instruction set has undergone numerous changes over time. Most of them were to add new functionality to the instruction set.x86 integer instructionsThis is the full 8086/8088 instruction set, but most, if not all of these instructions are …   Wikipedia

  • CPUID — The CPUID opcode is a processor supplementary instruction (its name derived from CPU IDentification) for the x86 architecture. It was introduced by Intel in 1993 when it introduced the Pentium and SL Enhanced 486 processors.[1] By using the CPUID …   Wikipedia

  • Расширения архитектуры x86 — (x86 extended features)  инженерные решения, разрабатываемые различными производителями микропроцессоров архитектуры x86 для собственных процессоров, которые, зачастую, присутствуют в одних моделях, и отсутствуют в других. Разработчики… …   Википедия

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”