Andy McFadden
b1c9cc2f2d
Add memory barriers to pthread_once.
...
The implementation was using a double-checked locking approach that
could break on SMP.
In addition to the barriers I also switched to a volatile pointer. I
don't think this will matter unless gcc can conclude that _normal_lock
can't affect *once_control, but I figured it was better to be safe.
(It seems to have no impact whatsoever on the generated code.)
Bug 3022795.
Change-Id: Ib91da25d57ff5bee4288526e39d457153ef6aacd
2010-09-23 12:30:12 -07:00
..
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00
2010-01-25 11:18:30 -08:00
2010-06-27 20:53:04 -07:00
2010-06-22 17:51:41 -07:00
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00
2009-11-18 10:36:25 -08:00
2009-11-18 10:36:25 -08:00
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00
2010-01-15 15:57:02 -08:00
2010-01-15 16:52:35 -08:00
2010-07-23 13:53:19 -07:00
2010-06-22 17:51:41 -07:00
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00
2010-06-27 20:53:04 -07:00
2009-07-18 01:11:10 +02:00
2010-06-27 20:53:04 -07:00
2009-11-18 10:36:25 -08:00
2010-06-11 13:49:09 -07:00
2010-08-09 13:43:46 -07:00
2010-02-16 11:43:18 -08:00
2010-05-03 15:33:05 -07:00
2010-02-16 11:43:18 -08:00
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00
2010-07-23 13:10:16 -07:00
2010-07-23 13:10:16 -07:00
2010-05-19 14:53:18 -07:00
2009-03-03 19:28:35 -08:00
2010-09-23 12:30:12 -07:00
2009-03-03 19:28:35 -08:00
2010-02-05 16:05:52 -02:00
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00
2010-07-02 15:09:57 -07:00
2009-03-03 19:28:35 -08:00
2010-02-05 17:48:07 -02:00
2010-02-12 11:35:38 -08:00
2010-06-22 17:51:41 -07:00
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00
2009-03-03 19:28:35 -08:00