1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-22 22:22:11 +02:00
Commit graph

1376 commits

Author SHA1 Message Date
Marc Khouzam
9781f7bfa8 Don't require gdbserver to be present for local tests to pass
The TraceFileTest.java file has three tests which depend on each other.
Inter-dependency between tests is not good.  This commit removes it.

Change-Id: Id910a5cea741c85959679e4b0a6981f603f19d13
2016-03-22 16:16:11 -04:00
Marc Khouzam
c58c554e3a Bug 489777: Remove method returning thread as ints
Method MIThreadListIdsInfo#getThreadIds() has been removed.  MIThreadListIdsInfo#getStrThreadIds() should be used instead.

Change-Id: Id6fb924a96b193012eaae0c8811b386873cd411c
2016-03-20 07:28:52 -05:00
Alvaro Sanchez-Leon
ba6eb9e0f0 Bug 489777 - [API] Replace thread id type from int to String
in preparation for the introduction of thread groups syntax in GDB,
thread id needs to be handled as a String.

Change-Id: I379a92de9755ba0532265519ee70d1e199de811b
2016-03-19 21:03:51 -04:00
Jonah Graham
a56abb4783 Bug 472765: use Strings for backend path in Map Entries
Preserve the user supplied backend path as a string so that it matches
what GDB (backend) later reports as a file name to resolve.

Condensed history:

Traditionally in source mapping container, the backend path was stored
as an IPath and that was used to compare against the debug information
being returned by GDB. This worked well when the platform compiled for
matched the platform run on, but when there was Windows/Linux together
that did not work. So as part of Bug 393791 a workaround was done to try
and use hand crafted MapEntrySourceContainer.createPath() instead of
Path constructor to preserve some of the differences. This solution had
its limitations too as UNC paths still could not be represented, See
open Bug 386675.

Change-Id: I4c8f62114a2c6019dc9d07ce446ac424be8b230c
Signed-off-by: Jonah Graham <jonah@kichwacoders.com>
2016-03-19 19:44:19 -04:00
Marc Khouzam
8d4ea57654 Bug 488950 - Remove "New..." button from 'Connect' dialogue
Change-Id: Ia60e7a9e1e6d211bbe4c137f3ff5f7368ab68e83
2016-03-19 19:38:27 -04:00
Marc Khouzam
11c94f2755 Bug 489683 - Fix typo while changing API
Change-Id: I1e5e5f92564c486e2f14da9a7f3a4e15598ba069
2016-03-19 13:05:12 -04:00
Marc Dumais
c0109d378d Bug 489683 - Change the breakpoint "number" from an int to a String
Change-Id: I33a8ca95f6894c360c95260433945cdf1b529bc3
2016-03-18 22:21:21 -05:00
Alena Laskavaia
1cb7faae95 Support -Dcdt.tests.dsf.gdb.versions=all for gdb tests
Change-Id: I7b0921f3dfc41e75f2f32b270712c0eda7fc96a4
2016-03-18 22:31:20 -04:00
Jonah Graham
25023542e8 Fix version range check in SourceLookupTest
Change-Id: Ief38312449c67073c6a6503f27807b455fa4066c
Signed-off-by: Jonah Graham <jonah@kichwacoders.com>
2016-03-18 22:30:33 -04:00
Marc Dumais
16ed5ea208 Bug 489216 - [memory view] memory space sometimes wrongly set, during
the restoring of memory monitors

Change-Id: Iab8554aef0ca24d2643440f1ba845eb253e29676
2016-03-18 12:43:32 -04:00
Alena Laskavaia
528de33113 Flattening rest of gdb tests
this commit removes and merges rest of gdb tests in favor of using
parametrized tests

Change-Id: I352545c2ea3d76154c8079f8efa9aa5d4a3e0032
2016-03-18 09:39:45 -04:00
Marc Khouzam
e977bb4953 Bug 472765: Add extra sourceLookup test
Change-Id: I98c11a2f4e231d6bc0e0bb53ea1e0b3465c9a976
2016-03-18 06:30:41 -04:00
Marc Khouzam
7856453f30 Bug 488909: Unify services factory classes to extend more easily
From org.eclipse.cdt.debug.gdbjtag.core, constructor
GdbJtagDebugServicesFactory.GdbJtagDebugServicesFactory(String)
has been replaced by
GdbJtagDebugServicesFactory.GdbJtagDebugServicesFactory(String,
ILaunchConfiguration)

From org.eclipse.cdt.dsf.gdb, constructor
GdbDebugServicesFactory.GdbDebugServicesFactory(String)
has been replaced by
GdbDebugServicesFactory.GdbDebugServicesFactory(String,
ILaunchConfiguration)

