Skip to content

Instantly share code, notes, and snippets.

@Kijewski
Created March 4, 2012 09:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Kijewski/1971767 to your computer and use it in GitHub Desktop.
Save Kijewski/1971767 to your computer and use it in GitHub Desktop.
an expensive, pipeline hostile nop
.global reg_nop
.macro round
xor %eax, %ebx
xor %ebx, %ecx
xor %ecx, %edx
xor %edx, %eax
.endm
.macro reg_rol
round
round
round
round
xor %edx, %eax
.endm
.macro reg_nop
reg_rol
reg_rol
reg_rol
reg_rol
.endm
reg_nop:
reg_nop
ret
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment