@@ -256,7 +256,7 @@ cfg_if::cfg_if! {
256256}
257257
258258pub unsafe fn panic ( data : Box < dyn Any + Send > ) -> u32 {
259- use core:: intrinsics:: atomic_store ;
259+ use core:: intrinsics:: atomic_store_seqcst ;
260260
261261 // _CxxThrowException executes entirely on this stack frame, so there's no
262262 // need to otherwise transfer `data` to the heap. We just pass a stack
@@ -288,20 +288,23 @@ pub unsafe fn panic(data: Box<dyn Any + Send>) -> u32 {
288288 //
289289 // In any case, we basically need to do something like this until we can
290290 // express more operations in statics (and we may never be able to).
291- atomic_store ( & mut THROW_INFO . pmfnUnwind as * mut _ as * mut u32 , ptr ! ( exception_cleanup) as u32 ) ;
292- atomic_store (
291+ atomic_store_seqcst (
292+ & mut THROW_INFO . pmfnUnwind as * mut _ as * mut u32 ,
293+ ptr ! ( exception_cleanup) as u32 ,
294+ ) ;
295+ atomic_store_seqcst (
293296 & mut THROW_INFO . pCatchableTypeArray as * mut _ as * mut u32 ,
294297 ptr ! ( & CATCHABLE_TYPE_ARRAY as * const _) as u32 ,
295298 ) ;
296- atomic_store (
299+ atomic_store_seqcst (
297300 & mut CATCHABLE_TYPE_ARRAY . arrayOfCatchableTypes [ 0 ] as * mut _ as * mut u32 ,
298301 ptr ! ( & CATCHABLE_TYPE as * const _) as u32 ,
299302 ) ;
300- atomic_store (
303+ atomic_store_seqcst (
301304 & mut CATCHABLE_TYPE . pType as * mut _ as * mut u32 ,
302305 ptr ! ( & TYPE_DESCRIPTOR as * const _) as u32 ,
303306 ) ;
304- atomic_store (
307+ atomic_store_seqcst (
305308 & mut CATCHABLE_TYPE . copyFunction as * mut _ as * mut u32 ,
306309 ptr ! ( exception_copy) as u32 ,
307310 ) ;
0 commit comments