From org.eclipse.cdt.dsf.gdb, class GdbDebugServicesFactoryNS has been
removed and its logic was merged into class GdbDebugServicesFactory

Change-Id: Ifecba752cfc12da62f1447027b11c0bb1f7c0171
2016-03-17 14:31:45 -04:00
Alena Laskavaia
6aefe76491 gdb catchpoints registers tests cleanup
Change-Id: Ibea6071b9b8e07f63508e177fabf8e60da5c0a08
2016-03-17 09:24:39 -04:00
Jonah Graham
6283890715 Bug 472765: Use gdb's "set substitute-path from to"
Add support for gdb's "set substitute-path from to" by adding a new
service called GDBSourceLookup that uses GDB to perform the path
mapping.

The new GDBSourceLookup service uses the new GdbSourceLookupDirector to
get the set of paths that need mapping using GDB's "set
substitute-path" and the director resolves compilation path differently
so as to leave the GDB backend to handle the local path to compile path
resolution.

The MappingSourceContainer has been enhanced to allow a per mapping
container override of the new behaviour. This is a fallback as the
default behaviour when using GDB is to use "set substitute-path".

The MappingSourceContainerDialog exposes the new option in
MappingSourceContainer as a checkbox at the bottom of the path mapping
dialog in a backend agnostic way.

The new code is tested in methods called "sourceSubstitute*" and
mirror the same tests for the now non-backend handled version
which are "sourceMapping*". Note that
doMappingAndLaunch/doSubstituteAndLaunch have been updated to explicitly
check or uncheck the setIsMappingWithBackendEnabled setting

Change-Id: I122d7c597cd461d8e38c4f82522ccfdf9e51a5ba
Signed-off-by: Jonah Graham <jonah@kichwacoders.com>
2016-03-16 22:30:51 -04:00
Alena Laskavaia
b3f03996de parameterized tests gdb tests
this commit to introduce a test harness that allow
to reduce SIGNIFICALLY duplication of test per gdb version.
Tests is now parameterized with version and type (gdb vs gdbserver).
This commit flattens on of the tests as example rest is still 
using an old way.

Parameters are defined externally now via Java variable like this
 -Dcdt.tests.dsf.gdb.versions=gdb.7.7,gdbserver.7.7,gdb.7.11

Change-Id: I855449afba40e265c542dc5de7a3562548c97e8b
2016-03-16 16:51:17 -04:00
Alena Laskavaia
bb0ba6fd91 Bug 489455 - Add new breakpoint action to run arbitrary debugger command
This is generic support for debugger commands though mi console bridge,
should be not gdb specific (have a simple gdb implementation though)

We add new breakpoint action called "Debugger Command"
Interface allows to enter arbitrary string(s)
This is interpreted by debugger as it see fit
For gdb implementation these are cli commands


Change-Id: I20ca0b8b094c724e1cf8b0691f4f6cab84a3737d
2016-03-16 11:24:20 -04:00
Alena Laskavaia
76c4c117c4 adding repeater to some intermittent tests
Change-Id: Idd1610e9c753951a974e336a65441b752e667e00
2016-03-15 14:32:01 -04:00
Jesper Eskilson
eac2f92bb4 Fixed warnings: do not call MessageFormat#format(...) with String[].
Change-Id: I3da681e323cfeb0c1c07a669183e6d1d18ca6ff6
Signed-off-by: Jesper Eskilson <jesper.eskilson@iar.com>
2016-03-14 13:41:59 -04:00
Alena Laskavaia
2cf32973cc InterimittentRule generic junit rule
Change-Id: I375ed04cb6c44f6c923d048523c008b28883700d
2016-03-14 09:32:00 -04:00
Jonah Graham
ff7f25b94d Bug 484900: Remove Majority of CDI classes
This is the first change to remove CDI from CDT. The CDI model
implementation is removed along with everything that directly
depends upon the implementation.

This commit does not include refactoring or moving classes. The few
insertions are the minimum necessary.

Change-Id: I80274e1a0d77bc7bb00a2afe4babc00c4f7613ae
Signed-off-by: Jonah Graham <jonah@kichwacoders.com>
2016-03-08 19:18:05 -05:00
Marc Khouzam
219cf56e7f Bug 478740: Improve overriding of GDBProcesses service
This also propagates the fix to Bug 487144 to GDB 7.10, which we had
missed.

Change-Id: I1b1819d40a43e6667d2e0a0fdb4045b1a000a086
2016-03-07 07:24:49 -05:00
Marc Khouzam
1f3ff86ea0 Cosmetics
Signed-off-by: Marc Khouzam <marc.khouzam@ericsson.com>
2016-03-06 16:56:01 -05:00
Marc Khouzam
bf52a46a9d Revert "Bug 478740: Improve overriding of GDBProcesses service"
This reverts commit 2cd56f2ca9
Review number: 67852.

