[Lldb-commits] [PATCH] D156817: _wsopen_s does not accept bits other than `_S_IREAD | _S_IWRITE`

2023-08-02 Thread David Spickett via Phabricator via lldb-commits
DavidSpickett added a comment.

I just commented on the issue, thanks for the fix!

What exactly are the other bits in the mode here, are we losing something 
important potentially? I guess it can't be that important if Windows rejects 
them.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156817/new/

https://reviews.llvm.org/D156817

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


[Lldb-commits] [PATCH] D156817: _wsopen_s does not accept bits other than `_S_IREAD | _S_IWRITE`

2023-08-02 Thread David Spickett via Phabricator via lldb-commits
DavidSpickett added a comment.

Also please put `[lldb][Windows]` at the start of the commit title.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156817/new/

https://reviews.llvm.org/D156817

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


[Lldb-commits] [PATCH] D156817: _wsopen_s does not accept bits other than `_S_IREAD | _S_IWRITE`

2023-08-02 Thread David Spickett via Phabricator via lldb-commits
DavidSpickett added inline comments.



Comment at: lldb/source/Host/windows/FileSystem.cpp:104
 return -1;
+  mode = mode & (_S_IREAD | _S_IWRITE); // All other bits are rejected by 
_wsopen_s
   int result;

Nitpick: comments are usually on the line before.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156817/new/

https://reviews.llvm.org/D156817

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


[Lldb-commits] [PATCH] D156774: [lldb] Parse enums while parsing a type

2023-08-02 Thread Michael Buch via Phabricator via lldb-commits
Michael137 added inline comments.



Comment at: lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp:3040
 
+case DW_TAG_enumeration_type:
+{

Michael137 wrote:
> Michael137 wrote:
> > At first glance this seems OK but I'll want to check why the type doesn't 
> > get resolved when `clang::Sema` asks LLDB for it by name
> Checking locally and will report back
Ok, so what happens for `expr Outer::Enum::var` is that LLDB will first resolve 
the `Outer` structure (and all its member fields, but not nested types). When 
clang looks for `Enum`, it wants to find it in a direct lookup into the `Outer` 
DeclContext. But that lookup will fail because we never created the decls for 
the nested type. There is no fallback to the external source in such a case 
unfortunately so LLDB never has the chance to correct this. See the 
`LookupQualifiedName` code path in `Sema::BuildCXXNestedNameSpecifier`.

So I think this proposed approach should be fine. But what I think could be 
better is if we just do the same for `DW_TAG_enumeration_type` and 
`DW_TAG_structure_type` as we do for `DW_TAG_subprogram`.

I.e., simply push back the type into `member_function_dies` (we should rename 
this) and then it will get resolved properly in `CompleteRecordType`.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156774/new/

https://reviews.llvm.org/D156774

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


[Lldb-commits] [PATCH] D156774: [lldb] Parse enums while parsing a type

2023-08-02 Thread Michael Buch via Phabricator via lldb-commits
Michael137 added a comment.

Could you update the commit message with a description of the failure and 
summary of the fix? And change the title to something like 
`[lldb][DWARFASTParserClang] Resolve nested types when parsing structures`


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156774/new/

https://reviews.llvm.org/D156774

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


[Lldb-commits] [PATCH] D156774: [lldb] Parse enums while parsing a type

2023-08-02 Thread Michael Buch via Phabricator via lldb-commits
Michael137 added inline comments.



Comment at: lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp:3040
 
+case DW_TAG_enumeration_type:
+{

Michael137 wrote:
> Michael137 wrote:
> > Michael137 wrote:
> > > At first glance this seems OK but I'll want to check why the type doesn't 
> > > get resolved when `clang::Sema` asks LLDB for it by name
> > Checking locally and will report back
> Ok, so what happens for `expr Outer::Enum::var` is that LLDB will first 
> resolve the `Outer` structure (and all its member fields, but not nested 
> types). When clang looks for `Enum`, it wants to find it in a direct lookup 
> into the `Outer` DeclContext. But that lookup will fail because we never 
> created the decls for the nested type. There is no fallback to the external 
> source in such a case unfortunately so LLDB never has the chance to correct 
> this. See the `LookupQualifiedName` code path in 
> `Sema::BuildCXXNestedNameSpecifier`.
> 
> So I think this proposed approach should be fine. But what I think could be 
> better is if we just do the same for `DW_TAG_enumeration_type` and 
> `DW_TAG_structure_type` as we do for `DW_TAG_subprogram`.
> 
> I.e., simply push back the type into `member_function_dies` (we should rename 
> this) and then it will get resolved properly in `CompleteRecordType`.
Also `DW_TAG_union_type` while you're here :)


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156774/new/

https://reviews.llvm.org/D156774

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


[Lldb-commits] [PATCH] D156774: [lldb] Parse enums while parsing a type

2023-08-02 Thread Vlad Serebrennikov via Phabricator via lldb-commits
Endill added inline comments.



Comment at: lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp:3040
 
+case DW_TAG_enumeration_type:
+{

Michael137 wrote:
> Michael137 wrote:
> > Michael137 wrote:
> > > Michael137 wrote:
> > > > At first glance this seems OK but I'll want to check why the type 
> > > > doesn't get resolved when `clang::Sema` asks LLDB for it by name
> > > Checking locally and will report back
> > Ok, so what happens for `expr Outer::Enum::var` is that LLDB will first 
> > resolve the `Outer` structure (and all its member fields, but not nested 
> > types). When clang looks for `Enum`, it wants to find it in a direct lookup 
> > into the `Outer` DeclContext. But that lookup will fail because we never 
> > created the decls for the nested type. There is no fallback to the external 
> > source in such a case unfortunately so LLDB never has the chance to correct 
> > this. See the `LookupQualifiedName` code path in 
> > `Sema::BuildCXXNestedNameSpecifier`.
> > 
> > So I think this proposed approach should be fine. But what I think could be 
> > better is if we just do the same for `DW_TAG_enumeration_type` and 
> > `DW_TAG_structure_type` as we do for `DW_TAG_subprogram`.
> > 
> > I.e., simply push back the type into `member_function_dies` (we should 
> > rename this) and then it will get resolved properly in `CompleteRecordType`.
> Also `DW_TAG_union_type` while you're here :)
I can look into doing things more lazily like `DW_TAG_subprogram`, if you can 
point me to code paths for this on LLDB side:
> When clang looks for Enum, it wants to find it in a direct lookup into the 
> Outer DeclContext. But that lookup will fail because we never created the 
> decls for the nested type. There is no fallback to the external source in 
> such a case unfortunately so LLDB never has the chance to correct this.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156774/new/

https://reviews.llvm.org/D156774

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


[Lldb-commits] [PATCH] D156774: [lldb][DWARFASTParserClang] Resolve nested types when parsing structures

2023-08-02 Thread Michael Buch via Phabricator via lldb-commits
Michael137 added inline comments.



Comment at: lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp:3040
 
+case DW_TAG_enumeration_type:
+{

Endill wrote:
> Michael137 wrote:
> > Michael137 wrote:
> > > Michael137 wrote:
> > > > Michael137 wrote:
> > > > > At first glance this seems OK but I'll want to check why the type 
> > > > > doesn't get resolved when `clang::Sema` asks LLDB for it by name
> > > > Checking locally and will report back
> > > Ok, so what happens for `expr Outer::Enum::var` is that LLDB will first 
> > > resolve the `Outer` structure (and all its member fields, but not nested 
> > > types). When clang looks for `Enum`, it wants to find it in a direct 
> > > lookup into the `Outer` DeclContext. But that lookup will fail because we 
> > > never created the decls for the nested type. There is no fallback to the 
> > > external source in such a case unfortunately so LLDB never has the chance 
> > > to correct this. See the `LookupQualifiedName` code path in 
> > > `Sema::BuildCXXNestedNameSpecifier`.
> > > 
> > > So I think this proposed approach should be fine. But what I think could 
> > > be better is if we just do the same for `DW_TAG_enumeration_type` and 
> > > `DW_TAG_structure_type` as we do for `DW_TAG_subprogram`.
> > > 
> > > I.e., simply push back the type into `member_function_dies` (we should 
> > > rename this) and then it will get resolved properly in 
> > > `CompleteRecordType`.
> > Also `DW_TAG_union_type` while you're here :)
> I can look into doing things more lazily like `DW_TAG_subprogram`, if you can 
> point me to code paths for this on LLDB side:
> > When clang looks for Enum, it wants to find it in a direct lookup into the 
> > Outer DeclContext. But that lookup will fail because we never created the 
> > decls for the nested type. There is no fallback to the external source in 
> > such a case unfortunately so LLDB never has the chance to correct this.
The `DW_TAG_subprogram` path is just above this one in the switch statement 
(line 3030). Search for `member_function_dies` in this file.

> if you can point me to code paths for this on LLDB side

Clang requests type completion by calling `FindExternalVisibleDeclsByName` 
(which LLDB implements). So if you break in that function you should be able to 
see what LLDB finds when it looks for the outer structure and the enum. But you 
don't necessarily need to do that. If we just fill up the 
`member_function_dies` vector with the nested enum/union/structure types like 
we do for `DW_TAG_subprogram` that is sufficient.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156774/new/

https://reviews.llvm.org/D156774

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


[Lldb-commits] [PATCH] D140630: [lldb-vscode] Add data breakpoint support

2023-08-02 Thread Callum Macmillan via Phabricator via lldb-commits
cimacmillan added a comment.

Ping

@clayborg would you mind having another look? Thanks


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D140630/new/

https://reviews.llvm.org/D140630

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


[Lldb-commits] [lldb] 54458c5 - [lldb][lldb-vscode] Skip disassembler test on Arm

2023-08-02 Thread David Spickett via lldb-commits

Author: David Spickett
Date: 2023-08-02T14:36:24Z
New Revision: 54458c525aa47219a3ef2bee2be33d6096b1585c

URL: 
https://github.com/llvm/llvm-project/commit/54458c525aa47219a3ef2bee2be33d6096b1585c
DIFF: 
https://github.com/llvm/llvm-project/commit/54458c525aa47219a3ef2bee2be33d6096b1585c.diff

LOG: [lldb][lldb-vscode] Skip disassembler test on Arm

This is failing and/or causing time outs (hard to tell which ) on
our Arm Linux bot:
https://lab.llvm.org/buildbot/#/builders/17/builds/41108

Added: 


Modified: 
lldb/test/API/tools/lldb-vscode/disassemble/TestVSCode_disassemble.py

Removed: 




diff  --git 
a/lldb/test/API/tools/lldb-vscode/disassemble/TestVSCode_disassemble.py 
b/lldb/test/API/tools/lldb-vscode/disassemble/TestVSCode_disassemble.py
index 6d3ebdf296e2b1..7f133afb6a22b4 100644
--- a/lldb/test/API/tools/lldb-vscode/disassemble/TestVSCode_disassemble.py
+++ b/lldb/test/API/tools/lldb-vscode/disassemble/TestVSCode_disassemble.py
@@ -14,6 +14,7 @@
 class TestVSCode_disassemble(lldbvscode_testcase.VSCodeTestCaseBase):
 @skipIfWindows
 @skipIfRemote
+@skipIf(archs=["arm"])
 def test_disassemble(self):
 """
 Tests the 'disassemble' request.



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


[Lldb-commits] [PATCH] D156493: [lldb-vsocde] Adding support for the "disassemble" request.

2023-08-02 Thread David Spickett via Phabricator via lldb-commits
DavidSpickett added a comment.

I've marked one of these tests skipped on Arm because it's failing on our bot: 
https://github.com/llvm/llvm-project/commit/54458c525aa47219a3ef2bee2be33d6096b1585c

This is a 32 Arm machine, so unless you've got ready access to one, we'll 
figure out what the problem is. Other tests in this change may also be failing, 
but I'll see what the bot thinks of this first skip.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156493/new/

https://reviews.llvm.org/D156493

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


[Lldb-commits] [PATCH] D140630: [lldb-vscode] Add data breakpoint support

2023-08-02 Thread walter erquinigo via Phabricator via lldb-commits
wallace added a comment.

Greg hasn't been working for a while. You can go ahead and land this, and when 
he gets back he can share some feedback.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D140630/new/

https://reviews.llvm.org/D140630

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


[Lldb-commits] [PATCH] D156493: [lldb-vsocde] Adding support for the "disassemble" request.

2023-08-02 Thread David Spickett via Phabricator via lldb-commits
DavidSpickett added a comment.

Also it would be very useful if the logs could be printed in a pretty form like:

  >>> from pprint import pprint
  >>> pprint(j)
  {u'body': {u'instructions': [{u'address': u'0x400584',
u'column': 9,
u'instruction': u'ldr r0, [sp, #0x4]',
u'instructionBytes': u'04 00 9d e5',
u'line': 12,
u'location': {u'name': u'main.c',
  u'path': 
u'/home/tcwg-buildbot/worker/lldb-arm-ubuntu/llvm-project/lldb/test/API/tools/lldb-vscode/disassemble/main.c'}},
   {u'address': u'0x400588',
u'column': 16,
u'instruction': u'ldr r1, [sp]',
u'instructionBytes': u'00 10 9d e5',
u'line': 12,
u'location': {u'name': u'main.c',
  u'path': 
u'/home/tcwg-buildbot/worker/lldb-arm-ubuntu/llvm-project/lldb/test/API/tools/lldb-vscode/disassemble/main.c'}},

Probably only want to do that when we've had a failure and not waste time 
otherwise, but it would be a lot more readable in the log file.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156493/new/

https://reviews.llvm.org/D156493

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


[Lldb-commits] [PATCH] D156493: [lldb-vsocde] Adding support for the "disassemble" request.

2023-08-02 Thread John Harrison via Phabricator via lldb-commits
ashgti added a comment.

Do you have any additional information about the failure? The link looks like a 
timeout, so I'm not sure where things are timing out.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156493/new/

https://reviews.llvm.org/D156493

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


[Lldb-commits] [lldb] 6c2e324 - [lldb] Re-add compile-time checks for SPI in HosInfoMacOSX

2023-08-02 Thread Alex Langford via lldb-commits

Author: Alex Langford
Date: 2023-08-02T10:21:54-07:00
New Revision: 6c2e3249160f5b68f6e09fed0435ee043659f2d9

URL: 
https://github.com/llvm/llvm-project/commit/6c2e3249160f5b68f6e09fed0435ee043659f2d9
DIFF: 
https://github.com/llvm/llvm-project/commit/6c2e3249160f5b68f6e09fed0435ee043659f2d9.diff

LOG: [lldb] Re-add compile-time checks for SPI in HosInfoMacOSX

There were some checks removed previously in
bc196970b549782bffde5fdbfa450c565af11fc1.

However, all these SPIs are actually defined in macOS 12 and onward, not
macOSX 10.12 as the previous commit would suggest. As a result, if you
have access to these SPIs lldb will fail to compile correctly.

Instead of adding back the __builtin_availability checks, it seems
easier just to check the minimum deployment target with Availability
macros.

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

Added: 


Modified: 
lldb/source/Host/macosx/objcxx/HostInfoMacOSX.mm

Removed: 




diff  --git a/lldb/source/Host/macosx/objcxx/HostInfoMacOSX.mm 
b/lldb/source/Host/macosx/objcxx/HostInfoMacOSX.mm
index e56a930d80c6b1..1af450374e776b 100644
--- a/lldb/source/Host/macosx/objcxx/HostInfoMacOSX.mm
+++ b/lldb/source/Host/macosx/objcxx/HostInfoMacOSX.mm
@@ -34,18 +34,21 @@
 #include 
 
 // Objective-C/C++ includes
+#include 
 #include 
 #include 
 #include 
+#if defined(MAC_OS_X_VERSION_MIN_REQUIRED) && \
+  MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_VERSION_12_0
 #if __has_include()
 #include 
 #define SDK_HAS_NEW_DYLD_INTROSPECTION_SPIS
 #endif
+#endif
 #include 
 
 // These are needed when compiling on systems
 // that do not yet have these definitions
-#include 
 #ifndef CPU_SUBTYPE_X86_64_H
 #define CPU_SUBTYPE_X86_64_H ((cpu_subtype_t)8)
 #endif



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


[Lldb-commits] [PATCH] D156838: [lldb] Re-add compile-time checks for SPI in HosInfoMacOSX

2023-08-02 Thread Alex Langford via Phabricator via lldb-commits
This revision was automatically updated to reflect the committed changes.
Closed by commit rG6c2e3249160f: [lldb] Re-add compile-time checks for SPI in 
HosInfoMacOSX (authored by bulbazord).

Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156838/new/

https://reviews.llvm.org/D156838

Files:
  lldb/source/Host/macosx/objcxx/HostInfoMacOSX.mm


Index: lldb/source/Host/macosx/objcxx/HostInfoMacOSX.mm
===
--- lldb/source/Host/macosx/objcxx/HostInfoMacOSX.mm
+++ lldb/source/Host/macosx/objcxx/HostInfoMacOSX.mm
@@ -34,18 +34,21 @@
 #include 
 
 // Objective-C/C++ includes
+#include 
 #include 
 #include 
 #include 
+#if defined(MAC_OS_X_VERSION_MIN_REQUIRED) && \
+  MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_VERSION_12_0
 #if __has_include()
 #include 
 #define SDK_HAS_NEW_DYLD_INTROSPECTION_SPIS
 #endif
+#endif
 #include 
 
 // These are needed when compiling on systems
 // that do not yet have these definitions
-#include 
 #ifndef CPU_SUBTYPE_X86_64_H
 #define CPU_SUBTYPE_X86_64_H ((cpu_subtype_t)8)
 #endif


Index: lldb/source/Host/macosx/objcxx/HostInfoMacOSX.mm
===
--- lldb/source/Host/macosx/objcxx/HostInfoMacOSX.mm
+++ lldb/source/Host/macosx/objcxx/HostInfoMacOSX.mm
@@ -34,18 +34,21 @@
 #include 
 
 // Objective-C/C++ includes
+#include 
 #include 
 #include 
 #include 
+#if defined(MAC_OS_X_VERSION_MIN_REQUIRED) && \
+  MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_VERSION_12_0
 #if __has_include()
 #include 
 #define SDK_HAS_NEW_DYLD_INTROSPECTION_SPIS
 #endif
+#endif
 #include 
 
 // These are needed when compiling on systems
 // that do not yet have these definitions
-#include 
 #ifndef CPU_SUBTYPE_X86_64_H
 #define CPU_SUBTYPE_X86_64_H ((cpu_subtype_t)8)
 #endif
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [PATCH] D156919: [lldb/crashlog] Make register output match lldb ordering in legacy mode

2023-08-02 Thread Med Ismail Bennani via Phabricator via lldb-commits
mib created this revision.
mib added reviewers: bulbazord, JDevlieghere.
mib added a project: LLDB.
Herald added a project: All.
mib requested review of this revision.
Herald added a subscriber: lldb-commits.

This patch changes the way we dump the registers from the legacy
crashlog command to make sure that the ordering matches the one from lldb.

rdar://109172073

Signed-off-by: Med Ismail Bennani 


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D156919

Files:
  lldb/examples/python/crashlog.py

Index: lldb/examples/python/crashlog.py
===
--- lldb/examples/python/crashlog.py
+++ lldb/examples/python/crashlog.py
@@ -71,6 +71,7 @@
 sys.exit(1)
 
 from lldb.utils import symbolication
+from lldb.plugins.scripted_process import INTEL64_GPR, ARM64_GPR
 
 
 def read_plist(s):
@@ -84,7 +85,7 @@
 class Thread:
 """Class that represents a thread in a darwin crash log"""
 
-def __init__(self, index, app_specific_backtrace):
+def __init__(self, index, app_specific_backtrace, arch):
 self.index = index
 self.id = index
 self.images = list()
@@ -96,8 +97,37 @@
 self.queue = None
 self.crashed = False
 self.app_specific_backtrace = app_specific_backtrace
+self.arch = arch
+
+def dump_registers(self, prefix=""):
+registers_info = None
+if self.arch:
+if "x86_64" == self.arch:
+registers_info = INTEL64_GPR
+elif "arm64" in self.arch:
+registers_info = ARM64_GPR
+else:
+print("unknown target architecture: %s" % self.arch)
+return
 
-def dump(self, prefix):
+for reg_info in registers_info:
+reg_name = None
+if reg_info["name"] in self.registers:
+reg_name = reg_info["name"]
+elif "generic" in reg_info and reg_info["generic"] in self.registers:
+reg_name = reg_info["generic"]
+else:
+# Skip register
+continue
+
+reg = self.registers[reg_name]
+print("%s%-8s = %#16.16x" % (prefix, reg_name, reg))
+else:
+for reg in self.registers.keys():
+print("%s%-8s = %#16.16x" % (prefix, reg, self.registers[reg]))
+
+
+def dump(self, prefix=""):
 if self.app_specific_backtrace:
 print(
 "%Application Specific Backtrace[%u] %s"
@@ -111,8 +141,7 @@
 frame.dump(prefix + "")
 if self.registers:
 print("%s  Registers:" % (prefix))
-for reg in self.registers.keys():
-print("%s%-8s = %#16.16x" % (prefix, reg, self.registers[reg]))
+self.dump_registers(prefix)
 
 def dump_symbolicated(self, crash_log, options):
 this_thread_crashed = self.app_specific_backtrace
@@ -194,8 +223,7 @@
 print(frame)
 if self.registers:
 print()
-for reg in self.registers.keys():
-print("%-8s = %#16.16x" % (reg, self.registers[reg]))
+self.dump_registers()
 elif self.crashed:
 print()
 print("No thread state (register information) available")
@@ -655,7 +683,7 @@
 def parse_threads(self, json_threads):
 idx = 0
 for json_thread in json_threads:
-thread = self.crashlog.Thread(idx, False)
+thread = self.crashlog.Thread(idx, False, self.crashlog.process_arch)
 if "name" in json_thread:
 thread.name = json_thread["name"]
 thread.reason = json_thread["name"]
@@ -749,7 +777,7 @@
 
 def parse_app_specific_backtraces(self, json_app_specific_bts):
 for idx, backtrace in enumerate(json_app_specific_bts):
-thread = self.crashlog.Thread(idx, True)
+thread = self.crashlog.Thread(idx, True, self.crashlog.process_arch)
 thread.queue = "Application Specific Backtrace"
 if self.parse_asi_backtrace(thread, backtrace):
 self.crashlog.threads.append(thread)
@@ -1008,7 +1036,7 @@
 self.app_specific_backtrace = False
 self.parse_mode = CrashLogParseMode.THREAD
 thread_idx = int(thread_match.group(1))
-self.thread = self.crashlog.Thread(thread_idx, False)
+self.thread = self.crashlog.Thread(thread_idx, False, self.crashlog.process_arch)
 return
 return
 elif line.startswith("Binary Images:"):
@@ -1020,12 +1048,12 @@
 self.parse_m

[Lldb-commits] [PATCH] D156919: [lldb/crashlog] Make register output match lldb ordering in legacy mode

2023-08-02 Thread Alex Langford via Phabricator via lldb-commits
bulbazord added a comment.

In general looks good to me. I have one suggestion and one question.




Comment at: lldb/examples/python/crashlog.py:104
+registers_info = None
+if self.arch:
+if "x86_64" == self.arch:

Is there a reason to do anything if `self.arch` isn't set? (Or is set to `None`)



Comment at: lldb/examples/python/crashlog.py:119-124
+else:
+# Skip register
+continue
+
+reg = self.registers[reg_name]
+print("%s%-8s = %#16.16x" % (prefix, reg_name, reg))

nit: You can avoid an else+continue if you check reg_name at the end. Just a 
style thing though, feel free to ignore.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156919/new/

https://reviews.llvm.org/D156919

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


[Lldb-commits] [PATCH] D156919: [lldb/crashlog] Make register output match lldb ordering in legacy mode

2023-08-02 Thread Med Ismail Bennani via Phabricator via lldb-commits
mib marked 2 inline comments as done.
mib added inline comments.



Comment at: lldb/examples/python/crashlog.py:104
+registers_info = None
+if self.arch:
+if "x86_64" == self.arch:

bulbazord wrote:
> Is there a reason to do anything if `self.arch` isn't set? (Or is set to 
> `None`)
If we fail to parse it from the report or if it's missing (for some reasons), 
`self.crashlog.process_arch` will be `None`.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156919/new/

https://reviews.llvm.org/D156919

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


[Lldb-commits] [PATCH] D156822: [lldb] Make IR interpretation interruptible

2023-08-02 Thread Jim Ingham via Phabricator via lldb-commits
jingham added a comment.

LGTM.  Thanks for adding this.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156822/new/

https://reviews.llvm.org/D156822

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


[Lldb-commits] [PATCH] D156934: [lldb][NFCI] Add SBTraceCursor.h to swig headers file

2023-08-02 Thread Alex Langford via Phabricator via lldb-commits
bulbazord created this revision.
bulbazord added reviewers: JDevlieghere, mib.
Herald added a project: All.
bulbazord requested review of this revision.
Herald added a project: LLDB.
Herald added a subscriber: lldb-commits.

Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D156934

Files:
  lldb/bindings/headers.swig


Index: lldb/bindings/headers.swig
===
--- lldb/bindings/headers.swig
+++ lldb/bindings/headers.swig
@@ -63,6 +63,7 @@
 #include "lldb/API/SBThreadCollection.h"
 #include "lldb/API/SBThreadPlan.h"
 #include "lldb/API/SBTrace.h"
+#include "lldb/API/SBTraceCursor.h"
 #include "lldb/API/SBType.h"
 #include "lldb/API/SBTypeCategory.h"
 #include "lldb/API/SBTypeEnumMember.h"


Index: lldb/bindings/headers.swig
===
--- lldb/bindings/headers.swig
+++ lldb/bindings/headers.swig
@@ -63,6 +63,7 @@
 #include "lldb/API/SBThreadCollection.h"
 #include "lldb/API/SBThreadPlan.h"
 #include "lldb/API/SBTrace.h"
+#include "lldb/API/SBTraceCursor.h"
 #include "lldb/API/SBType.h"
 #include "lldb/API/SBTypeCategory.h"
 #include "lldb/API/SBTypeEnumMember.h"
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] 61af957 - [lldb] Make IR interpretation interruptible

2023-08-02 Thread Jonas Devlieghere via lldb-commits

Author: Jonas Devlieghere
Date: 2023-08-02T13:56:24-07:00
New Revision: 61af957aeaa3ba69a64598966525af6a40280fa0

URL: 
https://github.com/llvm/llvm-project/commit/61af957aeaa3ba69a64598966525af6a40280fa0
DIFF: 
https://github.com/llvm/llvm-project/commit/61af957aeaa3ba69a64598966525af6a40280fa0.diff

LOG: [lldb] Make IR interpretation interruptible

Check the interrupt flag while interpreting IR expressions and allow the
user to interrupt them.

Differential revision: https://reviews.llvm.org/D156822

Added: 


Modified: 
lldb/source/Expression/IRInterpreter.cpp
lldb/test/API/commands/expression/ir-interpreter/TestIRInterpreter.py

Removed: 




diff  --git a/lldb/source/Expression/IRInterpreter.cpp 
b/lldb/source/Expression/IRInterpreter.cpp
index 36d9980f73e9c0..10457f51a95d8b 100644
--- a/lldb/source/Expression/IRInterpreter.cpp
+++ b/lldb/source/Expression/IRInterpreter.cpp
@@ -7,6 +7,7 @@
 
//===--===//
 
 #include "lldb/Expression/IRInterpreter.h"
+#include "lldb/Core/Debugger.h"
 #include "lldb/Core/Module.h"
 #include "lldb/Core/ModuleSpec.h"
 #include "lldb/Core/ValueObject.h"
@@ -464,6 +465,8 @@ static const char *unsupported_operand_error =
 "Interpreter doesn't handle one of the expression's operands";
 static const char *interpreter_internal_error =
 "Interpreter encountered an internal error";
+static const char *interrupt_error =
+"Interrupted while interpreting expression";
 static const char *bad_value_error =
 "Interpreter couldn't resolve a value during execution";
 static const char *memory_allocation_error =
@@ -726,6 +729,9 @@ bool IRInterpreter::Interpret(llvm::Module &module, 
llvm::Function &function,
 
   frame.Jump(&function.front());
 
+  lldb_private::Process *process = exe_ctx.GetProcessPtr();
+  lldb_private::Target *target = exe_ctx.GetTargetPtr();
+
   using clock = std::chrono::steady_clock;
 
   // Compute the time at which the timeout has been exceeded.
@@ -741,6 +747,16 @@ bool IRInterpreter::Interpret(llvm::Module &module, 
llvm::Function &function,
   return false;
 }
 
+// If we have access to the debugger we can honor an interrupt request.
+if (target) {
+  if (INTERRUPT_REQUESTED(target->GetDebugger(),
+  "Interrupted in IR interpreting.")) {
+error.SetErrorToGenericError();
+error.SetErrorString(interrupt_error);
+return false;
+  }
+}
+
 const Instruction *inst = &*frame.m_ii;
 
 LLDB_LOGF(log, "Interpreting %s", PrintValue(inst).c_str());
@@ -1432,7 +1448,7 @@ bool IRInterpreter::Interpret(llvm::Module &module, 
llvm::Function &function,
   }
 
   // Make sure we have a valid process
-  if (!exe_ctx.GetProcessPtr()) {
+  if (!process) {
 error.SetErrorToGenericError();
 error.SetErrorString("unable to get the process");
 return false;
@@ -1538,11 +1554,11 @@ bool IRInterpreter::Interpret(llvm::Module &module, 
llvm::Function &function,
 return false;
   }
 
-  exe_ctx.GetProcessPtr()->SetRunningUserExpression(true);
+  process->SetRunningUserExpression(true);
 
   // Execute the actual function call thread plan
-  lldb::ExpressionResults res = exe_ctx.GetProcessRef().RunThreadPlan(
-  exe_ctx, call_plan_sp, options, diagnostics);
+  lldb::ExpressionResults res =
+  process->RunThreadPlan(exe_ctx, call_plan_sp, options, diagnostics);
 
   // Check that the thread plan completed successfully
   if (res != lldb::ExpressionResults::eExpressionCompleted) {
@@ -1551,7 +1567,7 @@ bool IRInterpreter::Interpret(llvm::Module &module, 
llvm::Function &function,
 return false;
   }
 
-  exe_ctx.GetProcessPtr()->SetRunningUserExpression(false);
+  process->SetRunningUserExpression(false);
 
   // Void return type
   if (returnType->isVoidTy()) {

diff  --git 
a/lldb/test/API/commands/expression/ir-interpreter/TestIRInterpreter.py 
b/lldb/test/API/commands/expression/ir-interpreter/TestIRInterpreter.py
index 3528f1636acd17..1b11d8e5ba054b 100644
--- a/lldb/test/API/commands/expression/ir-interpreter/TestIRInterpreter.py
+++ b/lldb/test/API/commands/expression/ir-interpreter/TestIRInterpreter.py
@@ -47,6 +47,40 @@ def test_interpreter_timeout(self):
 self.assertGreaterEqual(duration_sec, 1)
 self.assertLess(duration_sec, 30)
 
+def test_interpreter_interrupt(self):
+"""Test interrupting the IRInterpreter."""
+self.build()
+self.target = self.dbg.CreateTarget(self.getBuildArtifact("a.out"))
+self.assertTrue(self.target, VALID_TARGET)
+
+# A non-trivial infinite loop.
+inf_loop = "for (unsigned i = 0; i < 100; ++i) --i; 1"
+
+options = lldb.SBExpressionOptions()
+
+# This is an IRInterpreter specific test, so 

[Lldb-commits] [PATCH] D156822: [lldb] Make IR interpretation interruptible

2023-08-02 Thread Jonas Devlieghere via Phabricator via lldb-commits
This revision was automatically updated to reflect the committed changes.
Closed by commit rG61af957aeaa3: [lldb] Make IR interpretation interruptible 
(authored by JDevlieghere).
Herald added a project: LLDB.

Changed prior to commit:
  https://reviews.llvm.org/D156822?vs=546174&id=546600#toc

Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156822/new/

https://reviews.llvm.org/D156822

Files:
  lldb/source/Expression/IRInterpreter.cpp
  lldb/test/API/commands/expression/ir-interpreter/TestIRInterpreter.py

Index: lldb/test/API/commands/expression/ir-interpreter/TestIRInterpreter.py
===
--- lldb/test/API/commands/expression/ir-interpreter/TestIRInterpreter.py
+++ lldb/test/API/commands/expression/ir-interpreter/TestIRInterpreter.py
@@ -47,6 +47,40 @@
 self.assertGreaterEqual(duration_sec, 1)
 self.assertLess(duration_sec, 30)
 
+def test_interpreter_interrupt(self):
+"""Test interrupting the IRInterpreter."""
+self.build()
+self.target = self.dbg.CreateTarget(self.getBuildArtifact("a.out"))
+self.assertTrue(self.target, VALID_TARGET)
+
+# A non-trivial infinite loop.
+inf_loop = "for (unsigned i = 0; i < 100; ++i) --i; 1"
+
+options = lldb.SBExpressionOptions()
+
+# This is an IRInterpreter specific test, so disable the JIT.
+options.SetAllowJIT(False)
+
+# Make sure we have a pretty long (10s) timeout so we have a chance to
+# interrupt the interpreted expression.
+options.SetTimeoutInMicroSeconds(1000)
+
+self.dbg.RequestInterrupt()
+
+self.dbg.SetAsync(True)
+res = self.target.EvaluateExpression(inf_loop, options)
+self.dbg.SetAsync(False)
+
+# Be sure to turn this off again:
+def cleanup():
+if self.dbg.InterruptRequested():
+self.dbg.CancelInterruptRequest()
+
+self.addTearDownHook(cleanup)
+
+interrupt_error = "Interrupted while interpreting expression"
+self.assertIn(interrupt_error, str(res.GetError()))
+
 def setUp(self):
 # Call super's setUp().
 TestBase.setUp(self)
Index: lldb/source/Expression/IRInterpreter.cpp
===
--- lldb/source/Expression/IRInterpreter.cpp
+++ lldb/source/Expression/IRInterpreter.cpp
@@ -7,6 +7,7 @@
 //===--===//
 
 #include "lldb/Expression/IRInterpreter.h"
+#include "lldb/Core/Debugger.h"
 #include "lldb/Core/Module.h"
 #include "lldb/Core/ModuleSpec.h"
 #include "lldb/Core/ValueObject.h"
@@ -464,6 +465,8 @@
 "Interpreter doesn't handle one of the expression's operands";
 static const char *interpreter_internal_error =
 "Interpreter encountered an internal error";
+static const char *interrupt_error =
+"Interrupted while interpreting expression";
 static const char *bad_value_error =
 "Interpreter couldn't resolve a value during execution";
 static const char *memory_allocation_error =
@@ -726,6 +729,9 @@
 
   frame.Jump(&function.front());
 
+  lldb_private::Process *process = exe_ctx.GetProcessPtr();
+  lldb_private::Target *target = exe_ctx.GetTargetPtr();
+
   using clock = std::chrono::steady_clock;
 
   // Compute the time at which the timeout has been exceeded.
@@ -741,6 +747,16 @@
   return false;
 }
 
+// If we have access to the debugger we can honor an interrupt request.
+if (target) {
+  if (INTERRUPT_REQUESTED(target->GetDebugger(),
+  "Interrupted in IR interpreting.")) {
+error.SetErrorToGenericError();
+error.SetErrorString(interrupt_error);
+return false;
+  }
+}
+
 const Instruction *inst = &*frame.m_ii;
 
 LLDB_LOGF(log, "Interpreting %s", PrintValue(inst).c_str());
@@ -1432,7 +1448,7 @@
   }
 
   // Make sure we have a valid process
-  if (!exe_ctx.GetProcessPtr()) {
+  if (!process) {
 error.SetErrorToGenericError();
 error.SetErrorString("unable to get the process");
 return false;
@@ -1538,11 +1554,11 @@
 return false;
   }
 
-  exe_ctx.GetProcessPtr()->SetRunningUserExpression(true);
+  process->SetRunningUserExpression(true);
 
   // Execute the actual function call thread plan
-  lldb::ExpressionResults res = exe_ctx.GetProcessRef().RunThreadPlan(
-  exe_ctx, call_plan_sp, options, diagnostics);
+  lldb::ExpressionResults res =
+  process->RunThreadPlan(exe_ctx, call_plan_sp, options, diagnostics);
 
   // Check that the thread plan completed successfully
   if (res != lldb::ExpressionResults::eExpressionCompleted) {
@@ -1551,7 +1567,7 @@
 return false;
   }
 
-  exe_ctx.GetProcessPtr()->SetRunningUserExpression(false);
+  process->SetRunningUserExpression(f

[Lldb-commits] [PATCH] D156919: [lldb/crashlog] Make register output match lldb ordering in legacy mode

2023-08-02 Thread Jonas Devlieghere via Phabricator via lldb-commits
JDevlieghere accepted this revision.
JDevlieghere added a comment.
This revision is now accepted and ready to land.

LGTM


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156919/new/

https://reviews.llvm.org/D156919

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


[Lldb-commits] [PATCH] D156086: [lldb][NFC] Use MCInstrAnalysis when available in the disassembler plugin

2023-08-02 Thread Fangrui Song via Phabricator via lldb-commits
MaskRay added inline comments.



Comment at: lldb/unittests/Disassembler/RISCV/TestMCDisasmInstanceRISCV.cpp:23
+
+class TestMCDisasmInstanceRISCV : public testing::Test {
+public:

Place all classes and test methods in an anonymous namespace.



Comment at: lldb/unittests/Disassembler/RISCV/TestMCDisasmInstanceRISCV.cpp:64
+  // and we should skip these tests without marking anything as failing.
+  if (disass_sp) {
+const InstructionList inst_list (disass_sp->GetInstructionList());

Early return



Comment at: llvm/include/llvm/MC/MCInstrAnalysis.h:76
+  return false;
+if (Info->get(Inst.getOpcode()).hasDefOfPhysReg(Inst, PC, MCRI))
+  return true;

`return Info->get(Inst.getOpcode()).hasDefOfPhysReg(Inst, PC, MCRI)`


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156086/new/

https://reviews.llvm.org/D156086

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


[Lldb-commits] [lldb] 5f45a87 - [lldb] Print hint if object description is requested but not implemented

2023-08-02 Thread Augusto Noronha via lldb-commits

Author: Augusto Noronha
Date: 2023-08-02T15:33:32-07:00
New Revision: 5f45a87bf029cc4b9815f5f819906198b07e00d1

URL: 
https://github.com/llvm/llvm-project/commit/5f45a87bf029cc4b9815f5f819906198b07e00d1
DIFF: 
https://github.com/llvm/llvm-project/commit/5f45a87bf029cc4b9815f5f819906198b07e00d1.diff

LOG: [lldb] Print hint if object description is requested but not implemented

Lots of users use "po" as their default print command. If the type
doesn't implement the description function the output is often not what
the user wants. Print a hint telling the user that they might prefer
using "p" instead.

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

Added: 
lldb/test/API/lang/objc/objc-po-hint/Makefile
lldb/test/API/lang/objc/objc-po-hint/TestObjcPoHint.py
lldb/test/API/lang/objc/objc-po-hint/main.m

Modified: 
lldb/include/lldb/Core/Debugger.h
lldb/source/Commands/CommandObjectDWIMPrint.cpp
lldb/source/Core/CoreProperties.td
lldb/source/Core/Debugger.cpp

Removed: 




diff  --git a/lldb/include/lldb/Core/Debugger.h 
b/lldb/include/lldb/Core/Debugger.h
index 239429b75c4260..be16e742a72099 100644
--- a/lldb/include/lldb/Core/Debugger.h
+++ b/lldb/include/lldb/Core/Debugger.h
@@ -321,6 +321,8 @@ class Debugger : public 
std::enable_shared_from_this,
 
   llvm::StringRef GetAutosuggestionAnsiSuffix() const;
 
+  bool GetShowDontUsePoHint() const;
+
   bool GetUseSourceCache() const;
 
   bool SetUseSourceCache(bool use_source_cache);

diff  --git a/lldb/source/Commands/CommandObjectDWIMPrint.cpp 
b/lldb/source/Commands/CommandObjectDWIMPrint.cpp
index b2b7f201a5add1..7b168eab9e02d4 100644
--- a/lldb/source/Commands/CommandObjectDWIMPrint.cpp
+++ b/lldb/source/Commands/CommandObjectDWIMPrint.cpp
@@ -25,6 +25,8 @@
 #include "llvm/ADT/StringRef.h"
 #include "llvm/Support/FormatVariadic.h"
 
+#include 
+
 using namespace llvm;
 using namespace lldb;
 using namespace lldb_private;
@@ -95,8 +97,46 @@ bool CommandObjectDWIMPrint::DoExecute(StringRef command,
   m_expr_options.m_verbosity, m_format_options.GetFormat());
   dump_options.SetHideRootName(suppress_result);
 
+  bool is_po = m_varobj_options.use_objc;
+
   StackFrame *frame = m_exe_ctx.GetFramePtr();
 
+  // Either Swift was explicitly specified, or the frame is Swift.
+  lldb::LanguageType language = m_expr_options.language;
+  if (language == lldb::eLanguageTypeUnknown && frame)
+language = frame->GuessLanguage();
+
+  // Add a hint if object description was requested, but no description
+  // function was implemented.
+  auto maybe_add_hint = [&](llvm::StringRef output) {
+// Identify the default output of object description for Swift and
+// Objective-C
+// ". The regex is:
+// - Start with "<".
+// - Followed by 1 or more non-whitespace characters.
+// - Followed by ": 0x".
+// - Followed by 5 or more hex digits.
+// - Followed by ">".
+// - End with zero or more whitespace characters.
+const std::regex swift_class_regex("^<\\S+: 0x[[:xdigit:]]{5,}>\\s*$");
+
+if (GetDebugger().GetShowDontUsePoHint() && target_ptr &&
+(language == lldb::eLanguageTypeSwift ||
+ language == lldb::eLanguageTypeObjC) &&
+std::regex_match(output.data(), swift_class_regex)) {
+
+  static bool note_shown = false;
+  if (note_shown)
+return;
+
+  result.GetOutputStream()
+  << "note: object description requested, but type doesn't implement "
+ "a custom object description. Consider using \"p\" instead of "
+ "\"po\" (this note will only be shown once per debug session).\n";
+  note_shown = true;
+}
+  };
+
   // First, try `expr` as the name of a frame variable.
   if (frame) {
 auto valobj_sp = frame->FindVariable(ConstString(expr));
@@ -114,7 +154,15 @@ bool CommandObjectDWIMPrint::DoExecute(StringRef command,
 flags, expr);
   }
 
-  valobj_sp->Dump(result.GetOutputStream(), dump_options);
+  if (is_po) {
+StreamString temp_result_stream;
+valobj_sp->Dump(temp_result_stream, dump_options);
+llvm::StringRef output = temp_result_stream.GetString();
+maybe_add_hint(output);
+result.GetOutputStream() << output;
+  } else {
+valobj_sp->Dump(result.GetOutputStream(), dump_options);
+  }
   result.SetStatus(eReturnStatusSuccessFinishResult);
   return true;
 }
@@ -135,8 +183,17 @@ bool CommandObjectDWIMPrint::DoExecute(StringRef command,
 expr);
   }
 
-  if (valobj_sp->GetError().GetError() != UserExpression::kNoResult)
-valobj_sp->Dump(result.GetOutputStream(), dump_options);
+  if (valobj_sp->GetError().GetError() != UserExpression::kNoResult) {
+if (is_po) {
+  StreamString temp_result_stream;
+  valobj_sp->Dump(temp_r

[Lldb-commits] [PATCH] D153489: [lldb] Print hint if object description is requested but not implemented

2023-08-02 Thread Augusto Noronha via Phabricator via lldb-commits
This revision was automatically updated to reflect the committed changes.
Closed by commit rG5f45a87bf029: [lldb] Print hint if object description is 
requested but not implemented (authored by augusto2112).

Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D153489/new/

https://reviews.llvm.org/D153489

Files:
  lldb/include/lldb/Core/Debugger.h
  lldb/source/Commands/CommandObjectDWIMPrint.cpp
  lldb/source/Core/CoreProperties.td
  lldb/source/Core/Debugger.cpp
  lldb/test/API/lang/objc/objc-po-hint/Makefile
  lldb/test/API/lang/objc/objc-po-hint/TestObjcPoHint.py
  lldb/test/API/lang/objc/objc-po-hint/main.m

Index: lldb/test/API/lang/objc/objc-po-hint/main.m
===
--- /dev/null
+++ lldb/test/API/lang/objc/objc-po-hint/main.m
@@ -0,0 +1,22 @@
+#import 
+
+@interface Foo : NSObject {}
+
+-(id) init;
+
+@end
+
+@implementation Foo
+
+-(id) init
+{
+return self = [super init];
+}
+@end
+
+int main()
+{
+Foo *foo = [Foo new];
+NSLog(@"a"); // Set breakpoint here.
+return 0;
+}
Index: lldb/test/API/lang/objc/objc-po-hint/TestObjcPoHint.py
===
--- /dev/null
+++ lldb/test/API/lang/objc/objc-po-hint/TestObjcPoHint.py
@@ -0,0 +1,49 @@
+import lldb
+from lldbsuite.test.decorators import *
+from lldbsuite.test.lldbtest import *
+from lldbsuite.test import lldbutil
+
+
+class TestObjcPoHint(TestBase):
+NO_DEBUG_INFO_TESTCASE = True
+
+def test_show_po_hint(self):
+### Test that the po hint is shown once with the DWIM print command
+self.build()
+_, _, _, _ = lldbutil.run_to_source_breakpoint(
+self, "Set breakpoint here", lldb.SBFileSpec("main.m")
+)
+# Make sure the hint is printed the first time
+self.expect(
+"dwim-print -O -- foo",
+substrs=[
+"note: object description requested, but type doesn't implement "
+'a custom object description. Consider using "p" instead of "po"',
+"(
+  idx, g_debugger_properties[idx].default_uint_value != 0);
+}
+
 bool Debugger::GetUseSourceCache() const {
   const uint32_t idx = ePropertyUseSourceCache;
   return GetPropertyAtIndexAs(
Index: lldb/source/Core/CoreProperties.td
===
--- lldb/source/Core/CoreProperties.td
+++ lldb/source/Core/CoreProperties.td
@@ -195,6 +195,10 @@
 Global,
 DefaultStringValue<"${ansi.normal}">,
 Desc<"When displaying suggestion in a color-enabled terminal, use the ANSI terminal code specified in this format immediately after the suggestion.">;
+  def ShowDontUsePoHint: Property<"show-dont-use-po-hint", "Boolean">,
+Global,
+DefaultTrue,
+Desc<"If true, and object description was requested for a type that does not implement it, LLDB will print a hint telling the user to consider using p instead.">;
   def DWIMPrintVerbosity: Property<"dwim-print-verbosity", "Enum">,
 Global,
 DefaultEnumValue<"eDWIMPrintVerbosityNone">,
Index: lldb/source/Commands/CommandObjectDWIMPrint.cpp
===
--- lldb/source/Commands/CommandObjectDWIMPrint.cpp
+++ lldb/source/Commands/CommandObjectDWIMPrint.cpp
@@ -25,6 +25,8 @@
 #include "llvm/ADT/StringRef.h"
 #include "llvm/Support/FormatVariadic.h"
 
+#include 
+
 using namespace llvm;
 using namespace lldb;
 using namespace lldb_private;
@@ -95,8 +97,46 @@
   m_expr_options.m_verbosity, m_format_options.GetFormat());
   dump_options.SetHideRootName(suppress_result);
 
+  bool is_po = m_varobj_options.use_objc;
+
   StackFrame *frame = m_exe_ctx.GetFramePtr();
 
+  // Either Swift was explicitly specified, or the frame is Swift.
+  lldb::LanguageType language = m_expr_options.language;
+  if (language == lldb::eLanguageTypeUnknown && frame)
+language = frame->GuessLanguage();
+
+  // Add a hint if object description was requested, but no description
+  // function was implemented.
+  auto maybe_add_hint = [&](llvm::StringRef output) {
+// Identify the default output of object description for Swift and
+// Objective-C
+// ". The regex is:
+// - Start with "<".
+// - Followed by 1 or more non-whitespace characters.
+// - Followed by ": 0x".
+// - Followed by 5 or more hex digits.
+// - Followed by ">".
+// - End with zero or more whitespace characters.
+const std::regex swift_class_regex("^<\\S+: 0x[[:xdigit:]]{5,}>\\s*$");
+
+if (GetDebugger().GetShowDontUsePoHint() && target_ptr &&
+(language == lldb::eLanguageTypeSwift ||
+ language == lldb::eLanguageTypeObjC) &&
+std::regex_match(output.data(), swift_class_regex)) {
+
+  static bool note_shown = false;
+  if (note_shown)
+return;
+
+  result.GetOutputStream()
+  << "note: object description requ

[Lldb-commits] [PATCH] D156949: [lldb] Update LLDB Code Ownership

2023-08-02 Thread Jonas Devlieghere via Phabricator via lldb-commits
JDevlieghere created this revision.
JDevlieghere added reviewers: jasonmolenda, DavidSpickett, jingham, bulbazord, 
Michael137, clayborg, mib, labath, wallace, compnerd, aprantl, zequanwu, 
emaste, omjavaid.
Herald added a subscriber: yaxunl.
Herald added a project: All.
JDevlieghere requested review of this revision.

https://discourse.llvm.org/t/rfc-update-lldb-code-ownership/72253


https://reviews.llvm.org/D156949

Files:
  lldb/CODE_OWNERS.txt
  lldb/CodeOwners.rst

Index: lldb/CodeOwners.rst
===
--- /dev/null
+++ lldb/CodeOwners.rst
@@ -0,0 +1,244 @@
+
+LLDB Code Owners
+
+
+This file is a list of the people responsible for ensuring that patches for a
+particular part of LLDB are reviewed, either by themself or by someone else.
+They are also the gatekeepers for their part of LLDB, with the final word on
+what goes in or not.
+
+.. contents::
+   :depth: 2
+   :local:
+
+Current Code Owners
+===
+The following people are the active code owners for the project. Please reach
+out to them for code reviews, questions about their area of expertise, or other
+assistance.
+
+All parts of LLDB not covered by someone else
+--
+| Jonas Devlieghere
+| jonas\@devlieghere.com (email), jdevlieghere (Phabricator), jdevlieghere (GitHub)
+
+Components
+--
+These code owners are responsible for particular high-level components within
+LLDB.
+
+ABI
+~~~
+| Jason Molenda
+| jmolenda\@apple.com (email), jasonmolenda (Phabricator), jasonmolenda (GitHub)
+
+| David Spickett
+| david.spickett\@linaro.org (email), DavidSpickett (Phabricator), DavidSpickett (GitHub)
+
+
+Breakpoint
+~~
+| Jim Ingham
+| jingham\@apple.com (email), jingham (Phabricator), jimingham (GitHub)
+
+CMake & Build System
+
+| Jonas Devlieghere
+| jonas\@devlieghere.com (email), jdevlieghere (Phabricator), jdevlieghere (GitHub)
+
+| Alex Langford
+| alangford\@apple.com (email), bulbazord (Phabricator), bulbazord (GitHub)
+
+Commands
+
+| Jim Ingham
+| jingham\@apple.com (email), jingham (Phabricator), jimingham (GitHub)
+
+Expression Parser
+~
+| Michael Buch
+| michaelbuch12\@gmail.com (email), Michael137 (Phabricator), Michael137 (GitHub)
+
+| Jim Ingham
+| jingham\@apple.com (email), jingham (Phabricator), jimingham (GitHub)
+
+Interpreter
+~~~
+| Jim Ingham
+| jingham\@apple.com (email), jingham (Phabricator), jimingham (GitHub)
+
+| Greg Clayton
+| gclayton\@fb.com (email), clayborg (Phabricator), clayborg (GitHub)
+
+
+Lua
+~~~
+| Jonas Delvieghere
+| jonas\@devlieghere.com (email), jdevlieghere (Phabricator), jdevlieghere (GitHub)
+
+Python
+~~
+| Med Ismail Bennani
+| ismail\@bennani.ma (email), mib (Phabricator), medismailben (GitHub)
+
+Target/Process Control
+~~
+| Med Ismail Bennani
+| ismail\@bennani.ma (email), mib (Phabricator), medismailben (GitHub)
+
+| Jim Ingham
+| jingham\@apple.com (email), jingham (Phabricator), jimingham (GitHub)
+
+Test Suite
+~~
+| Jonas Devlieghere
+| jonas\@devlieghere.com (email), jdevlieghere (Phabricator), jdevlieghere (GitHub)
+
+| Pavel Labath
+| pavel\@labath.sk (email), labath (Phabricator), labath (GitHub)
+
+Trace
+~
+| Walter Erquinigo
+| a20012251\@gmail.com (email), wallace (Phabricator), walter-erquinigo (GitHub)
+
+Unwinding
+~
+| Jason Molenda
+| jmolenda\@apple.com (email), jasonmolenda (Phabricator), jasonmolenda (GitHub)
+
+Utility
+~~~
+| Pavel Labath
+| pavel\@labath.sk (email), labath (Phabricator), labath (GitHub)
+
+ValueObject
+~~~
+| Jim Ingham
+| jingham\@apple.com (email), jingham (Phabricator), jimingham (GitHub)
+
+Watchpoints
+~~~
+| Jason Molenda
+| jmolenda\@apple.com (email), jasonmolenda (Phabricator), jasonmolenda (GitHub)
+
+File Formats
+
+The following people are responsible for decisions involving file and debug
+info formats.
+
+(PE)COFF
+
+| Saleem Abdulrasool
+| compnerd\@compnerd.org (email), compnerd (Phabricator), compnerd (GitHub)
+
+Breakpad
+
+| Pavel Labath
+| pavel\@labath.sk (email), labath (Phabricator), labath (GitHub)
+
+CTF
+~~~
+| Jonas Devlieghere
+| jonas\@devlieghere.com (email), jdevlieghere (Phabricator), jdevlieghere (GitHub)
+
+DWARF
+~
+| Adrian Prantl
+| aprantl\@apple.com (email), aprantl (Phabricator), adrian-prantl (GitHub)
+
+| Greg Clayton
+| gclayton\@fb.com (email), clayborg (Phabricator), clayborg (GitHub)
+
+ELF
+~~~
+| Pavel Labath
+| pavel\@labath.sk (email), labath (Phabricator), labath (GitHub)
+
+JSON
+
+| Jonas Devlieghere
+| jonas\@devlieghere.com (email), jdevlieghere (Phabricator), jdevlieghere (GitHub)
+
+MachO
+~
+| Greg Clayton
+| gclayton\@fb.com (email), clayborg (Phabricator), clayborg (GitHub)
+
+| Jason Molenda
+| jmolenda\@apple.com (email), jasonmolenda (Phabricator), jasonmolenda (GitHub)
+
+PDB

[Lldb-commits] [PATCH] D156804: [lldb] Bump SWIG minimum version to 4

2023-08-02 Thread Jonas Devlieghere via Phabricator via lldb-commits
JDevlieghere added a comment.

Added the bot owners as reviewers for visibility.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156804/new/

https://reviews.llvm.org/D156804

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


[Lldb-commits] [PATCH] D156949: [lldb] Update LLDB Code Ownership

2023-08-02 Thread Med Ismail Bennani via Phabricator via lldb-commits
mib accepted this revision.
mib added a comment.
This revision is now accepted and ready to land.

LGTM!


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156949/new/

https://reviews.llvm.org/D156949

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


[Lldb-commits] [PATCH] D140630: [lldb-vscode] Add data breakpoint support

2023-08-02 Thread Greg Clayton via Phabricator via lldb-commits
clayborg added a comment.

Sorry this fell off my radar. I was on medical leave for a surgery for 3 
months. Back now




Comment at: lldb/tools/lldb-vscode/Watchpoint.cpp:72
+  m_verified = true;
+  m_error = "";
+}





Comment at: lldb/tools/lldb-vscode/Watchpoint.cpp:90
+  m_verified = false;
+  m_error = "";
+}





Comment at: lldb/tools/lldb-vscode/Watchpoint.h:1
+//===-- Watchpoint.h --*- C++ -*-===//
+//

Fix width of this comment to match line 7



Comment at: lldb/tools/lldb-vscode/lldb-vscode.cpp:2449
+  << " with size " << std::dec << v_size;
+  populate_data_breakpoint_info(response, data.str(), description.str(), 
error.Success() && region_info.IsReadable(), error.Success() && 
region_info.IsWritable());
+  g_vsc.SendJSON(llvm::json::Value(std::move(response)));

Any line over 80 chars should be formatted to not exceed. Best to try and. use 
clang-format


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D140630/new/

https://reviews.llvm.org/D140630

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


[Lldb-commits] [PATCH] D155905: lldb RFC: Exposing set/get address masks, Fix*Address methods in SBProcess

2023-08-02 Thread Greg Clayton via Phabricator via lldb-commits
clayborg accepted this revision.
clayborg added a comment.
This revision is now accepted and ready to land.

Thanks for the explanation. LGTM


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D155905/new/

https://reviews.llvm.org/D155905

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


[Lldb-commits] [PATCH] D156949: [lldb] Update LLDB Code Ownership

2023-08-02 Thread Tanya Lattner via Phabricator via lldb-commits
tonic added a comment.

Since you are going to the effort of changing the CodeOwners file format from 
what is in LLVM, can you go ahead and add Discourse and Discord handles? It is 
often very helpful to tag someone on Discourse/Discord.  I'll be proposing this 
change for LLVM soon.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156949/new/

https://reviews.llvm.org/D156949

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


[Lldb-commits] [PATCH] D156086: [lldb][NFC] Use MCInstrAnalysis when available in the disassembler plugin

2023-08-02 Thread Venkata Ramanaiah Nalamothu via Phabricator via lldb-commits
RamNalamothu updated this revision to Diff 546688.
RamNalamothu added a comment.

Address review comments.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156086/new/

https://reviews.llvm.org/D156086

Files:
  lldb/source/Plugins/Disassembler/LLVMC/DisassemblerLLVMC.cpp
  lldb/unittests/Disassembler/CMakeLists.txt
  lldb/unittests/Disassembler/RISCV/CMakeLists.txt
  lldb/unittests/Disassembler/RISCV/TestMCDisasmInstanceRISCV.cpp
  lldb/unittests/Disassembler/x86/TestGetControlFlowKindx86.cpp
  llvm/include/llvm/MC/MCInstrAnalysis.h

Index: llvm/include/llvm/MC/MCInstrAnalysis.h
===
--- llvm/include/llvm/MC/MCInstrAnalysis.h
+++ llvm/include/llvm/MC/MCInstrAnalysis.h
@@ -18,6 +18,7 @@
 #include "llvm/MC/MCInst.h"
 #include "llvm/MC/MCInstrDesc.h"
 #include "llvm/MC/MCInstrInfo.h"
+#include "llvm/MC/MCRegisterInfo.h"
 #include 
 #include 
 
@@ -64,6 +65,17 @@
 return Info->get(Inst.getOpcode()).isTerminator();
   }
 
+  virtual bool mayAffectControlFlow(const MCInst &Inst,
+const MCRegisterInfo &MCRI) const {
+if (isBranch(Inst) || isCall(Inst) || isReturn(Inst) ||
+isIndirectBranch(Inst))
+  return true;
+unsigned PC = MCRI.getProgramCounter();
+if (PC == 0)
+  return false;
+return Info->get(Inst.getOpcode()).hasDefOfPhysReg(Inst, PC, MCRI);
+  }
+
   /// Returns true if at least one of the register writes performed by
   /// \param Inst implicitly clears the upper portion of all super-registers.
   ///
Index: lldb/unittests/Disassembler/x86/TestGetControlFlowKindx86.cpp
===
--- lldb/unittests/Disassembler/x86/TestGetControlFlowKindx86.cpp
+++ lldb/unittests/Disassembler/x86/TestGetControlFlowKindx86.cpp
@@ -129,17 +129,28 @@
   // If we failed to get a disassembler, we can assume it is because
   // the llvm we linked against was not built with the i386 target,
   // and we should skip these tests without marking anything as failing.
-
-  if (disass_sp) {
-const InstructionList inst_list(disass_sp->GetInstructionList());
-EXPECT_EQ(num_of_instructions, inst_list.GetSize());
-
-for (size_t i = 0; i < num_of_instructions; ++i) {
-  InstructionSP inst_sp;
-  inst_sp = inst_list.GetInstructionAtIndex(i);
-  ExecutionContext exe_ctx (nullptr, nullptr, nullptr);
-  InstructionControlFlowKind kind = inst_sp->GetControlFlowKind(&exe_ctx);
-  EXPECT_EQ(kind, result[i]);
-}
+  if (!disass_sp)
+return;
+
+  const InstructionList inst_list(disass_sp->GetInstructionList());
+  EXPECT_EQ(num_of_instructions, inst_list.GetSize());
+
+  for (size_t i = 0; i < num_of_instructions; ++i) {
+InstructionSP inst_sp;
+inst_sp = inst_list.GetInstructionAtIndex(i);
+ExecutionContext exe_ctx(nullptr, nullptr, nullptr);
+InstructionControlFlowKind kind = inst_sp->GetControlFlowKind(&exe_ctx);
+EXPECT_EQ(kind, result[i]);
+
+// Also, test the DisassemblerLLVMC::MCDisasmInstance methods.
+if (kind == eInstructionControlFlowKindReturn)
+  EXPECT_FALSE(inst_sp->IsCall());
+if (kind == eInstructionControlFlowKindCall)
+  EXPECT_TRUE(inst_sp->IsCall());
+if (kind == eInstructionControlFlowKindCall ||
+kind == eInstructionControlFlowKindJump ||
+kind == eInstructionControlFlowKindCondJump ||
+kind == eInstructionControlFlowKindReturn)
+  EXPECT_TRUE(inst_sp->DoesBranch());
   }
 }
Index: lldb/unittests/Disassembler/RISCV/TestMCDisasmInstanceRISCV.cpp
===
--- /dev/null
+++ lldb/unittests/Disassembler/RISCV/TestMCDisasmInstanceRISCV.cpp
@@ -0,0 +1,90 @@
+//===-- TestMCDisasmInstanceRISCV.cpp -===//
+
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+//
+//===--===//
+
+#include "llvm/Support/TargetSelect.h"
+#include "gtest/gtest.h"
+
+#include "lldb/Core/Address.h"
+#include "lldb/Core/Disassembler.h"
+#include "lldb/Target/ExecutionContext.h"
+#include "lldb/Utility/ArchSpec.h"
+
+#include "Plugins/Disassembler/LLVMC/DisassemblerLLVMC.h"
+
+using namespace lldb;
+using namespace lldb_private;
+
+class TestMCDisasmInstanceRISCV : public testing::Test {
+public:
+  static void SetUpTestCase();
+  static void TearDownTestCase();
+
+protected:
+};
+
+void TestMCDisasmInstanceRISCV::SetUpTestCase() {
+  llvm::InitializeAllTargets();
+  llvm::InitializeAllAsmPrinters();
+  llvm::InitializeAllTargetMCs();
+  llvm::InitializeAllDisassemblers();
+  DisassemblerLLVMC::Initialize();
+}
+
+void TestMCDisasmInstanceRISCV::TearDownTestCase() {
+  DisassemblerLLVMC::Terminate();

[Lldb-commits] [PATCH] D156086: [lldb][NFC] Use MCInstrAnalysis when available in the disassembler plugin

2023-08-02 Thread Venkata Ramanaiah Nalamothu via Phabricator via lldb-commits
RamNalamothu marked 3 inline comments as done.
RamNalamothu added a comment.

Thanks for the comments @MaskRay.




Comment at: lldb/unittests/Disassembler/RISCV/TestMCDisasmInstanceRISCV.cpp:23
+
+class TestMCDisasmInstanceRISCV : public testing::Test {
+public:

MaskRay wrote:
> Place all classes and test methods in an anonymous namespace.
All the disassembler tests need this change. Will address that in a separate 
patch.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156086/new/

https://reviews.llvm.org/D156086

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


[Lldb-commits] [PATCH] D156949: [lldb] Update LLDB Code Ownership

2023-08-02 Thread Jonas Devlieghere via Phabricator via lldb-commits
JDevlieghere updated this revision to Diff 546694.
JDevlieghere added a comment.

Add Discourse and Discord usernames.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156949/new/

https://reviews.llvm.org/D156949

Files:
  lldb/CODE_OWNERS.txt
  lldb/CodeOwners.rst

Index: lldb/CodeOwners.rst
===
--- /dev/null
+++ lldb/CodeOwners.rst
@@ -0,0 +1,244 @@
+
+LLDB Code Owners
+
+
+This file is a list of the people responsible for ensuring that patches for a
+particular part of LLDB are reviewed, either by themself or by someone else.
+They are also the gatekeepers for their part of LLDB, with the final word on
+what goes in or not.
+
+.. contents::
+   :depth: 2
+   :local:
+
+Current Code Owners
+===
+The following people are the active code owners for the project. Please reach
+out to them for code reviews, questions about their area of expertise, or other
+assistance.
+
+All parts of LLDB not covered by someone else
+--
+| Jonas Devlieghere
+| jonas\@devlieghere.com (email), jdevlieghere (Phabricator), jdevlieghere (GitHub), jdevlieghere (Discourse), jdevlieghere (Discord)
+
+Components
+--
+These code owners are responsible for particular high-level components within
+LLDB.
+
+ABI
+~~~
+| Jason Molenda
+| jmolenda\@apple.com (email), jasonmolenda (Phabricator), jasonmolenda (GitHub), jasonmolenda (Discourse), jasonmolenda (Discord)
+
+| David Spickett
+| david.spickett\@linaro.org (email), DavidSpickett (Phabricator), DavidSpickett (GitHub), DavidSpickett (Discourse), davidspickett (Discord)
+
+
+Breakpoint
+~~
+| Jim Ingham
+| jingham\@apple.com (email), jingham (Phabricator), jimingham (GitHub), jingham (Discourse)
+
+CMake & Build System
+
+| Jonas Devlieghere
+| jonas\@devlieghere.com (email), jdevlieghere (Phabricator), jdevlieghere (GitHub), jdevlieghere (Discourse), jdevlieghere (Discord)
+
+| Alex Langford
+| alangford\@apple.com (email), bulbazord (Phabricator), bulbazord (GitHub), bulbazord (Discourse), bulba_zord (Discord)
+
+Commands
+
+| Jim Ingham
+| jingham\@apple.com (email), jingham (Phabricator), jimingham (GitHub), jingham (Discourse)
+
+Expression Parser
+~
+| Michael Buch
+| michaelbuch12\@gmail.com (email), Michael137 (Phabricator), Michael137 (GitHub), Michael137 (Discourse)
+
+| Jim Ingham
+| jingham\@apple.com (email), jingham (Phabricator), jimingham (GitHub), jingham (Discourse)
+
+Interpreter
+~~~
+| Jim Ingham
+| jingham\@apple.com (email), jingham (Phabricator), jimingham (GitHub), jingham (Discourse)
+
+| Greg Clayton
+| gclayton\@fb.com (email), clayborg (Phabricator), clayborg (GitHub), clayborg (Discourse)
+
+
+Lua
+~~~
+| Jonas Delvieghere
+| jonas\@devlieghere.com (email), jdevlieghere (Phabricator), jdevlieghere (GitHub), jdevlieghere (Discourse), jdevlieghere (Discord)
+
+Python
+~~
+| Med Ismail Bennani
+| ismail\@bennani.ma (email), mib (Phabricator), medismailben (GitHub), mib (Discourse), mib#8727 (Discord)
+
+Target/Process Control
+~~
+| Med Ismail Bennani
+| ismail\@bennani.ma (email), mib (Phabricator), medismailben (GitHub), mib (Discourse), mib#8727 (Discord)
+
+| Jim Ingham
+| jingham\@apple.com (email), jingham (Phabricator), jimingham (GitHub), jingham (Discourse)
+
+Test Suite
+~~
+| Jonas Devlieghere
+| jonas\@devlieghere.com (email), jdevlieghere (Phabricator), jdevlieghere (GitHub), jdevlieghere (Discourse), jdevlieghere (Discord)
+
+| Pavel Labath
+| pavel\@labath.sk (email), labath (Phabricator), labath (GitHub), labath (Discourse)
+
+Trace
+~
+| Walter Erquinigo
+| a20012251\@gmail.com (email), wallace (Phabricator), walter-erquinigo (GitHub), wallace (Discourse), werquinigo (Discord)
+
+Unwinding
+~
+| Jason Molenda
+| jmolenda\@apple.com (email), jasonmolenda (Phabricator), jasonmolenda (GitHub), jasonmolenda (Discourse), jasonmolenda (Discord)
+
+Utility
+~~~
+| Pavel Labath
+| pavel\@labath.sk (email), labath (Phabricator), labath (GitHub), labath (Discourse)
+
+ValueObject
+~~~
+| Jim Ingham
+| jingham\@apple.com (email), jingham (Phabricator), jimingham (GitHub), jingham (Discourse)
+
+Watchpoints
+~~~
+| Jason Molenda
+| jmolenda\@apple.com (email), jasonmolenda (Phabricator), jasonmolenda (GitHub), jasonmolenda (Discourse), jasonmolenda (Discord)
+
+File Formats
+
+The following people are responsible for decisions involving file and debug
+info formats.
+
+(PE)COFF
+
+| Saleem Abdulrasool
+| compnerd\@compnerd.org (email), compnerd (Phabricator), compnerd (GitHub), compnerd (Discourse), compnerd (Discord)
+
+Breakpad
+
+| Pavel Labath
+| pavel\@labath.sk (email), labath (Phabricator), labath (GitHub), labath (Discourse)
+
+CTF
+~~~
+| Jonas Devlieghere
+| jonas\@devlieghere.com (email), jdevlieghere (Phabricator), jdevliegh