nitesh.jain added a comment.

The issue was observed while parsing "vdso module" for the core file. When the 
DynamicLoader::LoadModuleAtAddress is called to load "vdso" module. Since 
"vdso" doesn't match with any of the module in the target.GetImages(), the 
check_alternative_file_name becomes true. This cause MatchesModuleSpec to 
return true and application binary to reload again at vdso base 
address(AT_SYSINFO_EHDR) thus all load addresses of application elf's sections 
becomes incorrect. Please find attach log file.
DynamicLoader::LoadModuleAtAddress(...)
{

  ...
  ...
  ...
  if (check_alternative_file_name) {
          ...
          ...
          ...
          **FileSpec(memory_info.GetName().AsCString(), false),**  ** // 
memory_info.GetName().AsCString() is empty here**
          target.GetArchitecture());
  
      if ((module_sp = modules.FindFirstModule(new_module_spec))) {  // 
FindFirstModule returns application elf's module
        UpdateLoadedSections(module_sp, link_map_addr, base_addr, false); // 
load addresses of application elf's sections gets updated to vdso's address 
(which is incorrect)
        return module_sp;
      }

...
 ...
 ...
}


https://reviews.llvm.org/D30454



_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to