It was committed by mistake.

Change-Id: Ic6f567b0230e159eafeb2da3cab4255f7372104b
2016-03-05 06:03:43 -05:00
Marc Khouzam
d47fc9be4e Cosmetics
Signed-off-by: Marc Khouzam <marc.khouzam@ericsson.com>
2016-03-05 06:01:33 -05:00
Marc Khouzam
2cd56f2ca9 Bug 478740: Improve overriding of GDBProcesses service
This also propagates the fix to Bug 487144 to GDB 7.10, which we had
missed.
 
Change-Id: Ic70cc9b5cc304288f81a7e10be4aed7138096e94
2016-03-05 05:38:00 -05:00
Marc Khouzam
4175b5a1a4 Bug 478740: Simplify user-facing terminology
I got some user feedback about some terminology they didn't quite
understand and this patch tries to address the issues by:
- Simplifying the name of the reverse debugging options.
- Simplifying the preference page.

The patch aslo removes un-used strings in plugin.properties.

Change-Id: I1e4487eeda23f81d391ef11ddbe7dd6feba401ec
2016-03-04 09:54:30 -05:00
raddepal
4a54e2269f Bug 488660 - Refresh reverse toggle on console changes with GDB 7.10
The patch implements the event handler which
queries the trace method and triggers the necessary
update in the command handler.

Change-Id: I9c1827deb56dce099b7f455e942d1b6735a80643
Signed-off-by: raddepal <ravitheja.addepally@intel.com>
Signed-off-by: ravitheja.addepally <ravitheja.addepally@intel.com>
2016-03-04 07:26:20 -05:00
Marc Dumais
76dee8f4d1 Bug 487128 - Attaching to process errors not propagated to user
Change-Id: Idfa8808e2d50384d491ac9dbc6492570182880f2
2016-03-03 10:56:47 -05:00
Marc Dumais
a21b4f2331 Bug 488874 - attach dialog sometimes does not appear, because no active
shell is found

Change-Id: I039c90677152efe1611049d11cd9b6102c99f86b
2016-03-03 10:54:36 -05:00
Teodor Madan
f29de7cedd Bug 487682 - refuse process selection for already connected process
- Extend query for already connected process to all sessions for local
session types

Change-Id: I36591ff96d28977b4670700a2a2eb92c34945c7a
Signed-off-by: Teodor Madan <teodor.madan@nxp.com>
2016-03-03 09:51:24 -05:00
Marc Khouzam
4f5cccde8a Cosmetics
Signed-off-by: Marc Khouzam <marc.khouzam@ericsson.com>
2016-02-28 21:25:07 -05:00
Marc Khouzam
21e303d976 Bug 487128: Errors when starting a new process is not propagated to user
This is a follow-up to the work done to show errors when attaching to
processes.  We were also not showing errors when trying to start a new
process using the "Debug new executable..." context menu option of the
debug view.

Change-Id: I9f68410b6d41a28df6f76f63b091a049a38b14e9
2016-02-27 21:16:22 -05:00
Marc Khouzam
c1c656bda8 Cosmetics
Signed-off-by: Marc Khouzam <marc.khouzam@ericsson.com>
2016-02-27 10:43:34 -05:00
Marc Khouzam
e6e50c16fb Cosmetics
Signed-off-by: Marc Khouzam <marc.khouzam@ericsson.com>
2016-02-27 07:46:50 -05:00
Marc Khouzam
231dae5323 Cosmetics
Signed-off-by: Marc Khouzam <marc.khouzam@ericsson.com>
2016-02-25 16:27:16 -05:00
Marc Khouzam
39f31d42a3 Remove unnecessary setting of GDB version for non-stop tests.
Non-stop tests inherit from their all-stop counterpart which already
sets the GDB version.

Change-Id: I7444372971a9a74536745279fddac32842c46c03
2016-02-25 11:18:23 -05:00
raddepal
3be258d79b Bug 478740: Add Switch off tracing option
This patch adds the "Switch Off Tracing" option to 
the select reverse debugging method pull down menu.

Change-Id: Ib184c1f4c1d1db781bea4468bc8c939bd27db27d
Signed-off-by: raddepal <ravitheja.addepally@intel.com>
2016-02-25 09:21:01 -05:00
Marc Khouzam
79e0972413 Add Inferior exit code test
Simple test to verify that the exit code of a process is properly set
for the console to read.

