summaryrefslogtreecommitdiffstats
path: root/lldb/packages/Python/lldbsuite/test/functionalities/reproducer/gdb-remote
diff options
context:
space:
mode:
authorJonas Devlieghere <jonas@devlieghere.com>2018-12-03 17:28:29 +0000
committerJonas Devlieghere <jonas@devlieghere.com>2018-12-03 17:28:29 +0000
commit15eacd741faa5ec75ef55d82db3486cbaf91f46f (patch)
tree4daa8934087c40d450d390c3fbee9c3b28b36bed /lldb/packages/Python/lldbsuite/test/functionalities/reproducer/gdb-remote
parent8918a511a1a53cc568b248428fb75c39b1949001 (diff)
downloadbcm5719-llvm-15eacd741faa5ec75ef55d82db3486cbaf91f46f.tar.gz
bcm5719-llvm-15eacd741faa5ec75ef55d82db3486cbaf91f46f.zip
[Reproducers] Change how reproducers are initialized.
This patch changes the way the reproducer is initialized. Rather than making changes at run time we now do everything at initialization time. To make this happen we had to introduce initializer options and their SB variant. This allows us to tell the initializer that we're running in reproducer capture/replay mode. Because of this change we also had to alter our testing strategy. We cannot reinitialize LLDB when using the dotest infrastructure. Instead we use lit and invoke two instances of the driver. Another consequence is that we can no longer enable capture or replay through commands. This was bound to go away form the beginning, but I had something in mind where you could enable/disable specific providers. However this seems like it adds very little value right now so the corresponding commands were removed. Finally this change also means you now have to control this through the driver, for which I replaced --reproducer with --capture and --replay to differentiate between the two modes. Differential revision: https://reviews.llvm.org/D55038 llvm-svn: 348152
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test/functionalities/reproducer/gdb-remote')
-rw-r--r--lldb/packages/Python/lldbsuite/test/functionalities/reproducer/gdb-remote/Makefile5
-rw-r--r--lldb/packages/Python/lldbsuite/test/functionalities/reproducer/gdb-remote/TestGdbRemoteReproducer.py49
2 files changed, 0 insertions, 54 deletions
diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/reproducer/gdb-remote/Makefile b/lldb/packages/Python/lldbsuite/test/functionalities/reproducer/gdb-remote/Makefile
deleted file mode 100644
index b09a579159d..00000000000
--- a/lldb/packages/Python/lldbsuite/test/functionalities/reproducer/gdb-remote/Makefile
+++ /dev/null
@@ -1,5 +0,0 @@
-LEVEL = ../../../make
-
-C_SOURCES := main.c
-
-include $(LEVEL)/Makefile.rules
diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/reproducer/gdb-remote/TestGdbRemoteReproducer.py b/lldb/packages/Python/lldbsuite/test/functionalities/reproducer/gdb-remote/TestGdbRemoteReproducer.py
deleted file mode 100644
index adbbd1be645..00000000000
--- a/lldb/packages/Python/lldbsuite/test/functionalities/reproducer/gdb-remote/TestGdbRemoteReproducer.py
+++ /dev/null
@@ -1,49 +0,0 @@
-"""
-Test the GDB remote reproducer.
-"""
-
-from __future__ import print_function
-
-import os
-import lldb
-from lldbsuite.test.decorators import *
-from lldbsuite.test.lldbtest import *
-from lldbsuite.test import lldbutil
-
-
-class TestGdbRemoteReproducer(TestBase):
-
- mydir = TestBase.compute_mydir(__file__)
- NO_DEBUG_INFO_TESTCASE = True
-
- def test(self):
- """Test record and replay of gdb-remote packets."""
- self.build()
-
- # Create temp directory for the reproducer.
- exe = self.getBuildArtifact("a.out")
-
- # First capture a regular debugging session.
- self.runCmd("reproducer capture enable")
-
- reproducer_path = self.dbg.GetReproducerPath()
-
- self.runCmd("file {}".format(exe))
- self.runCmd("breakpoint set -f main.c -l 13")
- self.runCmd("run")
- self.runCmd("bt")
- self.runCmd("cont")
-
- # Generate the reproducer and stop capturing.
- self.runCmd("reproducer generate")
- self.runCmd("reproducer capture disable")
-
- # Replay the session from the reproducer.
- self.runCmd("reproducer replay {}".format(reproducer_path))
-
- # We have to issue the same commands.
- self.runCmd("file {}".format(exe))
- self.runCmd("breakpoint set -f main.c -l 13")
- self.runCmd("run")
- self.runCmd("bt")
- self.expect("cont")
OpenPOWER on IntegriCloud