diff options
author | rsc <devnull@localhost> | 2005-08-22 16:56:28 +0000 |
---|---|---|
committer | rsc <devnull@localhost> | 2005-08-22 16:56:28 +0000 |
commit | 9f7a3e020e851a217790be84c177f0e8a4347d9b (patch) | |
tree | c5f0e9a0dc0350f64d853f22e90bed1635d9935a | |
parent | ad9e684811638b69d3800b011ee5fafb448992a3 (diff) | |
download | plan9port-9f7a3e020e851a217790be84c177f0e8a4347d9b.tar.gz plan9port-9f7a3e020e851a217790be84c177f0e8a4347d9b.tar.bz2 plan9port-9f7a3e020e851a217790be84c177f0e8a4347d9b.zip |
new
-rw-r--r-- | src/libthread/Linux-power-asm.s | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/libthread/Linux-power-asm.s b/src/libthread/Linux-power-asm.s new file mode 100644 index 00000000..d6e21c15 --- /dev/null +++ b/src/libthread/Linux-power-asm.s @@ -0,0 +1,16 @@ + .globl _tas +_tas: + li %r0, 0 + mr %r4, %r3 + lis %r5, 0xcafe + ori %r5, %r5, 0xbabe +1: + lwarx %r3, %r0, %r4 + cmpwi %r3, 0 + bne 2f + stwcx. %r5, %r0, %r4 + bne- 1b +2: + sync + blr + |