[Lldb-commits] [PATCH] D72437: [lldb/Bindings] Move bindings into their own subdirectory

2020-01-08 Thread Jonas Devlieghere via Phabricator via lldb-commits
JDevlieghere created this revision. JDevlieghere added reviewers: LLDB, labath. Herald added a subscriber: mgorny. Herald added a reviewer: jfb. Herald added a project: LLDB. All the code required to generate the language bindings for Python and Lua lives under scripts, even though the majority o

[Lldb-commits] [lldb] 51bdd98 - [lldb/SWIG] Refactor extensions to be non Python-specific (3/3)

2020-01-08 Thread Jonas Devlieghere via lldb-commits
Author: Jonas Devlieghere Date: 2020-01-08T21:02:59-08:00 New Revision: 51bdd98b8a52d07004bcaddff26caf376a1c32bf URL: https://github.com/llvm/llvm-project/commit/51bdd98b8a52d07004bcaddff26caf376a1c32bf DIFF: https://github.com/llvm/llvm-project/commit/51bdd98b8a52d07004bcaddff26caf376a1c32bf.d

[Lldb-commits] [PATCH] D71825: [lldb/Lua] Support loading Lua modules.

2020-01-08 Thread Jonas Devlieghere via Phabricator via lldb-commits
JDevlieghere updated this revision to Diff 236957. JDevlieghere added a comment. Skip the package loader as per our discussion on IRC Repository: rLLDB LLDB CHANGES SINCE LAST ACTION https://reviews.llvm.org/D71825/new/ https://reviews.llvm.org/D71825 Files: lldb/source/Plugins/ScriptIn

[Lldb-commits] [lldb] d44a074 - Save more descriptive error msg from FBS/BKS, relay it up to lldb.

2020-01-08 Thread Jason Molenda via lldb-commits
Author: Jason Molenda Date: 2020-01-08T18:47:35-08:00 New Revision: d44a0743175fc781aa2a23d638d683ded6eb10b8 URL: https://github.com/llvm/llvm-project/commit/d44a0743175fc781aa2a23d638d683ded6eb10b8 DIFF: https://github.com/llvm/llvm-project/commit/d44a0743175fc781aa2a23d638d683ded6eb10b8.diff

[Lldb-commits] [lldb] a63af91 - [lldb] Remove various dead Compare functions

2020-01-08 Thread Alex Langford via lldb-commits
Author: Alex Langford Date: 2020-01-08T18:05:33-08:00 New Revision: a63af915288ad9d1049d486833fcd085b620dc6d URL: https://github.com/llvm/llvm-project/commit/a63af915288ad9d1049d486833fcd085b620dc6d DIFF: https://github.com/llvm/llvm-project/commit/a63af915288ad9d1049d486833fcd085b620dc6d.diff

Re: [Lldb-commits] [PATCH] D72391: [lldb] Add a display name to ClangASTContext instances

2020-01-08 Thread Jim Ingham via lldb-commits
I think we should keep the pointer. You can easily cast the pointer & call functions on it in the expression parser. So if you have the log streaming as you are debugging and you see a log message that seems interesting, you can interrupt lldb and access the relevant context without having to

[Lldb-commits] [PATCH] D72391: [lldb] Add a display name to ClangASTContext instances

2020-01-08 Thread Greg Clayton via Phabricator via lldb-commits
clayborg added a comment. I don't mess with the expression parser all that much, but do we still want to see the pointer value in the log output? current: CompleteTagDecl[2] on (ASTContext*)0x7ff31f01d240 Completing (TagDecl*)0x7ff31f01d568 named DeclName1 Should the new one be CompleteT

[Lldb-commits] [PATCH] D72086: [lldb] Fix that SBThread.GetStopDescription is returning strings with uninitialized memory at the end.

2020-01-08 Thread Greg Clayton via Phabricator via lldb-commits
clayborg added inline comments. Comment at: lldb/scripts/Python/python-typemaps.swig:124 } else { - llvm::StringRef ref(static_cast($1), result); + llvm::StringRef ref = static_cast($1); PythonString string(ref); This assignment looks a bit g

[Lldb-commits] [PATCH] D72413: Add missing nullptr checks.

2020-01-08 Thread Adrian Prantl via Phabricator via lldb-commits
aprantl added a comment. > Do we currently have a way to end up in this state? Not in llvm.org. This was prompted by a swift-lldb-crash where we can end up with no Swift context after a catastrophic error. I believe that in practice the clang runtimes are always available, but the API returns a

[Lldb-commits] [lldb] ae47a3d - [lldb/SWIG] Refactor extensions to be non Python-specific (2/2)

2020-01-08 Thread Jonas Devlieghere via lldb-commits
Author: Jonas Devlieghere Date: 2020-01-08T16:34:09-08:00 New Revision: ae47a3d8107856c84c104f3c2e43a553f4e36748 URL: https://github.com/llvm/llvm-project/commit/ae47a3d8107856c84c104f3c2e43a553f4e36748 DIFF: https://github.com/llvm/llvm-project/commit/ae47a3d8107856c84c104f3c2e43a553f4e36748.d

[Lldb-commits] [PATCH] D72413: Add missing nullptr checks.

2020-01-08 Thread Shafik Yaghmour via Phabricator via lldb-commits
shafik added a reviewer: shafik. shafik added a comment. I am curious what prompted this set of changes, they look sensible but I don't see how we can do anything useful if we end up in this state. Do we currently have a way to end up in this state? CHANGES SINCE LAST ACTION https://reviews.

[Lldb-commits] [PATCH] D72413: Add missing nullptr checks.

2020-01-08 Thread Adrian Prantl via Phabricator via lldb-commits
aprantl added a comment. In D72413#1810969 , @jingham wrote: > If we can't make a persistent expression state, are we going to be able to do > anything useful with expressions? I don't see anything wrong here, but it > seems like we should really be put

[Lldb-commits] [PATCH] D72133: Data formatters: Look through array element typedefs

2020-01-08 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. Ok thanks for clarifying all my points! Looks good. And it would be nice to fix any locations that were canonicalizing types when they shouldn't be in a future patch. CHANGES SINCE LAST

[Lldb-commits] [PATCH] D72413: Add missing nullptr checks.

2020-01-08 Thread Jim Ingham via Phabricator via lldb-commits
jingham added a comment. If we can't make a persistent expression state, are we going to be able to do anything useful with expressions? I don't see anything wrong here, but it seems like we should really be putting up a crunchy frog warning and erroring out of "expr"directly if we really can'

[Lldb-commits] [lldb] 28b9cdd - Delete dead code.

2020-01-08 Thread Adrian Prantl via lldb-commits
Author: Adrian Prantl Date: 2020-01-08T14:32:11-08:00 New Revision: 28b9cdd26073c79be36c79476a9bacceca3d116f URL: https://github.com/llvm/llvm-project/commit/28b9cdd26073c79be36c79476a9bacceca3d116f DIFF: https://github.com/llvm/llvm-project/commit/28b9cdd26073c79be36c79476a9bacceca3d116f.diff

[Lldb-commits] [lldb] edadb81 - [lldb/CMake] Only auto-enable Lua when SWIG is found

2020-01-08 Thread Jonas Devlieghere via lldb-commits
Author: Jonas Devlieghere Date: 2020-01-08T14:02:47-08:00 New Revision: edadb818e5be005fa4397b7e4bd5e397ddb4f5d6 URL: https://github.com/llvm/llvm-project/commit/edadb818e5be005fa4397b7e4bd5e397ddb4f5d6 DIFF: https://github.com/llvm/llvm-project/commit/edadb818e5be005fa4397b7e4bd5e397ddb4f5d6.d

[Lldb-commits] [PATCH] D72413: Add missing nullptr checks.

2020-01-08 Thread Davide Italiano via Phabricator via lldb-commits
davide added a comment. Raphael and Jim should look at the expression evaluator bits. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72413/new/ https://reviews.llvm.org/D72413 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https:/

[Lldb-commits] [PATCH] D72413: Add missing nullptr checks.

2020-01-08 Thread Adrian Prantl via Phabricator via lldb-commits
aprantl created this revision. aprantl added reviewers: JDevlieghere, jingham. GetPersistentExpressionStateForLanguage() can return a nullptr if it cannot construct a typesystem. This patch adds missing nullptr checks at all uses. Inspired by rdar://problem/58317195 https://reviews.llvm.org/D7

[Lldb-commits] [PATCH] D72377: [ldlb/SWIG] Refactor extensions to be non Python-specific.

2020-01-08 Thread Jonas Devlieghere via Phabricator via lldb-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG0341c11e0850: [lldb/SWIG] Refactor extensions to be non Python-specific (authored by JDevlieghere). Changed prior to commit: https://reviews.llvm.org/D72377?vs=236861&id=236898#toc Repository: rG LLV

[Lldb-commits] [lldb] 0341c11 - [lldb/SWIG] Refactor extensions to be non Python-specific

2020-01-08 Thread Jonas Devlieghere via lldb-commits
Author: Jonas Devlieghere Date: 2020-01-08T13:37:07-08:00 New Revision: 0341c11e08504acef8c16ab07210bc253dadf2d9 URL: https://github.com/llvm/llvm-project/commit/0341c11e08504acef8c16ab07210bc253dadf2d9 DIFF: https://github.com/llvm/llvm-project/commit/0341c11e08504acef8c16ab07210bc253dadf2d9.d

[Lldb-commits] [PATCH] D69119: Modernize the rest of the Find.* API (NFC)

2020-01-08 Thread Ted Woodward via Phabricator via lldb-commits
ted added a comment. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69119/new/ https://reviews.llvm.org/D69119 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mail

[Lldb-commits] [PATCH] D71372: [lldb] Add additional validation on return address in 'thread step-out'

2020-01-08 Thread Ted Woodward via Phabricator via lldb-commits
ted added a comment. I've got another failure case for this. If the remote gdbserver doesn't implement qMemoryRegionInfo or qXfer:memory-map:read, thread step-out will fail. error: Could not create return address breakpoint. Return address (0x5bc0) permissions not found. That comes from this c

[Lldb-commits] [PATCH] D72377: [ldlb/SWIG] Refactor extensions to be non Python-specific.

2020-01-08 Thread Pavel Labath via Phabricator via lldb-commits
labath accepted this revision. labath added a comment. This revision is now accepted and ready to land. cool Comment at: lldb/scripts/interface/SBTarget.i:1085-1086 } // namespace lldb + + delete? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72377/n

