@@ -134,13 +134,6 @@ pub struct AtomicUint {
134
134
priv nopod : marker:: NoPod
135
135
}
136
136
137
- /// An unsigned atomic integer type that is forced to be 64-bits. This does not
138
- /// support all operations.
139
- pub struct AtomicU64 {
140
- priv v: Unsafe < u64 > ,
141
- priv nopod : marker:: NoPod
142
- }
143
-
144
137
/// An unsafe atomic pointer. Only supports basic atomic operations
145
138
pub struct AtomicPtr < T > {
146
139
priv p: Unsafe < uint > ,
@@ -198,11 +191,6 @@ pub static INIT_ATOMIC_INT : AtomicInt = AtomicInt { v: Unsafe{value: 0,
198
191
pub static INIT_ATOMIC_UINT : AtomicUint = AtomicUint { v : Unsafe { value : 0 ,
199
192
marker1 : marker:: InvariantType } ,
200
193
nopod : marker:: NoPod } ;
201
- /// An `AtomicU64` initialized to `0`
202
- pub static INIT_ATOMIC_U64 : AtomicU64 = AtomicU64 { v : Unsafe { value : 0 ,
203
- marker1 : marker:: InvariantType } ,
204
- nopod : marker:: NoPod } ;
205
-
206
194
207
195
// NB: Needs to be -1 (0b11111111...) to make fetch_nand work correctly
208
196
static UINT_TRUE : uint = -1 ;
@@ -478,46 +466,6 @@ impl AtomicInt {
478
466
}
479
467
}
480
468
481
- // temporary workaround
482
- // it causes link failure on MIPS target
483
- // libgcc doesn't implement 64-bit atomic operations for MIPS32
484
- #[ cfg( not( target_arch = "mips" ) ) ]
485
- impl AtomicU64 {
486
- pub fn new ( v : u64 ) -> AtomicU64 {
487
- AtomicU64 { v : Unsafe :: new ( v) , nopod : marker:: NoPod }
488
- }
489
-
490
- #[ inline]
491
- pub fn load ( & self , order : Ordering ) -> u64 {
492
- unsafe { atomic_load ( self . v . get ( ) , order) }
493
- }
494
-
495
- #[ inline]
496
- pub fn store ( & self , val : u64 , order : Ordering ) {
497
- unsafe { atomic_store ( self . v . get ( ) , val, order) ; }
498
- }
499
-
500
- #[ inline]
501
- pub fn swap ( & self , val : u64 , order : Ordering ) -> u64 {
502
- unsafe { atomic_swap ( self . v . get ( ) , val, order) }
503
- }
504
-
505
- #[ inline]
506
- pub fn compare_and_swap ( & self , old : u64 , new : u64 , order : Ordering ) -> u64 {
507
- unsafe { atomic_compare_and_swap ( self . v . get ( ) , old, new, order) }
508
- }
509
-
510
- #[ inline]
511
- pub fn fetch_add ( & self , val : u64 , order : Ordering ) -> u64 {
512
- unsafe { atomic_add ( self . v . get ( ) , val, order) }
513
- }
514
-
515
- #[ inline]
516
- pub fn fetch_sub ( & self , val : u64 , order : Ordering ) -> u64 {
517
- unsafe { atomic_sub ( self . v . get ( ) , val, order) }
518
- }
519
- }
520
-
521
469
impl AtomicUint {
522
470
/// Create a new `AtomicUint`
523
471
pub fn new ( v : uint ) -> AtomicUint {
0 commit comments