summaryrefslogtreecommitdiffstats
path: root/lldb
Commit message (Collapse)AuthorAgeFilesLines
...
* [lldb/Test] Temporarily skip TestFoundationDisassembly on the ASan bot.Jonas Devlieghere2020-01-061-0/+1
| | | | | This test is timing out on the sanitized bot on GreenDragon. Temporarily disable it to increase the signal-to-noise ration.
* [lldb/CMake] Autodetect Python dependencyJonas Devlieghere2020-01-063-48/+107
| | | | | | | | Python was the last remaining "optional" dependency for LLDB. This moves the code to find Python into FindPythonInterpAndLibs using the same principles as FindCursesAndPanel. Differential revision: https://reviews.llvm.org/D72107
* [lldb] [Process/NetBSD] Remove unused orig_*ax useMichał Górny2020-01-061-5/+0
| | | | | | | orig_*ax logic is Linux-specific, and was never used on NetBSD. In fact, its support seems to be a dead code entirely. Differential Revision: https://reviews.llvm.org/D72195
* [lldb/Command] Add --force option for `watchpoint delete` commandMed Ismail Bennani2020-01-043-39/+94
| | | | | | | | | | | | | | Currently, there is no option to delete all the watchpoint without LLDB asking for a confirmation. Besides making the watchpoint delete command homogeneous with the breakpoint delete command, this option could also become handy to trigger automated watchpoint deletion i.e. using breakpoint actions. rdar://42560586 Differential Revision: https://reviews.llvm.org/D72096 Signed-off-by: Med Ismail Bennani <medismail.bennani@gmail.com>
* [UserExpression] Clean up `return` after `else`.Davide Italiano2020-01-031-4/+3
|
* [lldb/Utility] YAML validation should be orthogonal to packet semantics.Jonas Devlieghere2020-01-031-3/+0
| | | | | | It's not up to YAML to validate the semantics of the GDB remote packet struct. This is especially wrong here as there's nothing that says that the amount of bytes transmitted matches the packet payload size.
* [lldb/Docs] Include the man page on the websiteJonas Devlieghere2020-01-031-4/+5
|
* [lldb/Docs] Include how to generate the man pageJonas Devlieghere2020-01-031-0/+1
|
* [lldb][NFC] Remove forward declaration for non-existent type clang::Action ↵Raphael Isemann2020-01-033-7/+2
| | | | | | | and delete references to it There is no clang::Action anymore so our forward decl for it and the obsolete pointer in the ASTStructExtractor can both go (that code anyway didn't do anything).
* [lldb][NFC] Document TypeSystem and related Compiler* classesRaphael Isemann2020-01-034-12/+64
|
* Revert "[lldb/Command] Add --force option for `watchpoint delete` command"Med Ismail Bennani2020-01-033-119/+19
| | | | This reverts commit 3620e5f28a4d2800fb6c325ec24b3d660e48b9ba.
* [lldb/Python] Remove unused imports (NFC)Jonas Devlieghere2020-01-021-9/+0
|
* [lldb/Python] Remove unused support file (NFC)Jonas Devlieghere2020-01-021-58/+0
|
* [lldb/Command] Add --force option for `watchpoint delete` commandMed Ismail Bennani2020-01-033-19/+119
| | | | | | | | | | | | Currently, there is no option to delete all the watchpoint without LLDB asking for a confirmation. Besides making the watchpoint delete command homogeneous with the breakpoint delete command, this option could also become handy to trigger automated watchpoint deletion i.e. using breakpoint actions. rdar://42560586 Signed-off-by: Med Ismail Bennani <medismail.bennani@gmail.com>
* [lldb/CMake] Print whether an optional dependency was enabled.Jonas Devlieghere2020-01-021-5/+7
| | | | | | Use a status message to convey whether an optional dependency was found or not. With the auto-detection code it's not longer as simple as checking the CMake cache.
* [lldb/CMake] Fix variable naming in FindLibEditJonas Devlieghere2020-01-026-26/+28
| | | | | | | | | | | | The current FOUND_VAR for FindLibEdit is libedit_FOUND but wasn't set by find_package_handle_standard_args. However this isn't valid for the package name. The argument for FOUND_VAR is "libedit_FOUND", but only "LibEdit_FOUND" and "LIBEDIT_FOUND" are valid names. This fixes all the variables set by FindLibEdit to match the desired naming scheme.
* [lldb/CMake] Use PYTHON_LIBRARIES instead of PYTHON_LIBRARYJonas Devlieghere2020-01-023-5/+5
| | | | | | PYTHON_LIBRARIES is the canonical variable set by FindPythonLibs while PYTHON_LIBRARY is an implementation detail. This replaces the uses of the latter with the former.
* build: reduce CMake handling for zlibSaleem Abdulrasool2020-01-022-3/+3
| | | | | | | | | | | | | Rather than handling zlib handling manually, use `find_package` from CMake to find zlib properly. Use this to normalize the `LLVM_ENABLE_ZLIB`, `HAVE_ZLIB`, `HAVE_ZLIB_H`. Furthermore, require zlib if `LLVM_ENABLE_ZLIB` is set to `YES`, which requires the distributor to explicitly select whether zlib is enabled or not. This simplifies the CMake handling and usage in the rest of the tooling. This restores 68a235d07f9e7049c7eb0c8091f37e385327ac28, e6c7ed6d2164a0659fd9f6ee44f1375d301e3cad. The problem with the windows bot is a need for clearing the cache.
* Revert "build: reduce CMake handling for zlib"James Henderson2020-01-022-3/+3
| | | | | | | This reverts commit 68a235d07f9e7049c7eb0c8091f37e385327ac28. This commit broke the clang-x64-windows-msvc build bot and a follow-up commit did not fix it. Reverting to fix the bot.
* [lldb] Fix crash in AccessDeclContextSanity when copying ↵Raphael Isemann2020-01-025-4/+58
| | | | | | | | | | | | | | | | | | | | | | | | FunctionTemplateDecl inside a record. Summary: We currently don't set access specifiers for function template declarations. This seems to be fine as long as the function template is not declared inside any record in which case Clang asserts with the following once we try to query it's access: ``` Assertion failed: (Access != AS_none && "Access specifier is AS_none inside a record decl"), function AccessDeclContextSanity, ``` This patch just marks these function template declarations as public to make Clang happy. Reviewers: shafik, teemperor Reviewed By: teemperor Subscribers: JDevlieghere, lldb-commits Tags: #lldb Differential Revision: https://reviews.llvm.org/D71909
* [lldb][NFC] Remove unused variable in DWARFASTParserClang::ParseSingleMemberRaphael Isemann2020-01-021-1/+0
|
* [lldb][NFC] Create type-safe function for creating a CompilerType from a ↵Raphael Isemann2020-01-027-286/+222
| | | | | | | | | | | | | | | | | | | | | | QualType LLDB frequently converts QualType to CompilerType. This is currently done like this: result = CompilerType(this, qual_type_var.getAsOpaquePtr()) There are a few shortcomings in this current approach: 1. CompilerType's constructor takes a void* pointer so it isn't type safe. 2. We can't add any sanity checks to the CompilerType constructor (e.g. that the type actually belongs to the passed ClangASTContext) without expanding the TypeSystem API. 3. The logic for converting QualType->CompilerType is spread out over all of LLDB so changing it is difficult (e.g., what if we want to just pass the type ptr and not the 1type_ptr | qual_flags1 to CompilerType). This patch adds a `ClangASTContext::GetType` function similar to the other GetTypeForDecl functions that does this conversion in a type safe way. It also adds a sanity check for Tag-based types that the type actually belongs to the current ClangASTContext (Types don't seem to know their ASTContext, so we have to workaround by looking at the decl for the underlying TagDecl. This doesn't cover all types we construct but it's better than no sanity check).
* build: reduce CMake handling for zlibSaleem Abdulrasool2020-01-012-3/+3
| | | | | | | | | Rather than handling zlib handling manually, use `find_package` from CMake to find zlib properly. Use this to normalize the `LLVM_ENABLE_ZLIB`, `HAVE_ZLIB`, `HAVE_ZLIB_H`. Furthermore, require zlib if `LLVM_ENABLE_ZLIB` is set to `YES`, which requires the distributor to explicitly select whether zlib is enabled or not. This simplifies the CMake handling and usage in the rest of the tooling.
* tests: XFAIL/UNSUPPORTED tests on WindowsSaleem Abdulrasool2020-01-015-4/+12
| | | | | | | | | Now that we are building the python bindings on Windows once more, the extended testsuite is running. Mark a few failing tests and skip a few tests which hang. This should at least bring the bot back to green without reverting the Python changes which are an improvement for the build system and enable another ~35% of the test suite which was previously disabled.
* [lldb][NFC] Simplify CompilerType constructors/destructors and fix unused ↵Raphael Isemann2020-01-013-14/+5
| | | | | | | | | variable warning CompilerType has no virtual functions and no statements in its constructors, so we can simplify this code. This also allows Clang to emit unused variable warnings for CompilerType, so I also removed one unused variable that otherwise causes -Werror builds to fail.
* [NFC] Fixes -Wrange-loop-analysis warningsMark de Wever2020-01-013-3/+3
| | | | | | This avoids new warnings due to D68912 adds -Wrange-loop-analysis to -Wall. Differential Revision: https://reviews.llvm.org/D71857
* [lldb][NFC] Make some checks more readable in Variable::PrivateAutoCompleteRaphael Isemann2020-01-011-3/+3
|
* [lldb][NFC] Simplify ClangASTContext::GetTypeForDeclRaphael Isemann2019-12-303-23/+12
| | | | Also removes the GetASTContext call from this code.
* [lldb][NFC] Make integer types functions in ClangASTContext not staticRaphael Isemann2019-12-292-53/+34
| | | | | | These functions need a ClangASTContext instance that we would otherwise recalculate by calling GetASTContext (which is no longer necessary with this patch).
* [lldb][NFC] Delete static versions of ClangASTContext::CreateFunctionTypeRaphael Isemann2019-12-293-37/+17
| | | | We can always call the member function version of this function.
* [lldb][NFC] Remove most GetASTContext calls in AST metadata codeRaphael Isemann2019-12-293-38/+21
|
* [lldb][NFC] Remove GetASTContext call in ClangPersistentVariablesRaphael Isemann2019-12-283-27/+36
| | | | | | | | We try to build a CompilerType from the persistent decls so we need a ClangASTContext. With this patch the ClangPersistentVariables store the associated ClangASTContext of the persistent decls (which is always the scratch ClangASTContext) and no longer call GetASTContext to map back from clang::ASTContext to ClangASTContext.
* [lldb][NFC] Remove GetASTContext call in ClangDeclVendorRaphael Isemann2019-12-285-22/+20
| | | | | | | | Instead of returning NamedDecls and then calling GetASTContext to find back the ClangASTContext we used can just implement the FindDecl variant that returns CompilerDecls (and implement the other function by throwing away the ClangASTContext part of the compiler decl).
* [lldb] Silent random xpass on aarch64-linux buildbotMuhammad Omair Javaid2019-12-271-1/+1
| | | | | | This patch adds skipif decorator to TestWatchLocationWithWatchSet.py. Decorator will trigger for aarch64-linux as this test passes randomly causing buildbot failure.
* [lldb][test] Don't include "test_common.h" in the debug macros testTatyana Krasnukha2019-12-261-0/+3
| | | | | GCC produces incorrect .debug_macro section when "-include" option is used: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93075.
* [lldb] Specify unsigned underlying type for an enumeration explicitlyTatyana Krasnukha2019-12-261-1/+3
| | | | | | | | | | | | | The enumeration EntryType is used as a bit field of DebugMacroEntry: ``` EntryType m_type : 3 ``` Since underlying type of enumeration is implementation-dependent, a signed integer is converted to the 3-bit value by some compilers (MSVC). That's why a DebugMacroEntry instance that was created with EntryType value > 3 (END_FILE or INDIRECT) contains incorrect negative value in its m_type data-member.
* [lldb][NFC] Move lock scope where it should beginTatyana Krasnukha2019-12-261-9/+10
|
* [lldb][NFC] Add "lldb-vscode" to all_categoriesTatyana Krasnukha2019-12-261-0/+1
| | | | Required to make the category manually disableable.
* [lldb][NFC] Simplify if-returnTatyana Krasnukha2019-12-261-3/+1
|
* [lldb][tests] Platform triple can be NoneTatyana Krasnukha2019-12-261-1/+6
| | | | If a remote target is not connected, SBPlatform's GetTriple function returns None.
* [lldb][tests] Posix function strdup requires macro _POSIX_C_SOURCETatyana Krasnukha2019-12-261-0/+2
|
* [lldb][NFC] Use ClangASTContext in AppleObjCRuntime interfacesRaphael Isemann2019-12-265-61/+46
| | | | | | | This code actually needs a ClangASTContext but instead takes a clang::ASTContext and then retrieves the original ClangASTContext via the global map of ClangASTContexts. Let's change it so that it takes a ClangASTContext which is simpler and faster.
* [lldb] Remove some calls to GetASTContextRaphael Isemann2019-12-263-36/+21
| | | | | | | GetASTContext is really expensive to call as it makes use of the global mapping from ASTContext to ClangASTContext. This replaces all calls where we already have the ClangASTContext around and don't need to call GetASTContext again.
* [lldb][NFC] Use StringRef in ↵Raphael Isemann2019-12-253-49/+43
| | | | ClangASTContext::GetBuiltinTypeForDWARFEncodingAndBitSize
* [lldb] Adapt for NetBSD-9.99.30 ptrace(2) API changesKamil Rytarowski2019-12-242-2/+21
| | | | | | | | Switch from PT_LWPINFO to PT_LWPSTATUS/PT_LWPNEXT. Keep compat support for < 9.99.30. No functional change intended.
* test: ensure that we dead-strip in the linkerSaleem Abdulrasool2019-12-241-0/+1
| | | | | `/OPT:REF` is needed for link to dead strip functions, `/Gy` by itself is not sufficient.
* [lldb][NFC] Move ClangASTContext::m_scratch_ast_source_up to the appropriate ↵Raphael Isemann2019-12-242-11/+17
| | | | | | | | | class m_scratch_ast_source_up is only used by ClangASTContextForExpressions so it should also be declared only in that class. Also make all other members of ClangASTContext private and move the initialization code for ClangASTContextForExpressions into the constructor.
* [lldb][NFC] Remove ClangExternalASTSourceCommonRaphael Isemann2019-12-249-142/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | ClangExternalASTSourceCommon's purpose is to store a map from Decl*/Type* to ClangASTMetadata. Usually this data is accessed via the ClangASTContext interface which then grabs the current ExternalASTSource of its ASTContext, tries to cast it to ClangExternalASTSourceCommon and then accesses the metadata map. If the casting fails the setter does nothing and the getter returns a nullptr as if there was no known metadata for a type/decl. This system breaks as soon as any non-LLDB ExternalASTSource is added via a multiplexer to our existing ExternalASTSource (in which case we suddenly loose all out metadata as the casting always fails with an ExternalASTSource that is not inheriting from ClangExternalASTSourceCommon). This patch moves the metadata map to the ClangASTContext. This gets rid of all the fragile casting, the requirement that every ExternalASTSource in LLDB has to inherit from ClangExternalASTSourceCommon and simplifies the metadata implementation to a simple map lookup. As ClangExternalASTSourceCommon had no other purpose than storing metadata, this patch deletes this class and replaces all uses with clang::ExternalASTSource. No other code changes in this commit beside the AppleObjCDeclVendor which was the only code that did not use the ClangASTContext interface but directly accessed the ClangExternalASTSourceCommon.
* test: correct flags for WindowsSaleem Abdulrasool2019-12-231-0/+2
| | | | | Adjust the flags for the LLDB test on Windows. This test was previously not running, but after the fix to the python detection, we now run this.
* Revert "[lldb] Don't process symlinks deep inside DWARFUnit"Jonas Devlieghere2019-12-232-12/+20
| | | | | This temporarily reverts commit 3cfb6677b2aa20f782d9bb0f7958e61f5a976c16 because it breaks TestCompDirSymLink.py on macOS.
OpenPOWER on IntegriCloud