diff options
author | Pavel Labath <labath@google.com> | 2018-03-26 15:17:58 +0000 |
---|---|---|
committer | Pavel Labath <labath@google.com> | 2018-03-26 15:17:58 +0000 |
commit | 9a652a84b141901b6eb17a5948b0741e0febd141 (patch) | |
tree | 311bb741d67b3b740441f26cecb26e60fc7a0cc2 /lldb/packages/Python/lldbsuite/test/functionalities/disassembly/main.cpp | |
parent | d95020108c48d785b99b08cce423134a8463a95d (diff) | |
download | bcm5719-llvm-9a652a84b141901b6eb17a5948b0741e0febd141.tar.gz bcm5719-llvm-9a652a84b141901b6eb17a5948b0741e0febd141.zip |
Fix TestDisassembleBreakpoint broken by r328488
The first issue was that the test was capturing the "before" disassembly
before launching, and the "after" after. This is a problem because some
of the disassembly will change after we know the load address (e.g. PCs
in call instructions). I fix this by capturing both disassemblies with
the process running.
The second issue was that the refactor in r328488 accidentaly changed
the meaning of the test, as it was no longer disassembling the function
which contained the breakpoint.
While inside, I also modernize the test to use
lldbutil.run_to_source_breakpoint and prevent debug-info replication.
llvm-svn: 328504
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test/functionalities/disassembly/main.cpp')
-rw-r--r-- | lldb/packages/Python/lldbsuite/test/functionalities/disassembly/main.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/disassembly/main.cpp b/lldb/packages/Python/lldbsuite/test/functionalities/disassembly/main.cpp index 93925829ec8..c68e3f1b321 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/disassembly/main.cpp +++ b/lldb/packages/Python/lldbsuite/test/functionalities/disassembly/main.cpp @@ -10,7 +10,7 @@ int sum (int a, int b) { - int result = a + b; + int result = a + b; // Set a breakpoint here return result; } @@ -20,7 +20,7 @@ main(int argc, char const *argv[]) int array[3]; - array[0] = sum (1238, 78392); // Set a breakpoint here + array[0] = sum (1238, 78392); array[1] = sum (379265, 23674); array[2] = sum (872934, 234); |