[all-commits] [llvm/llvm-project] 6f5ce4: [lldb] Remove non address bits when looking up mem...

David Spickett via All-commits all-commits at lists.llvm.org
Wed Nov 3 04:10:54 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 6f5ce43b433706c3ae5c37022d6c0964b6bfadf8
      https://github.com/llvm/llvm-project/commit/6f5ce43b433706c3ae5c37022d6c0964b6bfadf8
  Author: David Spickett <david.spickett at linaro.org>
  Date:   2021-11-03 (Wed, 03 Nov 2021)

  Changed paths:
    M lldb/include/lldb/Target/Process.h
    M lldb/source/Plugins/Process/Windows/Common/ProcessDebugger.cpp
    M lldb/source/Plugins/Process/Windows/Common/ProcessDebugger.h
    M lldb/source/Plugins/Process/Windows/Common/ProcessWindows.cpp
    M lldb/source/Plugins/Process/Windows/Common/ProcessWindows.h
    M lldb/source/Plugins/Process/elf-core/ProcessElfCore.cpp
    M lldb/source/Plugins/Process/elf-core/ProcessElfCore.h
    M lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
    M lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.h
    M lldb/source/Plugins/Process/mach-core/ProcessMachCore.cpp
    M lldb/source/Plugins/Process/mach-core/ProcessMachCore.h
    M lldb/source/Plugins/Process/minidump/ProcessMinidump.cpp
    M lldb/source/Plugins/Process/minidump/ProcessMinidump.h
    M lldb/source/Plugins/Process/scripted/ScriptedProcess.cpp
    M lldb/source/Plugins/Process/scripted/ScriptedProcess.h
    M lldb/source/Target/Process.cpp
    A lldb/test/API/linux/aarch64/tagged_memory_region/Makefile
    A lldb/test/API/linux/aarch64/tagged_memory_region/TestAArch64LinuxTaggedMemoryRegion.py
    A lldb/test/API/linux/aarch64/tagged_memory_region/main.c

  Log Message:
  -----------
  [lldb] Remove non address bits when looking up memory regions

On AArch64 we have various things using the non address bits
of pointers. This means when you lookup their containing region
you won't find it if you don't remove them.

This changes Process GetMemoryRegionInfo to a non virtual method
that uses the current ABI plugin to remove those bits. Then it
calls DoGetMemoryRegionInfo.

That function does the actual work and is virtual to be overriden
by Process implementations.

A test case is added that runs on AArch64 Linux using the top
byte ignore feature.

Reviewed By: omjavaid

Differential Revision: https://reviews.llvm.org/D102757




More information about the All-commits mailing list