os_kernel_lab/related_info/ostep/ostep11-threadintro/wait-for-me.s

14 lines
166 B
ArmAsm
Raw Normal View History

2015-03-15 16:54:19 +08:00
.main
test $1, %ax # ax should be 1 (signaller) or 0 (waiter)
je .signaller
.waiter
mov 2000, %cx
test $1, %cx
jne .waiter
halt
.signaller
mov $1, 2000
halt