~vcs-imports/eglibc/trunk

« back to all changes in this revision

Viewing changes to libc/nptl/allocatestack.c

  • Committer: joseph
  • Date: 2014-01-22 02:56:41 UTC
  • Revision ID: svn-v4:7b3dc134-2b1b-0410-93df-9e9f96275f8d:trunk:25088
Merge changes between r24941 and r25087 from /fsf/trunk.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1173
1173
#  error "Either TLS_TCB_AT_TP or TLS_DTV_AT_TP must be defined"
1174
1174
# endif
1175
1175
 
1176
 
  /* Fill in the DTV slot so that a later LD/GD access will find it.  */
1177
 
  dtv[map->l_tls_modid].pointer.val = dest;
1178
 
  dtv[map->l_tls_modid].pointer.is_static = true;
1179
 
 
1180
1176
  /* Initialize the memory.  */
1181
1177
  memset (__mempcpy (dest, map->l_tls_initimage, map->l_tls_initimage_size),
1182
1178
          '\0', map->l_tls_blocksize - map->l_tls_initimage_size);
 
1179
 
 
1180
  /* Fill in the DTV slot so that a later LD/GD access will find it.  */
 
1181
  dtv[map->l_tls_modid].pointer.is_static = true;
 
1182
  /* Pairs against the read barrier in tls_get_attr_tail, guaranteeing
 
1183
     any thread waiting for an update to pointer.val sees the
 
1184
     initimage write.  */
 
1185
  atomic_write_barrier ();
 
1186
  dtv[map->l_tls_modid].pointer.val = dest;
 
1187
 
1183
1188
}
1184
1189
 
1185
1190
void