[Lldb-commits] [PATCH] D71575: [LLDB] Add ObjectFileWasm plugin for WebAssembly debugging

2020-01-08 Thread Paolo Severini via Phabricator via lldb-commits
paolosev updated this revision to Diff 236868. paolosev marked 20 inline comments as done. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D71575/new/ https://reviews.llvm.org/D71575 Files: lldb/include/lldb/Utility/ArchSpec.h lldb/include/lldb/Uti

[Lldb-commits] [PATCH] D71575: [LLDB] Add ObjectFileWasm plugin for WebAssembly debugging

2020-01-08 Thread Paolo Severini via Phabricator via lldb-commits
paolosev added inline comments. Comment at: lldb/source/Plugins/ObjectFile/wasm/ObjectFileWasm.cpp:49 + lldb::offset_t initial_offset = *offset_ptr; + uint64_t value = section_header_data.GetULEB128(offset_ptr); + if (*offset_ptr == initial_offset || value > 127) -

[Lldb-commits] [PATCH] D72377: [ldlb/SWIG] Refactor extensions to be non Python-specific.

2020-01-08 Thread Jonas Devlieghere via Phabricator via lldb-commits
JDevlieghere updated this revision to Diff 236861. JDevlieghere added a comment. - Use `std::string` - Move extension into the corresponding interface file CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72377/new/ https://reviews.llvm.org/D72377 Files: lldb/scripts/Python/python-exten

[Lldb-commits] [PATCH] D71825: [lldb/Lua] Support loading Lua modules.

2020-01-08 Thread Jonas Devlieghere via Phabricator via lldb-commits
JDevlieghere updated this revision to Diff 236853. JDevlieghere added a comment. - Use `?.lua` to import modules - Use Lua runtime to quote strings CHANGES SINCE LAST ACTION https://reviews.llvm.org/D71825/new/ https://reviews.llvm.org/D71825 Files: lldb/source/Plugins/ScriptInterpreter/Lu

[Lldb-commits] [PATCH] D72190: Removing C-style casts in favor of explict C++ style casts

2020-01-08 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor added inline comments. Comment at: lldb/include/lldb/Expression/IRExecutionUnit.h:330 - static const unsigned eSectionIDInvalid = (unsigned)-1; Do we even need this cast? Neither Clang nor GCC complain about `unsigned X = -1` for me. CHANGES SIN

[Lldb-commits] [PATCH] D71825: [lldb/Lua] Support loading Lua modules.

