# Program to test retired instructions used by rep prefixed instructions # by Vince Weaver - vince _at_ csl.cornell.edu # # Compile with the following: # as -o rep_test.o rep_test.s ; ld -o rep_test rep_test.o # # .text .globl _start _start: mov $1,%edx # Change this to change # of loops loop: mov $4096,%ecx # Change this to change rep count mov $data,%esi rep lodsb dec %edx jnz loop exit: xor %ebx,%ebx # Call the Linux exit syscall xor %eax,%eax inc %eax int $0x80 .bss .align 4096 # align to beginning of page # 32MB, raise this if you want .lcomm data, 33554432 # more