llvm-project/lldb
Jakob Johnson f6eb089734 [trace][intelpt] Fix multi CPU decoding TSC assertion error
Occasionally the assertion that enforces increasing TSC values in `DecodedThread::NotifyTsc`
would get tripped during large multi CPU trace decoding.
The root cause of this issue was an assumption that all the data of a
PSB will fit within the start,end TSC of the "owning"
`ThreadContinuousExecution`. After investigating, this is not the case
because PSBs can have multiple TSCs.
This diff works around this issue by introducing a TSC upper bound for
each `PSBBlockDecoder`. This fixes the assertion failure by simply
"dropping" the remaining data of PSB whenever the TSC upper bound is
exceeded during decoding.
Future work will do a larger refactor of the multi CPU decoding to
remove the dependencies on this incorrect assumption so that PSB blocks
that span multiple `ThreadContinuousExecutions` are correctly handled.
correctly

Test Plan:

Differential Revision: https://reviews.llvm.org/D136610
2022-10-26 11:37:30 -07:00
..
bindings [lldb] Add matching based on Python callbacks for data formatters. 2022-10-19 12:53:38 -07:00
cmake [lldb] Include gtest in standalone build only if LLDB_INCLUDE_TESTS 2022-10-24 15:51:43 +02:00
docs [LLDB] Correct env vars for Android port selection 2022-10-26 12:31:27 +00:00
examples [lldb] Fixed a number of typos 2022-09-13 10:38:38 -07:00
include/lldb [trace][intel pt] Simple detection of infinite decoding loops 2022-10-25 10:20:49 -07:00
packages/Python/lldbsuite [lldb-vscode] Send Statistics Dump in terminated event 2022-10-25 18:47:29 -07:00
resources
scripts
source [trace][intelpt] Fix multi CPU decoding TSC assertion error 2022-10-26 11:37:30 -07:00
test Revert "[clang] Instantiate alias templates with sugar" 2022-10-26 10:14:21 +02:00
third_party/Python/module [lldb] Remove uses of six module (NFC) 2022-08-11 19:06:15 -07:00
tools [lldb-vscode] Send Statistics Dump in terminated event 2022-10-25 18:47:29 -07:00
unittests [LLDB][RISCV] Add RV64C instruction support for EmulateInstructionRISCV 2022-10-25 19:12:45 +08:00
utils Fix a bug in lldb-dotest that was uncovered by setting no value for dotest_args_str. 2022-08-31 18:00:18 -07:00
.clang-format
.clang-tidy [LLDB] Applying clang-tidy modernize-use-override over LLDB 2022-04-22 13:29:47 -07:00
.gitignore
CMakeLists.txt [lldb] Include gtest in standalone build only if LLDB_INCLUDE_TESTS 2022-10-24 15:51:43 +02:00
CODE_OWNERS.txt [CODE OWNERS] Add wallace as code owner 2022-01-12 12:36:30 -08:00
LICENSE.TXT
use_lldb_suite_root.py