2020-01-08 Thread Jonas Devlieghere via Phabricator via lldb-commits
JDevlieghere planned changes to this revision. JDevlieghere marked an inline comment as done. JDevlieghere added a comment. In D71825#1809825 , @labath wrote: > I think this needs more discussion. The current method of appending to > `package.path` seems

[Lldb-commits] [PATCH] D71801: [lldb/Lua] Make lldb.debugger et al available to Lua

2020-01-08 Thread Jonas Devlieghere via Phabricator via lldb-commits
JDevlieghere updated this revision to Diff 236846. JDevlieghere marked an inline comment as done. JDevlieghere added a comment. Feedback Pavel CHANGES SINCE LAST ACTION https://reviews.llvm.org/D71801/new/ https://reviews.llvm.org/D71801 Files: lldb/source/Plugins/ScriptInterpreter/Lua/Lua

[Lldb-commits] [PATCH] D71801: [lldb/Lua] Make lldb.debugger et al available to Lua

2020-01-08 Thread Jonas Devlieghere via Phabricator via lldb-commits
JDevlieghere updated this revision to Diff 236845. JDevlieghere marked an inline comment as done. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D71801/new/ https://reviews.llvm.org/D71801 Files: lldb/source/Plugins/ScriptInterpreter/Lua/Lua.cpp lldb/source/Plugins/ScriptInterpreter/Lu

[Lldb-commits] [PATCH] D72290: [lldb/CMake] Use LLDB's autodetection logic for libxml2

2020-01-08 Thread Jonas Devlieghere via Phabricator via lldb-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGf8a1065e: [lldb/CMake] Use LLDB's autodetection logic for libxml2 (authored by JDevlieghere). Changed prior to commit: https://reviews.llvm.org/D72290?vs=236721&id=236844#toc Repository: rG LLVM

[Lldb-commits] [lldb] bbbbf8a - [lldb/CMake] Use LLDB's autodetection logic for libxml2

2020-01-08 Thread Jonas Devlieghere via lldb-commits
Author: Jonas Devlieghere Date: 2020-01-08T09:03:40-08:00 New Revision: f8a1065e9420e3cc7c958897683e84023075 URL: https://github.com/llvm/llvm-project/commit/f8a1065e9420e3cc7c958897683e84023075 DIFF: https://github.com/llvm/llvm-project/commit/f8a1065e9420e3cc7c958897683e84023075.d

[Lldb-commits] [PATCH] D70846: Expression eval lookup speedup by not returning methods in ManualDWARFIndex::GetFunctions

2020-01-08 Thread Pavel Labath via Phabricator via lldb-commits
labath accepted this revision. labath added a comment. This revision is now accepted and ready to land. This looks fine to me. @shafik, @teemperor, do you have any more comments? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D70846/new/ https://reviews.llvm.org/D70846

[Lldb-commits] [PATCH] D71825: [lldb/Lua] Support loading Lua modules.

