Bagikan melalui


Floating-Point Intrinsics Using Streaming SIMD Extensions 2 Instructions

Microsoft Specific

The following topics list the floating-point and integer intrinsics broken into groups by the nature of the operation. Each intrinsic entry has an informal pseudo-code, and it is followed with a corresponding instruction name in uppercase letters; for example, ADDSD is the name of the first instruction listed in this section. The variable r is generally used for the intrinsic's return value. A number appended to a variable name indicates the element of a packed object. For example, r0 is the lowest double of r. Some intrinsics are composites because they require more than one instruction to implement them. For more details, refer to the Streaming SIMD Extensions 2 (SSE2) instructions external architecture specification (EAS). You should be familiar with the hardware features provided by the SSE2 instructions when writing programs with the intrinsics. The following are three important issues to keep in mind:

  • Certain intrinsics, such as _mm_loadr_pd and _mm_cmpgt_sd, are not directly supported by the instruction set. While these intrinsics are convenient programming aids, be mindful of their implementation cost.

  • Data loaded or stored as __m128d objects must be generally 16-byte aligned.

  • Some intrinsics require that their argument be immediates, that is, constant integers (literals), because of the nature of the instruction.

This section contains the following topics:

See Also

Reference

Streaming SIMD Extensions 2 Instructions