The _AcquireSpinLockCount intrinsic has the following declaration:
int _AcquireSpinLockCount(long *, int);
This intrinsic function is used to acquire the longword-aligned spinlock pointed to by the first argument. Unlike _AcquireSpinLock, this intrinsic will limit the number of times it will try to acquire the spinlock; the value is specified by the second argument. The return value of this intrinsic is 1 if the spinlock was successfully acquired or 0 if the spinlock was not acquired before the retry count was exceeded. This intrinsic contains required memory barriers.