2020-01-08 Thread Pavel Labath via Phabricator via lldb-commits
labath requested changes to this revision. labath added a comment. This revision now requires changes to proceed. I think this needs more discussion. The current method of appending to `package.path` seems to be completely broken. `package.path` contains patterns (e.g. `/?.lua;/usr/share/lua/5.1

[Lldb-commits] [PATCH] D72086: [lldb] Fix that SBThread.GetStopDescription is returning strings with uninitialized memory at the end.

2020-01-08 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor updated this revision to Diff 236793. teemperor added a comment. - Remove unintended empty line change. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72086/new/ https://reviews.llvm.org/D72086 Files: lldb/packages/Python/lldbsuite/test/python_api/thread/TestThreadAPI.py l

[Lldb-commits] [PATCH] D72086: [lldb] Fix that SBThread.GetStopDescription is returning strings with uninitialized memory at the end.

2020-01-08 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor marked an inline comment as done. teemperor added inline comments. Comment at: lldb/scripts/Python/python-typemaps.swig:124-125 } else { - llvm::StringRef ref(static_cast($1), result); + const char *cstr = static_cast($1); + llvm::StringRef ref(cstr,

[Lldb-commits] [PATCH] D72391: [lldb] Add a display name to ClangASTContext instances

2020-01-08 Thread Pavel Labath via Phabricator via lldb-commits
labath added a comment. Seems reasonable to me, some other important object already have names (e.g. broadcasters&listeners). Repository: rLLDB LLDB CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72391/new/ https://reviews.llvm.org/D72391 __

[Lldb-commits] [PATCH] D72086: [lldb] Fix that SBThread.GetStopDescription is returning strings with uninitialized memory at the end.

2020-01-08 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor updated this revision to Diff 236790. teemperor marked an inline comment as done. teemperor added a comment. - Simplify swig type map code. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72086/new/ https://reviews.llvm.org/D72086 Files: lldb/packages/Python/lldbsuite/test/py

[Lldb-commits] [PATCH] D71801: [lldb/Lua] Make lldb.debugger et al available to Lua

2020-01-08 Thread Pavel Labath via Phabricator via lldb-commits
labath added inline comments. Comment at: lldb/source/Plugins/ScriptInterpreter/Lua/ScriptInterpreterLua.cpp:46 + m_lua(std::make_unique()) { + llvm::cantFail(GetLua().EnterSession(debugger.GetID())); +} JDevlieghere wrote: > labath wrote: > > I don't thin

[Lldb-commits] [PATCH] D72391: [lldb] Add a display name to ClangASTContext instances

2020-01-08 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor created this revision. teemperor added reviewers: shafik, labath, JDevlieghere, mib. Herald added a project: LLDB. Herald added a subscriber: lldb-commits. teemperor added a comment. I don't know if this needs a unit test where we call the constructor and explicitly check the name is th

[Lldb-commits] [PATCH] D72391: [lldb] Add a display name to ClangASTContext instances

2020-01-08 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor added a comment. I don't know if this needs a unit test where we call the constructor and explicitly check the name is the one we passed in. Let me know if you think this would make sense. Repository: rLLDB LLDB CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72391/new/ htt

[Lldb-commits] [lldb] 518597c - [lldb] Remove default llvm::Triple argument from ClangASTContext constructor

2020-01-08 Thread Raphael Isemann via lldb-commits
Author: Raphael Isemann Date: 2020-01-08T12:05:51+01:00 New Revision: 518597c1737646ea1f087c1fa43109f689adf7a6 URL: https://github.com/llvm/llvm-project/commit/518597c1737646ea1f087c1fa43109f689adf7a6 DIFF: https://github.com/llvm/llvm-project/commit/518597c1737646ea1f087c1fa43109f689adf7a6.dif

[Lldb-commits] [PATCH] D63540: Fix lookup of symbols with the same address range but different binding

2020-01-08 Thread Pavel Labath via Phabricator via lldb-commits
labath added a comment. I think this is pretty close. The two things I'd change are: - make the RangeMap constructor take a `const Compare &` instead of a template pack. The std containers do the same, and I don't see a reason to diverge.. - make Compare operate only on the "data" field of the m

[Lldb-commits] [PATCH] D72290: [lldb/CMake] Use LLDB's autodetection logic for libxml2

2020-01-08 Thread Pavel Labath via Phabricator via lldb-commits
labath accepted this revision. labath added a comment. This revision is now accepted and ready to land. cool CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72290/new/ https://reviews.llvm.org/D72290 ___ lldb-commits mailing list lldb-commits

[Lldb-commits] [PATCH] D72377: [ldlb/SWIG] Refactor extensions to be non Python-specific.

2020-01-08 Thread Pavel Labath via Phabricator via lldb-commits
labath added a comment. I think this is a great direction to move in. If the extensions are written in C(++) then swig can automatically wrap everything we need. I am wondering if we can avoid constifying each string we return this way though... Comment at: lldb/scripts/exte

[Lldb-commits] [PATCH] D63540: Fix lookup of symbols with the same address range but different binding

2020-01-08 Thread Jan Kratochvil via Phabricator via lldb-commits
jankratochvil updated this revision to Diff 236777. jankratochvil added a comment. Found some way. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63540/new/ https://reviews.llvm.org/D63540 Files: lldb/include/lldb/Symbol/Symtab.h lldb/include/l

[Lldb-commits] [lldb] 0a4daff - [lldb][NFC] Remove redundant ClangASTContext constructor that takes ArchSpec

2020-01-08 Thread Raphael Isemann via lldb-commits
Author: Raphael Isemann Date: 2020-01-08T09:35:46+01:00 New Revision: 0a4daff6e26f276dd92e777b597e94e093ae018d URL: https://github.com/llvm/llvm-project/commit/0a4daff6e26f276dd92e777b597e94e093ae018d DIFF: https://github.com/llvm/llvm-project/commit/0a4daff6e26f276dd92e777b597e94e093ae018d.dif