File tree Expand file tree Collapse file tree 1 file changed +2
-3
lines changed
Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -249,7 +249,7 @@ impl<T> ArrayQueueMpsc<T> {
249249
250250 if tail_cached == head {
251251 if SPIN {
252- std :: hint:: spin_loop ( ) ;
252+ core :: hint:: spin_loop ( ) ;
253253 let tail = if _final_check {
254254 self . sender . load ( Ordering :: SeqCst ) as u32
255255 } else {
@@ -273,14 +273,13 @@ impl<T> ArrayQueueMpsc<T> {
273273 debug_assert ! ( index < self . buffer. len( ) ) ;
274274 let slot = unsafe { self . buffer . get_unchecked ( index) } ;
275275 // Wait for stamp update
276- let backoff = Backoff :: new ( ) ;
277276 let target_stamp = ( head as usize ) . wrapping_add ( 1 ) ;
278277 loop {
279278 let stamp = slot. stamp . load ( Ordering :: Acquire ) ;
280279 if stamp == target_stamp {
281280 break ;
282281 }
283- backoff . snooze ( ) ;
282+ core :: hint :: spin_loop ( ) ;
284283 }
285284 // Update head
286285 let new_head = if index + 1 < self . buffer . len ( ) {
You can’t perform that action at this time.
0 commit comments