Intel® ISA Extensions
Use hardware-based isolation and memory encryption to provide more code protection in your solutions.
This community is designed for sharing of public information. Please do not share Intel or third-party confidential information here.

Question on AVX Instruction set reference


If suppose there is a legacy 128 bit SIMD instrcution and the data is held in a 256 bit register. And if the entire 256 bit data is to be processed but since only a 128 bit SIMD is availabale, how can one:

1. run the instruction on the lower 128 bits
2. run the instruction on the upper 128 bits
3. shift the upper 128 bits to the lower 128 bit position


0 Kudos
1 Reply
Black Belt
Instructions prior to AVX don't touch the upper 128 bits. AVX instructions are available to copy the upper 128 bits to the lower 128, where an SSE instruction can operate. Following the SSE instruction, VZEROUPPER is required to clear the upper 128 bits to avoid ugly hardware timing dependencies in subsequent AVX instructions. Switching in and out of AVX normally occurs during function call/return; interprocedural optimizations aren't supported in this context, to my knowledge.