Skip to content

Commit 17055ab

Browse files
Merge conflict resolution
1 parent 178b69a commit 17055ab

File tree

1 file changed

+0
-53
lines changed

1 file changed

+0
-53
lines changed

lldb/source/Plugins/DynamicLoader/AIX-DYLD/DynamicLoaderAIXDYLD.cpp

Lines changed: 0 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -350,59 +350,6 @@ void DynamicLoaderAIXDYLD::FillCoreLoader32Data(lldb_private::DataExtractor &dat
350350
free(buffer);
351351
}
352352

353-
void DynamicLoaderAIXDYLD::FillCoreLoader32Data(lldb_private::DataExtractor &data,
354-
uint64_t loader_offset, uint64_t loader_size ) {
355-
356-
Log *log = GetLog(LLDBLog::DynamicLoader);
357-
LLDB_LOGF(log, "DynamicLoaderAIXDYLD::%s()", __FUNCTION__);
358-
static char *buffer = (char *)malloc(loader_size);
359-
if (buffer == NULL) {
360-
LLDB_LOG(log, "Buffer allocation failed error: {0}", std::strerror(errno));
361-
return;
362-
}
363-
char *ptr = buffer, filename[PATH_MAX], membername[32];
364-
uint64_t dataorg, textorg, datasize, textsize, core_offset;
365-
int next = 1;
366-
lldb::offset_t base_offset = loader_offset;
367-
while (next != 0)
368-
{
369-
lldb::offset_t offset = base_offset;
370-
next = data.GetU32(&offset);
371-
core_offset = data.GetU32(&offset);
372-
textorg = data.GetU32(&offset);
373-
textsize = data.GetU32(&offset);
374-
dataorg = data.GetU32(&offset);
375-
datasize = data.GetU32(&offset);
376-
377-
size_t s1_index = 0, s2_index = 0;
378-
uint8_t byte;
379-
380-
while ((byte = data.GetU8(&offset)) != '\0') {
381-
filename[s1_index++] = static_cast<char>(byte);
382-
}
383-
filename[s1_index] = '\0';
384-
while ((byte = data.GetU8(&offset)) != '\0') {
385-
membername[s2_index++] = static_cast<char>(byte);
386-
}
387-
membername[s2_index] = '\0';
388-
base_offset += next;
389-
char pathWithMember[PATH_MAX] = {0};
390-
if (strlen(membername) > 0) {
391-
sprintf(pathWithMember, "%s(%s)", filename, membername);
392-
} else {
393-
sprintf(pathWithMember, "%s", filename);
394-
}
395-
396-
FileSpec file(pathWithMember);
397-
ModuleSpec module_spec(file, m_process->GetTarget().GetArchitecture());
398-
if (ModuleSP module_sp = m_process->GetTarget().GetOrCreateModule(module_spec, true /* notify */)) {
399-
UpdateLoadedSectionsByType(module_sp, LLDB_INVALID_ADDRESS, (lldb::addr_t)textorg, false, 1);
400-
UpdateLoadedSectionsByType(module_sp, LLDB_INVALID_ADDRESS, (lldb::addr_t)dataorg, false, 2);
401-
// FIXME: .tdata, .bss
402-
}
403-
}
404-
}
405-
406353
void DynamicLoaderAIXDYLD::DidAttach() {
407354
Log *log = GetLog(LLDBLog::DynamicLoader);
408355
LLDB_LOGF(log, "DynamicLoaderAIXDYLD::%s()", __FUNCTION__);

0 commit comments

Comments
 (0)