|
Revision tags: llvmorg-20.1.0, llvmorg-20.1.0-rc3, llvmorg-20.1.0-rc2, llvmorg-20.1.0-rc1, llvmorg-21-init, llvmorg-19.1.7, llvmorg-19.1.6, llvmorg-19.1.5, llvmorg-19.1.4, llvmorg-19.1.3, llvmorg-19.1.2, llvmorg-19.1.1, llvmorg-19.1.0, llvmorg-19.1.0-rc4, llvmorg-19.1.0-rc3, llvmorg-19.1.0-rc2, llvmorg-19.1.0-rc1, llvmorg-20-init, llvmorg-18.1.8, llvmorg-18.1.7, llvmorg-18.1.6, llvmorg-18.1.5, llvmorg-18.1.4, llvmorg-18.1.3, llvmorg-18.1.2, llvmorg-18.1.1, llvmorg-18.1.0, llvmorg-18.1.0-rc4, llvmorg-18.1.0-rc3, llvmorg-18.1.0-rc2, llvmorg-18.1.0-rc1, llvmorg-19-init, llvmorg-17.0.6, llvmorg-17.0.5, llvmorg-17.0.4, llvmorg-17.0.3, llvmorg-17.0.2, llvmorg-17.0.1, llvmorg-17.0.0, llvmorg-17.0.0-rc4, llvmorg-17.0.0-rc3, llvmorg-17.0.0-rc2, llvmorg-17.0.0-rc1, llvmorg-18-init, llvmorg-16.0.6, llvmorg-16.0.5, llvmorg-16.0.4, llvmorg-16.0.3, llvmorg-16.0.2, llvmorg-16.0.1, llvmorg-16.0.0, llvmorg-16.0.0-rc4, llvmorg-16.0.0-rc3, llvmorg-16.0.0-rc2, llvmorg-16.0.0-rc1, llvmorg-17-init, llvmorg-15.0.7, llvmorg-15.0.6, llvmorg-15.0.5, llvmorg-15.0.4, llvmorg-15.0.3, llvmorg-15.0.2, llvmorg-15.0.1, llvmorg-15.0.0, llvmorg-15.0.0-rc3, llvmorg-15.0.0-rc2, llvmorg-15.0.0-rc1, llvmorg-16-init |
|
| #
1b4b12a3 |
| 23-Jul-2022 |
Nico Weber <[email protected]> |
Revert "[NFC] Improve FileSpec internal APIs and usage in preparation for adding caching of resolved/absolute." and follow-ups
This reverts commit 9429b67b8e300e638d7828bbcb95585f85c4df4d.
It broke
Revert "[NFC] Improve FileSpec internal APIs and usage in preparation for adding caching of resolved/absolute." and follow-ups
This reverts commit 9429b67b8e300e638d7828bbcb95585f85c4df4d.
It broke the build on Windows, see comments on https://reviews.llvm.org/D130309
It also reverts these follow-ups:
Revert "Fix buildbot breakage after https://reviews.llvm.org/D130309." This reverts commit f959d815f4637890ebbacca379f1c38ab47e4e14.
Revert "Fix buildbot breakage after https://reviews.llvm.org/D130309." This reverts commit 0bbce7a4c2d2bff622bdadd4323f93f5d90e6d24.
Revert "Cache the value for absolute path in FileSpec." This reverts commit dabe877248b85b34878e75d5510339325ee087d0.
show more ...
|
| #
9429b67b |
| 21-Jul-2022 |
Greg Clayton <[email protected]> |
[NFC] Improve FileSpec internal APIs and usage in preparation for adding caching of resolved/absolute.
The FileSpect APIs allow users to modify instance variables directly by getting a non const ref
[NFC] Improve FileSpec internal APIs and usage in preparation for adding caching of resolved/absolute.
The FileSpect APIs allow users to modify instance variables directly by getting a non const reference to the directory and filename instance variables. This makes it impossibly to control all of the times the FileSpec object is modified so we can clear the cache. This patch modifies the APIs of FileSpec so no one can modify the directory or filename directly by adding set accessors and by removing the get accessors that are non const.
Many clients were using FileSpec::GetCString(...) which returned a unique C string from a ConstString'ified version of the result of GetPath() which returned a std::string. This caused many locations to use this convenient function incorrectly and could cause many strings to be added to the constant string pool that didn't need to. Most clients were converted to using FileSpec::GetPath().c_str() when possible. Other clients were modified to use the newly renamed version of this function which returns an actualy ConstString: ConstString FileSpec::GetPathAsConstString(bool denormalize = true) const;
This avoids the issue where people were getting an already uniqued "const char *" that came from a ConstString only to put the "const char *" back into a "ConstString" object. By returning the ConstString instead of a "const char *" clients can be more efficient with the result.
The patch: - Removes the non const GetDirectory() and GetFilename() get accessors - Adds set accessors to replace the above functions: SetDirectory() and SetFilename(). - Adds ClearDirectory() and ClearFilename() to replace usage of the FileSpec::GetDirectory().Clear()/FileSpec::GetFilename().Clear() call sites - Fixed all incorrect usage of FileSpec::GetCString() to use FileSpec::GetPath().c_str() where appropriate, and updated other call sites that wanted a ConstString to use the newly returned ConstString appropriately and efficiently.
Differential Revision: https://reviews.llvm.org/D130309
show more ...
|
| #
3c849d0a |
| 15-Jul-2022 |
Fangrui Song <[email protected]> |
Modernize Optional::{getValueOr,hasValue}
|
| #
b74a01a8 |
| 12-Jul-2022 |
Zequan Wu <[email protected]> |
Reland "[LLDB][NFC] Decouple dwarf location table from DWARFExpression."
This reland 227dffd0b6d78154516ace45f6ed28259c7baa48 and 562c3467a6738aa89203f72fc1d1343e5baadf3c with failed api tests fixed
Reland "[LLDB][NFC] Decouple dwarf location table from DWARFExpression."
This reland 227dffd0b6d78154516ace45f6ed28259c7baa48 and 562c3467a6738aa89203f72fc1d1343e5baadf3c with failed api tests fixed by keeping function base file addres in DWARFExpressionList.
show more ...
|
| #
e4c5bca5 |
| 07-Jul-2022 |
Jonas Devlieghere <[email protected]> |
Revert "[LLDB][NFC] Decouple dwarf location table from DWARFExpression."
This reverts commit 227dffd0b6d78154516ace45f6ed28259c7baa48 and its follow up 562c3467a6738aa89203f72fc1d1343e5baadf3c becau
Revert "[LLDB][NFC] Decouple dwarf location table from DWARFExpression."
This reverts commit 227dffd0b6d78154516ace45f6ed28259c7baa48 and its follow up 562c3467a6738aa89203f72fc1d1343e5baadf3c because it breaks a bunch of tests on GreenDragon:
https://green.lab.llvm.org/green/view/LLDB/job/lldb-cmake/45155/
show more ...
|
|
Revision tags: llvmorg-14.0.6, llvmorg-14.0.5, llvmorg-14.0.4 |
|
| #
227dffd0 |
| 13-May-2022 |
Zequan Wu <[email protected]> |
[LLDB][NFC] Decouple dwarf location table from DWARFExpression.
Differential Revision: https://reviews.llvm.org/D125509
|
| #
5e7ddb0d |
| 23-Jun-2022 |
David Spickett <[email protected]> |
Revert "[LLDB] Handle DIE with DW_AT_low_pc and empty ranges"
This reverts commit 1beededc0e7d86d09cee972f0b9f0030a139cab4.
Due to failures on the Arm/AArch64 build bots: https://lab.llvm.org/build
Revert "[LLDB] Handle DIE with DW_AT_low_pc and empty ranges"
This reverts commit 1beededc0e7d86d09cee972f0b9f0030a139cab4.
Due to failures on the Arm/AArch64 build bots: https://lab.llvm.org/buildbot/#/builders/96/builds/25032
show more ...
|
| #
130167ed |
| 22-Jun-2022 |
Alexander Yermolovich <[email protected]> |
[LLDB] Handle DIE with DW_AT_low_pc and empty ranges
The case comes out of how BOLT handles transformation of DW_AT_low_pc/DW_AT_high_pc into DW_AT_low_pc/DW_AT_high_pc with latter being 0.
Reviewe
[LLDB] Handle DIE with DW_AT_low_pc and empty ranges
The case comes out of how BOLT handles transformation of DW_AT_low_pc/DW_AT_high_pc into DW_AT_low_pc/DW_AT_high_pc with latter being 0.
Reviewed By: clayborg
Differential Revision: https://reviews.llvm.org/D127889
show more ...
|
| #
0916d96d |
| 21-Jun-2022 |
Kazu Hirata <[email protected]> |
Don't use Optional::hasValue (NFC)
|
| #
aa88161b |
| 19-Jun-2022 |
Kazu Hirata <[email protected]> |
[lldb] Use value_or instead of getValueOr (NFC)
|
|
Revision tags: llvmorg-14.0.3, llvmorg-14.0.2 |
|
| #
7b81192d |
| 20-Apr-2022 |
Jeffrey Tan <[email protected]> |
Introduce new symbol on-demand for debug info
This diff introduces a new symbol on-demand which skips loading a module's debug info unless explicitly asked on demand. This provides significant perfo
Introduce new symbol on-demand for debug info
This diff introduces a new symbol on-demand which skips loading a module's debug info unless explicitly asked on demand. This provides significant performance improvement for application with dynamic linking mode which has large number of modules. The feature can be turned on with: "settings set symbols.load-on-demand true"
The feature works by creating a new SymbolFileOnDemand class for each module which wraps the actual SymbolFIle subclass as member variable. By default, most virtual methods on SymbolFileOnDemand are skipped so that it looks like there is no debug info for that module. But once the module's debug info is explicitly requested to be enabled (in the conditions mentioned below) SymbolFileOnDemand will allow all methods to pass through and forward to the actual SymbolFile which would hydrate module's debug info on-demand.
In an internal benchmark, we are seeing more than 95% improvement for a 3000 modules application.
Currently we are providing several ways to on demand hydrate a module's debug info: * Source line breakpoint: matching in supported files * Stack trace: resolving symbol context for an address * Symbolic breakpoint: symbol table match guided promotion * Global variable: symbol table match guided promotion
In all above situations the module's debug info will be on-demand parsed and indexed.
Some follow-ups for this feature: * Add a command that allows users to load debug info explicitly while using a new or existing command when this feature is enabled * Add settings for "never load any of these executables in Symbols On Demand" that takes a list of globs * Add settings for "always load the the debug info for executables in Symbols On Demand" that takes a list of globs * Add a new column in "image list" that shows up by default when Symbols On Demand is enable to show the status for each shlib like "not enabled for this", "debug info off" and "debug info on" (with a single character to short string, not the ones I just typed)
Differential Revision: https://reviews.llvm.org/D121631
show more ...
|
| #
5cbf516c |
| 20-Apr-2022 |
Jeffrey Tan <[email protected]> |
Refactor protected virtual functions from SymbolFile into new SymbolFileCommon class.
This is a preparatory patch for https://reviews.llvm.org/D121631. It refactors protected virtual members of Symb
Refactor protected virtual functions from SymbolFile into new SymbolFileCommon class.
This is a preparatory patch for https://reviews.llvm.org/D121631. It refactors protected virtual members of SymbolFile into a new SymbolFileCommon class per suggestion in: https://reviews.llvm.org/D121631
This will avoid the friendship declaration in that patch.
Differential Revision: https://reviews.llvm.org/D124110
show more ...
|
|
Revision tags: llvmorg-14.0.1 |
|
| #
13a3b0bb |
| 21-Mar-2022 |
Pavel Labath <[email protected]> |
[lldb] Remove usages of case-insensitive c-string functions
They are not portable (which meant we had a hand-rolled implementation for windows), and llvm::StringRef provides equivalent functionality.
|
|
Revision tags: llvmorg-14.0.0, llvmorg-14.0.0-rc4, llvmorg-14.0.0-rc3 |
|
| #
8f6ee17f |
| 03-Mar-2022 |
Pavel Labath <[email protected]> |
[lldb] Warn when we fail to find dwo/dwp files
This ensures that the user is aware that many commands will not work correctly.
We print the warning only once (per module) to avoid spamming the user
[lldb] Warn when we fail to find dwo/dwp files
This ensures that the user is aware that many commands will not work correctly.
We print the warning only once (per module) to avoid spamming the user with potentially thousands of error messages.
Differential Revision: https://reviews.llvm.org/D120892
show more ...
|
| #
ae869d44 |
| 03-Mar-2022 |
Shafik Yaghmour <[email protected]> |
[LLDB] Remove cases of using namespace llvm:: from header file
We have using namespace llvm::dwarf in dwarf.h header globally. Replacing that with a using namespace within lldb_private::dwarf and mo
[LLDB] Remove cases of using namespace llvm:: from header file
We have using namespace llvm::dwarf in dwarf.h header globally. Replacing that with a using namespace within lldb_private::dwarf and moving to a using namespace lldb_private::dwarf in .cpp files and fully qualified names in the few header files.
Differential Revision: https://reviews.llvm.org/D120836
show more ...
|
|
Revision tags: llvmorg-14.0.0-rc2 |
|
| #
15983c28 |
| 16-Feb-2022 |
Zequan Wu <[email protected]> |
[LLDB] Dump valid ranges of variables
This allows `image lookup -a ... -v` to print variables only if the given address is covered by the valid ranges of the variables. Since variables created in dw
[LLDB] Dump valid ranges of variables
This allows `image lookup -a ... -v` to print variables only if the given address is covered by the valid ranges of the variables. Since variables created in dwarf plugin always has empty scope range, print the variable if it has empty scope.
Differential Revision: https://reviews.llvm.org/D119963
show more ...
|
|
Revision tags: llvmorg-14.0.0-rc1 |
|
| #
c34698a8 |
| 03-Feb-2022 |
Pavel Labath <[email protected]> |
[lldb] Rename Logging.h to LLDBLog.h and clean up includes
Most of our code was including Log.h even though that is not where the "lldb" log channel is defined (Log.h defines the generic logging inf
[lldb] Rename Logging.h to LLDBLog.h and clean up includes
Most of our code was including Log.h even though that is not where the "lldb" log channel is defined (Log.h defines the generic logging infrastructure). This worked because Log.h included Logging.h, even though it should.
After the recent refactor, it became impossible the two files include each other in this direction (the opposite inclusion is needed), so this patch removes the workaround that was put in place and cleans up all files to include the right thing. It also renames the file to LLDBLog to better reflect its purpose.
show more ...
|
|
Revision tags: llvmorg-15-init |
|
| #
a007a6d8 |
| 31-Jan-2022 |
Pavel Labath <[email protected]> |
[lldb] Convert "LLDB" log channel to the new API
|
| #
2d75f627 |
| 27-Jan-2022 |
Pavel Labath <[email protected]> |
[lldb] Convert DWARF log to the new API
This also deletes some dead log statements (log initialization commented out).
|
|
Revision tags: llvmorg-13.0.1, llvmorg-13.0.1-rc3 |
|
| #
4f89157b |
| 17-Jan-2022 |
Pavel Labath <[email protected]> |
[lldb] Make StatsDuration thread-safe
std::chrono::duration types are not thread-safe, and they cannot be concurrently updated from multiple threads. Currently, we were doing such a thing (only) in
[lldb] Make StatsDuration thread-safe
std::chrono::duration types are not thread-safe, and they cannot be concurrently updated from multiple threads. Currently, we were doing such a thing (only) in the DWARF indexing code (DWARFUnit::ExtractDIEsRWLocked), but I think it can easily happen that someone else tries to update another statistic like this without bothering to check for thread safety.
This patch changes the StatsDuration type from a simple typedef into a class in its own right. The class stores the duration internally as std::atomic<uint64_t> (so it can be updated atomically), but presents it to its users as the usual chrono type (duration<float>).
Differential Revision: https://reviews.llvm.org/D117474
show more ...
|
|
Revision tags: llvmorg-13.0.1-rc2 |
|
| #
633b0029 |
| 27-Dec-2021 |
PoYao Chang <[email protected]> |
[lldb] Fix PR52702 by fixing bool conversion of Mangled
Remove the Mangled::operator! and Mangled::operator void* where the comments in header and implementation files disagree and replace them with
[lldb] Fix PR52702 by fixing bool conversion of Mangled
Remove the Mangled::operator! and Mangled::operator void* where the comments in header and implementation files disagree and replace them with operator bool.
This fix PR52702 as https://reviews.llvm.org/D106837 used the buggy Mangled::operator! in Symbol::SynthesizeNameIfNeeded. For example, consider the symbol "puts" in a hello world C program:
// Inside Symbol::SynthesizeNameIfNeeded (lldb) p m_mangled (lldb_private::Mangled) $0 = (m_mangled = None, m_demangled = "puts") (lldb) p !m_mangled (bool) $1 = true # should be false!! This leads to Symbol::SynthesizeNameIfNeeded overwriting m_demangled part of Mangled (in this case "puts").
In conclusion, this patch turns callq 0x401030 ; symbol stub for: ___lldb_unnamed_symbol36 back into callq 0x401030 ; symbol stub for: puts .
Differential Revision: https://reviews.llvm.org/D116217
show more ...
|
| #
b2e2eece |
| 09-Dec-2021 |
Lasse Folger <[email protected]> |
[lldb][NFC] clang-format some files as preparation for https://reviews.llvm.org/D114627
Reviewed By: werat
Differential Revision: https://reviews.llvm.org/D115110
|
|
Revision tags: llvmorg-13.0.1-rc1 |
|
| #
7e6df41f |
| 18-Nov-2021 |
Greg Clayton <[email protected]> |
[NFC] Refactor symbol table parsing.
Symbol table parsing has evolved over the years and many plug-ins contained duplicate code in the ObjectFile::GetSymtab() that used to be pure virtual. With this
[NFC] Refactor symbol table parsing.
Symbol table parsing has evolved over the years and many plug-ins contained duplicate code in the ObjectFile::GetSymtab() that used to be pure virtual. With this change, the "Symbtab *ObjectFile::GetSymtab()" is no longer virtual and will end up calling a new "void ObjectFile::ParseSymtab(Symtab &symtab)" pure virtual function to actually do the parsing. This helps centralize the code for parsing the symbol table and allows the ObjectFile base class to do all of the common work, like taking the necessary locks and creating the symbol table object itself. Plug-ins now just need to parse when they are asked to parse as the ParseSymtab function will only get called once.
This is a retry of the original patch https://reviews.llvm.org/D113965 which was reverted. There was a deadlock in the Manual DWARF indexing code during symbol preloading where the module was asked on the main thread to preload its symbols, and this would in turn cause the DWARF manual indexing to use a thread pool to index all of the compile units, and if there were relocations on the debug information sections, these threads could ask the ObjectFile to load section contents, which could cause a call to ObjectFileELF::RelocateSection() which would ask for the symbol table from the module and it would deadlock. We can't lock the module in ObjectFile::GetSymtab(), so the solution I am using is to use a llvm::once_flag to create the symbol table object once and then lock the Symtab object. Since all APIs on the symbol table use this lock, this will prevent anyone from using the symbol table before it is parsed and finalized and will avoid the deadlock I mentioned. ObjectFileELF::GetSymtab() was never locking the module lock before and would put off creating the symbol table until somewhere inside ObjectFileELF::GetSymtab(). Now we create it one time inside of the ObjectFile::GetSymtab() and immediately lock it which should be safe enough. This avoids the deadlocks and still provides safety.
Differential Revision: https://reviews.llvm.org/D114288
show more ...
|
| #
f66b69a3 |
| 23-Nov-2021 |
Tonko Sabolčec <[email protected]> |
[lldb] Fix lookup for global constants in namespaces
LLDB uses mangled name to construct a fully qualified name for global variables. Sometimes DW_TAG_linkage_name attribute is missing from debug in
[lldb] Fix lookup for global constants in namespaces
LLDB uses mangled name to construct a fully qualified name for global variables. Sometimes DW_TAG_linkage_name attribute is missing from debug info, so LLDB has to rely on parent entries to construct the fully qualified name.
Currently, the fallback is handled when the parent DW_TAG is either DW_TAG_compiled_unit or DW_TAG_partial_unit, which may not work well for global constants in namespaces. For example:
namespace ns { const int x = 10; }
may produce the following debug info:
<1><2a>: Abbrev Number: 2 (DW_TAG_namespace) <2b> DW_AT_name : (indirect string, offset: 0x5e): ns <2><2f>: Abbrev Number: 3 (DW_TAG_variable) <30> DW_AT_name : (indirect string, offset: 0x61): x <34> DW_AT_type : <0x3c> <38> DW_AT_decl_file : 1 <39> DW_AT_decl_line : 2 <3a> DW_AT_const_value : 10
Since the fallback didn't handle the case when parent tag is DW_TAG_namespace, LLDB wasn't able to match the variable by its fully qualified name "ns::x". This change fixes this by additional check if the parent is a DW_TAG_namespace.
Reviewed By: werat, clayborg
Differential Revision: https://reviews.llvm.org/D112147
show more ...
|
| #
95af9d88 |
| 17-Nov-2021 |
Quinn Pham <[email protected]> |
[NFC][lldb] Inclusive language: remove instances of master from comments in lldb
[NFC] As part of using inclusive language within the llvm project, this patch replaces master in these comments.
Rev
[NFC][lldb] Inclusive language: remove instances of master from comments in lldb
[NFC] As part of using inclusive language within the llvm project, this patch replaces master in these comments.
Reviewed By: clayborg, JDevlieghere
Differential Revision: https://reviews.llvm.org/D114123
show more ...
|