if (profile && _dl_name_match_p (GLRO(dl_profile), map))
if (profile && GLRO(dl_profile) != NULL && _dl_name_match_p (GLRO(dl_profile), map))
elf_machine_runtime_setup (struct link_map *map, int lazy, int profile){  if (map->l_info[DT_JMPREL])    {      Elf64_Word i;      Elf64_Word *glink = NULL;      Elf64_Xword *plt = (Elf64_Xword *) D_PTR (map, l_info[DT_PLTGOT]);      Elf64_Word num_plt_entries = (map->l_info[DT_PLTRELSZ]->d_un.d_val				    / sizeof (Elf64_Rela));      Elf64_Addr l_addr = map->l_addr;      Elf64_Dyn **info = map->l_info;      char *p;      extern void _dl_runtime_resolve (void);      extern void _dl_profile_resolve (void);      /* Relocate the DT_PPC64_GLINK entry in the _DYNAMIC section.	 elf_get_dynamic_info takes care of the standard entries but	 doesn't know exactly what to do with processor specific	 entires.  */      if (info[DT_PPC64(GLINK)] != NULL)	info[DT_PPC64(GLINK)]->d_un.d_ptr += l_addr;      if (lazy)	{	  /* The function descriptor of the appropriate trampline	     routine is used to set the 1st and 2nd doubleword of the	     plt_reserve.  */	  Elf64_FuncDesc *resolve_fd;	  Elf64_Word glink_offset;	  /* the plt_reserve area is the 1st 3 doublewords of the PLT */	  Elf64_FuncDesc *plt_reserve = (Elf64_FuncDesc *) plt;	  Elf64_Word offset;	  resolve_fd = (Elf64_FuncDesc *) (profile ? _dl_profile_resolve					   : _dl_runtime_resolve);	  if (profile && _dl_name_match_p (GLRO(dl_profile), map))	    /* This is the object we are looking for.  Say that we really	       want profiling and the timers are started.  */	    GL(dl_profile_map) = map;	  /* We need to stuff the address/TOC of _dl_runtime_resolve	     into doublewords 0 and 1 of plt_reserve.  Then we need to	     stuff the map address into doubleword 2 of plt_reserve.	     This allows the GLINK0 code to transfer control to the	     correct trampoline which will transfer control to fixup	     in dl-machine.c.  */	  plt_reserve->fd_func = resolve_fd->fd_func;	  plt_reserve->fd_toc  = resolve_fd->fd_toc;	  plt_reserve->fd_aux  = (Elf64_Addr) map;#ifdef RTLD_BOOTSTRAP	  /* When we're bootstrapping, the opd entry will not have	     been relocated yet.  */	  plt_reserve->fd_func += l_addr;	  plt_reserve->fd_toc  += l_addr;#endif	  /* Set up the lazy PLT entries.  */	  glink = (Elf64_Word *) D_PTR (map, l_info[DT_PPC64(GLINK)]);	  offset = PLT_INITIAL_ENTRY_WORDS;	  glink_offset = GLINK_INITIAL_ENTRY_WORDS;	  for (i = 0; i < num_plt_entries; i++)	    {	      plt[offset] = (Elf64_Xword) &glink[glink_offset];	      offset += 3;	      /* The first 32k entries of glink can set an index and		 branch using two instructions;  Past that point,		 glink uses three instructions.  */	      if (i < 0x8000)          	glink_offset += 2;	      else          	glink_offset += 3;	    }	  /* Now, we've modified data.  We need to write the changes from	     the data cache to a second-level unified cache, then make	     sure that stale data in the instruction cache is removed.	     (In a multiprocessor system, the effect is more complex.)	     Most of the PLT shouldn't be in the instruction cache, but	     there may be a little overlap at the start and the end.	     Assumes that dcbst and icbi apply to lines of 16 bytes or	     more.  Current known line sizes are 16, 32, and 128 bytes.  */	  for (p = (char *) plt; p < (char *) &plt[offset]; p += 16)	    PPC_DCBST (p);	  PPC_SYNC;	}    }  return lazy;}