diff --git a/lldb/source/Core/PluginManager.cpp b/lldb/source/Core/PluginManager.cpp --- a/lldb/source/Core/PluginManager.cpp +++ b/lldb/source/Core/PluginManager.cpp @@ -86,7 +86,7 @@ } template static FPtrTy CastToFPtr(void *VPtr) { - return reinterpret_cast(reinterpret_cast(VPtr)); + return reinterpret_cast(VPtr); } static FileSystem::EnumerateDirectoryResult diff --git a/lldb/source/Expression/IRExecutionUnit.cpp b/lldb/source/Expression/IRExecutionUnit.cpp --- a/lldb/source/Expression/IRExecutionUnit.cpp +++ b/lldb/source/Expression/IRExecutionUnit.cpp @@ -348,7 +348,7 @@ return; } m_jitted_functions.push_back(JittedFunction( - function.getName().str().c_str(), external, (lldb::addr_t)fun_ptr)); + function.getName().str().c_str(), external, reinterpret_cast(fun_ptr))); } CommitAllocations(process_sp); diff --git a/lldb/source/Expression/IRMemoryMap.cpp b/lldb/source/Expression/IRMemoryMap.cpp --- a/lldb/source/Expression/IRMemoryMap.cpp +++ b/lldb/source/Expression/IRMemoryMap.cpp @@ -328,9 +328,9 @@ case eAllocationPolicyMirror: process_sp = m_process_wp.lock(); LLDB_LOGF(log, - "IRMemoryMap::%s process_sp=0x%" PRIx64 + "IRMemoryMap::%s process_sp=0x%" PRIxPTR ", process_sp->CanJIT()=%s, process_sp->IsAlive()=%s", - __FUNCTION__, (lldb::addr_t)process_sp.get(), + __FUNCTION__, reinterpret_cast(process_sp.get()), process_sp && process_sp->CanJIT() ? "true" : "false", process_sp && process_sp->IsAlive() ? "true" : "false"); if (process_sp && process_sp->CanJIT() && process_sp->IsAlive()) { @@ -577,9 +577,9 @@ if (lldb_private::Log *log = lldb_private::GetLogIfAllCategoriesSet(LIBLLDB_LOG_EXPRESSIONS)) { LLDB_LOGF(log, - "IRMemoryMap::WriteMemory (0x%" PRIx64 ", 0x%" PRIx64 + "IRMemoryMap::WriteMemory (0x%" PRIx64 ", 0x%" PRIxPTR ", 0x%" PRId64 ") went to [0x%" PRIx64 "..0x%" PRIx64 ")", - (uint64_t)process_address, (uint64_t)bytes, (uint64_t)size, + (uint64_t)process_address, reinterpret_cast(bytes), (uint64_t)size, (uint64_t)allocation.m_process_start, (uint64_t)allocation.m_process_start + (uint64_t)allocation.m_size); @@ -708,9 +708,9 @@ if (lldb_private::Log *log = lldb_private::GetLogIfAllCategoriesSet(LIBLLDB_LOG_EXPRESSIONS)) { LLDB_LOGF(log, - "IRMemoryMap::ReadMemory (0x%" PRIx64 ", 0x%" PRIx64 + "IRMemoryMap::ReadMemory (0x%" PRIx64 ", 0x%" PRIxPTR ", 0x%" PRId64 ") came from [0x%" PRIx64 "..0x%" PRIx64 ")", - (uint64_t)process_address, (uint64_t)bytes, (uint64_t)size, + (uint64_t)process_address, reinterpret_cast(bytes), (uint64_t)size, (uint64_t)allocation.m_process_start, (uint64_t)allocation.m_process_start + (uint64_t)allocation.m_size); diff --git a/lldb/source/Host/common/HostInfoBase.cpp b/lldb/source/Host/common/HostInfoBase.cpp --- a/lldb/source/Host/common/HostInfoBase.cpp +++ b/lldb/source/Host/common/HostInfoBase.cpp @@ -246,8 +246,8 @@ // On other posix systems, we will get .../lib(64|32)?/liblldb.so. FileSpec lldb_file_spec(Host::GetModuleFileSpecForHostAddress( - reinterpret_cast(reinterpret_cast( - HostInfoBase::ComputeSharedLibraryDirectory)))); + reinterpret_cast( + HostInfoBase::ComputeSharedLibraryDirectory))); // This is necessary because when running the testsuite the shlib might be a // symbolic link inside the Python resource dir. diff --git a/lldb/source/Plugins/ExpressionParser/Clang/IRForTarget.cpp b/lldb/source/Plugins/ExpressionParser/Clang/IRForTarget.cpp --- a/lldb/source/Plugins/ExpressionParser/Clang/IRForTarget.cpp +++ b/lldb/source/Plugins/ExpressionParser/Clang/IRForTarget.cpp @@ -355,7 +355,7 @@ ConstantInt *new_constant_int = ConstantInt::get(llvm::Type::getInt64Ty(m_module->getContext()), - reinterpret_cast(result_decl), false); + reinterpret_cast(result_decl), false); llvm::Metadata *values[2]; values[0] = ConstantAsMetadata::get(new_result_global); diff --git a/lldb/source/Plugins/Process/POSIX/CrashReason.cpp b/lldb/source/Plugins/Process/POSIX/CrashReason.cpp --- a/lldb/source/Plugins/Process/POSIX/CrashReason.cpp +++ b/lldb/source/Plugins/Process/POSIX/CrashReason.cpp @@ -136,15 +136,15 @@ #if defined(si_lower) && defined(si_upper) if (reason == CrashReason::eBoundViolation) { str = "signal SIGSEGV"; - AppendBounds(str, reinterpret_cast(info.si_lower), - reinterpret_cast(info.si_upper), - reinterpret_cast(info.si_addr)); + AppendBounds(str, reinterpret_cast(info.si_lower), + reinterpret_cast(info.si_upper), + reinterpret_cast(info.si_addr)); return str; } #endif return GetCrashReasonString(reason, - reinterpret_cast(info.si_addr)); + reinterpret_cast(info.si_addr)); } std::string GetCrashReasonString(CrashReason reason, lldb::addr_t fault_addr) {