re PR testsuite/35677 (Intermitent failure "FAIL: libgomp.fortran/crayptr2.f90")
PR testsuite/35677 * emutls.c (__emutls_get_address): Make sure offset is really zero before initializing the object's offset. From-SVN: r142687
This commit is contained in:
parent
150da9f453
commit
b6b561e4c2
2 changed files with 12 additions and 2 deletions
|
@ -1,3 +1,9 @@
|
|||
2008-12-11 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
|
||||
|
||||
PR testsuite/35677
|
||||
* emutls.c (__emutls_get_address): Make sure offset is really zero
|
||||
before initializing the object's offset.
|
||||
|
||||
2008-12-11 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR c++/38253
|
||||
|
|
|
@ -147,8 +147,12 @@ __emutls_get_address (struct __emutls_object *obj)
|
|||
static __gthread_once_t once = __GTHREAD_ONCE_INIT;
|
||||
__gthread_once (&once, emutls_init);
|
||||
__gthread_mutex_lock (&emutls_mutex);
|
||||
offset = ++emutls_size;
|
||||
obj->loc.offset = offset;
|
||||
offset = obj->loc.offset;
|
||||
if (offset == 0)
|
||||
{
|
||||
offset = ++emutls_size;
|
||||
obj->loc.offset = offset;
|
||||
}
|
||||
__gthread_mutex_unlock (&emutls_mutex);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue