Why would introducing useless MOV instructions speed up a tight loop in x86_64 assembly?

Background: While optimizing some Pascal code with embedded assembly language, I noticed an unnecessary MOV instruction, and removed it. To my surprise, removing the un-necessary instruction caused my program to slow down. I found that adding arbitrary, useless MOV instructions increased performance even further. The effect is erratic, and changes based on execution order: the … Read more