Microarchitectural zeroing of a register via the register renamer: performance versus a mov?

前端 未结 3 1082
慢半拍i
慢半拍i 2021-02-05 14:23

I read on a blog post that recent X86 microarchitectures are also able to handle common register zeroing idioms (such as xor-ing a register with itself) in the register renamer;

3条回答
  •  粉色の甜心
    2021-02-05 14:27

    In addition to no latency, another benefit to zero idioms is that on modern Intel microarchitectures, the renaming, move elimination and zero idiom stage happens before even the scheduling of uops. Consequently, while a zero move idiom exists as a uop, it doesn't compete for execution ports allowing more ILP.

    Since zero idioms are detected and removed by the renamer, they have no execution latency.

提交回复
热议问题