1 /* $Id: bitops.S,v 1.3 2001/11/18 00:12:56 davem Exp $
2 * bitops.S: Sparc64 atomic bit operations.
4 * Copyright (C) 2000 David S. Miller (davem@redhat.com)
11 .globl ___test_and_set_bit
12 .type ___test_and_set_bit,#function
13 ___test_and_set_bit: /* %o0=nr, %o1=addr */
21 1: andcc %g7, %g5, %o0
29 membar #StoreLoad | #StoreStore
30 .size ___test_and_set_bit, .-___test_and_set_bit
32 .globl ___test_and_clear_bit
33 .type ___test_and_clear_bit,#function
34 ___test_and_clear_bit: /* %o0=nr, %o1=addr */
42 1: andcc %g7, %g5, %o0
50 membar #StoreLoad | #StoreStore
51 .size ___test_and_clear_bit, .-___test_and_clear_bit
53 .globl ___test_and_change_bit
54 .type ___test_and_change_bit,#function
55 ___test_and_change_bit: /* %o0=nr, %o1=addr */
70 membar #StoreLoad | #StoreStore
72 .size ___test_and_change_bit, .-___test_and_change_bit