Change-Id: Ib7dca7a86732ad119dd57bb2681120d4a6222e5c
2016-02-25 09:09:25 -05:00
Marc Khouzam
c28c12b353 Create DSF-GDB tests for GDB 7.11
Change-Id: Ib46fc78a9f9167c21898b925b7fe9f614adea289
2016-02-25 09:06:43 -05:00
Marc Khouzam
8c0ea6af0b Update script for GDB 7.11
Change-Id: Ia127aadc5fdf0989b7ac4f213c3596da141a2e79
2016-02-24 16:14:51 -05:00
Jonah Graham
84d92dce1f Bug 472765: Fix occasional exception during test
There was a race condition between commandTimedOutDuringSession
finishing and the next test starting that checked for unterminated
launches (in BaseTestCase removeTeminatedLaunchesBeforeTest).

While commandTimedOutDuringSession did wait for the shutdown to be
received (ICommandControlShutdownDMEvent), that can happen a few ms
before the launch is fully terminated (fLaunch.isTerminated() == true)

Change-Id: Ib4e6655938f6b0e3ab3ce89fd06528f1b72ee04d
Signed-off-by: Jonah Graham <jonah@kichwacoders.com>
2016-02-24 13:19:42 -05:00
Marc Khouzam
9e5888fb37 Bug 478740: Remove Reverse Debug dialog preference
Change-Id: I2a7f668ebc50bac6047395e0ca0e4eb7668cc863
2016-02-23 10:01:04 -05:00
Marc Khouzam
3d65c3474a Missing @since tags
Signed-off-by: Marc Khouzam <marc.khouzam@ericsson.com>
2016-02-22 20:39:59 -05:00
Marc Khouzam
ffffd11890 Bug 456116 - Cannot use class fields in GdbLaunchDelegate
The protected method GdbLaunchDelegate.cleanupLaunch() has been removed.
It has been replaced with GdbLaunchDelegate.cleanupLaunch(ILaunch).

The complexity about not using a class field in GdbLaunchDelegate is that
throughout the process of launching a session, we must be ready to cleanup
the GdbLaunch object.  The problem is that the platform does not provide
that launch object in the methods preLaunchCheck() and finalLaunchCheck(),
so we needed to store the launch object in a field.

This patch delays the call to GdbLaunch.initialize() so that we don't need
to cleanup the launch object if preLaunchCheck() and finalLaunchCheck()
abort the launch.  One hurdle was that we still needed to create the DsfSession
when constructing GdbLaunch, so still needed to clean it up.  This patch adds
a check in GdbLaunch itself, when the launch is removed, to cleanup any
lingering DsfSession automatically.

I've tested every path that aborts the launch in GdbLaunchDelegate and
confirmed that things are properly disposed of in every case.

Change-Id: Ie2981a843917b464f1785a477871073227e027c3
2016-02-22 13:16:07 -05:00
Marc Khouzam
c170288dc4 Bug 478740: Cleanup debugger tab
This patch cleans up the debugger tab and puts the new ReverseMode
dropdown box on the same line as the reverse checkbox.

The patch also decouples the gdb and gdbinit boxes (which require three
columns) from the other options (which require one or two columns).  This
will make modifying options simpler and more versatile.

Change-Id: I11909ed72237128f354dbf05ab3ba1de062aad2f
2016-02-22 09:48:11 -05:00
Marc Khouzam
fa5bc53607 Bug 478740: Re-order constants
Change-Id: I49a584f3f58794718a9eb97c6f8a98fc0b3ca35d
2016-02-19 14:22:51 -05:00
raddepal
5aa4380050 Bug 478740: Changes for supporting Hardware Reverse Debugging
The original toggle button for reverse debugging
has been modified to a pulldown menu for selecting
between hardware and software methods along with all necessary support. 

Change-Id: I2e4d97c46950253986d427cb87cda66b820744c9
Signed-off-by: raddepal <ravitheja.addepally@intel.com>
Signed-off-by: Marc Khouzam <marc.khouzam@ericsson.com>
2016-02-19 10:17:35 -05:00
Marc Khouzam
a3eb9edc59 Remove deprecated medthods.
GDBBackend.getGDBCommandLine() and GDBBackend.launchGDBProcess(String)
have been removed.

GDBBackend.getGDBCommandLineArray() and
GDBBackend.launchGDBProcess(String[]) should be used instead.

Change-Id: I50b118a0dfeef5c427c61ba5a9b38662cbe9748f
2016-02-17 06:19:00 -05:00
Marc Dumais
8ab12fa4e2 Bug 487762 - [tests] MIRegistersTests # frameSpecificValues() - fix
platform-dependent failure

Change-Id: I7bfe1b952ac97615f93ee63770f33b66a5cb9d3e
2016-02-15 10:01:41 -05:00