Revision tags: llvmorg-21-init |
|
#
eb96c8c1 |
| 15-Jan-2025 |
Pavel Labath <pavel@labath.sk> |
[lldb] Implement (SB)Function::GetInstructions for discontinuous functions (#122933)
The main change is to permit the disassembler class to process/store multiple (discontinuous) ranges of addresses
[lldb] Implement (SB)Function::GetInstructions for discontinuous functions (#122933)
The main change is to permit the disassembler class to process/store multiple (discontinuous) ranges of addresses. The result is not ambiguous because each instruction knows its size (in addition to its address), so we can check for discontinuity by looking at whether the next instruction begins where the previous ends.
This patch doesn't handle the "disassemble" CLI command, which uses a more elaborate mechanism for disassembling and printing instructions.
show more ...
|
#
c4fb7180 |
| 15-Jan-2025 |
Greg Clayton <gclayton@fb.com> |
[lldb][NFC] Make the target's SectionLoadList private. (#113278)
Lots of code around LLDB was directly accessing the target's section
load list. This NFC patch makes the section load list private s
[lldb][NFC] Make the target's SectionLoadList private. (#113278)
Lots of code around LLDB was directly accessing the target's section
load list. This NFC patch makes the section load list private so the
Target class can access it, but everyone else now uses accessor
functions. This allows us to control the resolving of addresses and will
allow for functionality in LLDB which can lazily resolve addresses in
JIT plug-ins with a future patch.
show more ...
|
Revision tags: llvmorg-19.1.7, llvmorg-19.1.6, llvmorg-19.1.5, llvmorg-19.1.4 |
|
#
39b2979a |
| 13-Nov-2024 |
Pavel Labath <pavel@labath.sk> |
[lldb] Fix source display for artificial locations (#115876)
When retrieving the location of the function declaration, we were
dropping the file component on the floor, which resulted in an amusing
[lldb] Fix source display for artificial locations (#115876)
When retrieving the location of the function declaration, we were
dropping the file component on the floor, which resulted in an amusingly
confusing situation were we displayed the file containing the
implementation of the function, but used the line number of the
declaration. This patch fixes that.
It required a small refactor Function::GetStartLineSourceLineInfo to
return a SupportFile (instead of just the file spec), which in turn
necessitated changes in a couple of other places as well.
show more ...
|
#
f109517d |
| 12-Nov-2024 |
Jonas Devlieghere <jonas@devlieghere.com> |
[lldb] Support overriding the disassembly CPU & features (#115382)
Add the ability to override the disassembly CPU and CPU features through
a target setting (`target.disassembly-cpu` and
`target.d
[lldb] Support overriding the disassembly CPU & features (#115382)
Add the ability to override the disassembly CPU and CPU features through
a target setting (`target.disassembly-cpu` and
`target.disassembly-features`) and a `disassemble` command option
(`--cpu` and `--features`).
This is especially relevant for architectures like RISC-V which relies
heavily on CPU extensions.
The majority of this patch is plumbing the options through. I recommend
looking at DisassemblerLLVMC and the test for the observable change in
behavior.
show more ...
|
Revision tags: llvmorg-19.1.3, llvmorg-19.1.2, llvmorg-19.1.1, llvmorg-19.1.0, llvmorg-19.1.0-rc4 |
|
#
130eddf7 |
| 30-Aug-2024 |
Jonas Devlieghere <jonas@devlieghere.com> |
[lldb] Deal with SupportFiles in SourceManager (NFC) (#106740)
To support detecting MD5 checksum mismatches, deal with SupportFiles
rather than a plain FileSpecs in the SourceManager.
|
Revision tags: 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 |
|
#
7154a396 |
| 18-Apr-2024 |
Alex Langford <alangford@apple.com> |
[lldb][nfc] Remove unused member Disassembler::m_base_addr (#89289)
This member variable is completely unused. I also don't think it makes a
ton of sense since (1) The "base address" can be obtaine
[lldb][nfc] Remove unused member Disassembler::m_base_addr (#89289)
This member variable is completely unused. I also don't think it makes a
ton of sense since (1) The "base address" can be obtained from the first
Instruction in its InstructionList, and (2) InstructionLists may not be
a series of contiguous instructions (even though they are most of the
time).
show more ...
|
Revision tags: llvmorg-18.1.4, llvmorg-18.1.3 |
|
#
556fe5f2 |
| 21-Mar-2024 |
Jonas Devlieghere <jonas@devlieghere.com> |
[lldb] Reland: Store SupportFile in FileEntry (NFC) (#85892)
This is another step towards supporting DWARF5 checksums and inline
source code in LLDB. This is a reland of #85468 but without the
fun
[lldb] Reland: Store SupportFile in FileEntry (NFC) (#85892)
This is another step towards supporting DWARF5 checksums and inline
source code in LLDB. This is a reland of #85468 but without the
functional change of storing the support file from the line table (yet).
show more ...
|
#
a289f66e |
| 20-Mar-2024 |
Jonas Devlieghere <jonas@devlieghere.com> |
Revert "[lldb] Store SupportFile in FileEntry (NFC)" (#85885)
Reverts llvm/llvm-project#85468 because @slackito reports this broke
stepping in one of their tests [1] and this patch was meant to be
Revert "[lldb] Store SupportFile in FileEntry (NFC)" (#85885)
Reverts llvm/llvm-project#85468 because @slackito reports this broke
stepping in one of their tests [1] and this patch was meant to be NFC.
[1]
https://github.com/llvm/llvm-project/commit/d5a277d309e92b1d3e493da6036cffdf815105b1#commitcomment-139991120
show more ...
|
Revision tags: llvmorg-18.1.2 |
|
#
d5a277d3 |
| 15-Mar-2024 |
Jonas Devlieghere <jonas@devlieghere.com> |
[lldb] Store SupportFile in FileEntry (NFC) (#85468)
This is another step towards supporting DWARF5 checksums and inline
source code in LLDB.
|
Revision tags: 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 |
|
#
933c25e5 |
| 17-Jan-2024 |
Jonas Devlieghere <jonas@devlieghere.com> |
[lldb] Store SupportFile in LineEntry (NFC) (#77999)
Store a SupportFile, rather than a FileSpec, in LineEntry. This commit
works towards having the SourceManageroperate on SupportFiles so that it
[lldb] Store SupportFile in LineEntry (NFC) (#77999)
Store a SupportFile, rather than a FileSpec, in LineEntry. This commit
works towards having the SourceManageroperate on SupportFiles so that it
can (1) validate the Checksum and (2) materialize the content of inline
source information.
show more ...
|
Revision tags: 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 |
|
#
a69f78b0 |
| 01-Sep-2023 |
Jonas Devlieghere <jonas@devlieghere.com> |
[lldb] Add syntax color highlighting for disassembly
Add support for syntax color highlighting disassembly in LLDB. This patch relies on 77d1032516e7, which introduces support for syntax highlightin
[lldb] Add syntax color highlighting for disassembly
Add support for syntax color highlighting disassembly in LLDB. This patch relies on 77d1032516e7, which introduces support for syntax highlighting in MC.
Currently only AArch64 and X86 have color support, but other interested backends can adopt WithColor in their respective MCInstPrinter.
Differential revision: https://reviews.llvm.org/D159164
show more ...
|
Revision tags: llvmorg-17.0.0-rc3, llvmorg-17.0.0-rc2, llvmorg-17.0.0-rc1, llvmorg-18-init |
|
#
1e7101a3 |
| 08-Jul-2023 |
Alex Langford <alangford@apple.com> |
[lldb][NFCI] TestEmulation should take a Stream ref
`Instruction::TestEmulation` takes a `Stream *` and checks it for validity. However, this is unnecessary as we can always ensure that we never pas
[lldb][NFCI] TestEmulation should take a Stream ref
`Instruction::TestEmulation` takes a `Stream *` and checks it for validity. However, this is unnecessary as we can always ensure that we never pass `nullptr` for the `Stream` argument. The only use of `Instruction::TestEmulation` currently is `SBInstruction::TestEmulation` which gets the `Stream` from an `SBStream`, and `SBStream::ref` can return a `Stream &` guaranteed.
Differential Revision: https://reviews.llvm.org/D154757
show more ...
|
Revision tags: llvmorg-16.0.6 |
|
#
aff35b2f |
| 09-Jun-2023 |
Alex Langford <alangford@apple.com> |
[lldb][NFCI] Replace some static ConstStrings with StringLiterals in Disassembler
These should have been replaced in e53e1de57ecc but I missed them because ConstStrings can be implicitly converted t
[lldb][NFCI] Replace some static ConstStrings with StringLiterals in Disassembler
These should have been replaced in e53e1de57ecc but I missed them because ConstStrings can be implicitly converted to llvm::StringRefs.
show more ...
|
Revision tags: llvmorg-16.0.5, llvmorg-16.0.4 |
|
#
f464b7c7 |
| 10-May-2023 |
Alex Langford <alangford@apple.com> |
[lldb] Change definition of DisassemblerCreateInstance
DissassemblerCreateInstance is a function pointer whos return type is `Disassembler *`. But Disassembler::FindPlugin always returns a Disassemb
[lldb] Change definition of DisassemblerCreateInstance
DissassemblerCreateInstance is a function pointer whos return type is `Disassembler *`. But Disassembler::FindPlugin always returns a DisassemblerSP, so there's no reason why we can't just create a DisassemblerSP in the first place.
Differential Revision: https://reviews.llvm.org/D150235
show more ...
|
#
3ebb3363 |
| 15-May-2023 |
Jonas Devlieghere <jonas@devlieghere.com> |
[lldb] Complete OptionValue cleanup (NFC)
Make the `Get.*Value` and `Set.*Value` function private and migrate the last remaining call sites to the new overloaded/templated functions.
|
#
efbd5870 |
| 11-May-2023 |
Dave Lee <davelee.com@gmail.com> |
[lldb] Correct elision of line zero in mixed disassembly
When `disassemble --mixed` is run, do not show source for line zero, as intended.
Differential Revision: https://reviews.llvm.org/D150383
|
Revision tags: llvmorg-16.0.3 |
|
#
ddd9358b |
| 02-May-2023 |
Jonas Devlieghere <jonas@devlieghere.com> |
[lldb] Remove unused will_modify argument (NFC)
Various OptionValue related classes are passing around will_modify but the value is never used. This patch simplifies the interfaces by removing the r
[lldb] Remove unused will_modify argument (NFC)
Various OptionValue related classes are passing around will_modify but the value is never used. This patch simplifies the interfaces by removing the redundant argument.
show more ...
|
#
fdbe7c7f |
| 02-May-2023 |
Jonas Devlieghere <jonas@devlieghere.com> |
[lldb] Refactor OptionValue to return a std::optional (NFC)
Refactor OptionValue to return a std::optional instead of taking a fail value. This allows the caller to handle situations where there's n
[lldb] Refactor OptionValue to return a std::optional (NFC)
Refactor OptionValue to return a std::optional instead of taking a fail value. This allows the caller to handle situations where there's no value, instead of being unable to distinguish between the absence of a value and the value happening the match the fail value. When a fail value is required, std::optional::value_or() provides the same functionality.
show more ...
|
#
e53e1de5 |
| 28-Apr-2023 |
Alex Langford <alangford@apple.com> |
[lldb] Change ObjectValueDictionary to use a StringMap
llvm has a structure for maps where the key's type is a string. Using that also means that the keys for OptionValueDictionary don't stick aroun
[lldb] Change ObjectValueDictionary to use a StringMap
llvm has a structure for maps where the key's type is a string. Using that also means that the keys for OptionValueDictionary don't stick around forever in ConstString's StringPool (even after they are gone).
The only thing we lose here is ordering: iterating over the map where the keys are ConstStrings guarantees that we iterate in alphabetical order. StringMap makes no guarantees about the ordering when you iterate over the entire map.
Differential Revision: https://reviews.llvm.org/D149482
show more ...
|
Revision tags: 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 |
|
#
62c7f035 |
| 07-Feb-2023 |
Archibald Elliott <archibald.elliott@arm.com> |
[NFC][TargetParser] Remove llvm/ADT/Triple.h
I also ran `git clang-format` to get the headers in the right order for the new location, which has changed the order of other headers in two files.
|
Revision tags: llvmorg-16.0.0-rc1, llvmorg-17-init, llvmorg-15.0.7 |
|
#
58e9cc13 |
| 19-Dec-2022 |
Muhammad Omair Javaid <omair.javaid@linaro.org> |
Revert "[lldb] Remove redundant .c_str() and .get() calls"
This reverts commit fbaf48be0ff6fb24b9aa8fe9c2284fe88a8798dd.
This has broken all LLDB buildbots: https://lab.llvm.org/buildbot/#/builders
Revert "[lldb] Remove redundant .c_str() and .get() calls"
This reverts commit fbaf48be0ff6fb24b9aa8fe9c2284fe88a8798dd.
This has broken all LLDB buildbots: https://lab.llvm.org/buildbot/#/builders/68/builds/44990 https://lab.llvm.org/buildbot/#/builders/96/builds/33160
show more ...
|
#
fbaf48be |
| 18-Dec-2022 |
Fangrui Song <i@maskray.me> |
[lldb] Remove redundant .c_str() and .get() calls
Removing .c_str() has a semantics difference, but the use scenarios likely do not matter as we don't have NUL in the strings.
|
Revision tags: llvmorg-15.0.6, llvmorg-15.0.5, llvmorg-15.0.4, llvmorg-15.0.3, working, llvmorg-15.0.2, llvmorg-15.0.1, llvmorg-15.0.0, llvmorg-15.0.0-rc3, llvmorg-15.0.0-rc2 |
|
#
b7c5683f |
| 02-Aug-2022 |
Martin Storsjö <martin@martin.st> |
[lldb] Silence a GCC warning about missing returns after a fully covered switch. NFC.
|
Revision tags: llvmorg-15.0.0-rc1, llvmorg-16-init |
|
#
d36ae495 |
| 26-Jul-2022 |
Jakob Johnson <johnsonjakob99@gmail.com> |
Add string conversion for InstructionControlFlowKind enum
Refactor the string conversion of the `lldb::InstructionControlFlowKind` enum out of `Instruction::Dump` to enable reuse of this logic by th
Add string conversion for InstructionControlFlowKind enum
Refactor the string conversion of the `lldb::InstructionControlFlowKind` enum out of `Instruction::Dump` to enable reuse of this logic by the JSON TraceDumper (to be implemented in separate diff).
Will coordinate the landing of this change with D130320 since there will be a minor merge conflict between these changes.
Test Plan: Run unittests ``` > ninja check-lldb [4/5] Running lldb unit test suite
Testing Time: 10.13s Passed: 1084 ```
Verify '-k' flag's output ``` (lldb) thread trace dump instructions -k thread #1: tid = 1375377 libstdc++.so.6`std::ostream::flush() + 43 7048: 0x00007ffff7b54dab return retq 7047: 0x00007ffff7b54daa other popq %rbx 7046: 0x00007ffff7b54da7 other movq %rbx, %rax 7045: 0x00007ffff7b54da5 cond jump je 0x11adb0 ; <+48> 7044: 0x00007ffff7b54da2 other cmpl $-0x1, %eax libc.so.6`_IO_fflush + 249 7043: 0x00007ffff7161729 return retq 7042: 0x00007ffff7161728 other popq %rbp 7041: 0x00007ffff7161727 other popq %rbx 7040: 0x00007ffff7161725 other movl %edx, %eax 7039: 0x00007ffff7161721 other addq $0x8, %rsp 7038: 0x00007ffff7161709 cond jump je 0x87721 ; <+241> 7037: 0x00007ffff7161707 other decl (%rsi) 7036: 0x00007ffff71616fe cond jump je 0x87707 ; <+215> 7035: 0x00007ffff71616f7 other cmpl $0x0, 0x33de92(%rip) ; __libc_multiple_threads 7034: 0x00007ffff71616ef other movq $0x0, 0x8(%rsi) 7033: 0x00007ffff71616ed cond jump jne 0x87721 ; <+241> 7032: 0x00007ffff71616e9 other subl $0x1, 0x4(%rsi) 7031: 0x00007ffff71616e2 other movq 0x88(%rbx), %rsi 7030: 0x00007ffff71616e0 cond jump jne 0x87721 ; <+241> 7029: 0x00007ffff71616da other testl $0x8000, (%rbx) ; imm = 0x8000 ```
Differential Revision: https://reviews.llvm.org/D130580
show more ...
|
#
0538e543 |
| 26-Jul-2022 |
Walter Erquinigo <wallace@fb.com> |
Move GetControlFlowKind's logic to DisassemblerLLVMC.cpp
This diff move the logic of `GetControlFlowKind()` from Disassembler.cpp to DisassemblerLLVMC.cpp. Here's details: - Actual logic of GetContr
Move GetControlFlowKind's logic to DisassemblerLLVMC.cpp
This diff move the logic of `GetControlFlowKind()` from Disassembler.cpp to DisassemblerLLVMC.cpp. Here's details: - Actual logic of GetControlFlowKind() move to `DisassemblerLLVMC.cpp`, and we can check underlying architecture using `DisassemblerScope` there. - With this change, passing 'triple' to `GetControlFlowKind()` is no more required.
Reviewed By: wallace
Differential Revision: https://reviews.llvm.org/D130320
show more ...
|