Change f0e2708 introduced the ability to specify source path mapping
containing regular expressions and used this in the elf reader.
To simplify the code, this change here moves the decision which paths
are considered regular expressions to the user. The other users which
are not aware of the special handling of paths starting with '(' in
the elf reader will interpret them as plain string, which appears to
be the right thing.
Change-Id: I31f10ed866fe7582d44307a923b6db10206acc9a
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
And AttachCrashedExternal to AttachToCrashedProcess
And AttachCore to AttachToCore.
Clearer.
Change-Id: I47c2eca5cbdbbc0eb38b9f62b2504c96558ff112
Reviewed-by: David Schulz <david.schulz@qt.io>
The lines between engine setup and running have always been
blurry, so it looks more and more unnatural to enforce this
in the architecture. Remove the runEngine() call from the
end of notifySetupEngineOk, and do it on the user side.
Change-Id: I3a5e158e8b3fe9b0a288d064f798e24b2ac47f86
Reviewed-by: David Schulz <david.schulz@qt.io>
There's an ICore::raiseWindow() call already for spontaneous stops,
conditioned on boolSetting(RaiseOnInterrupt). This should be sufficient
for normal operation.
Task-number: QTCREATORBUG-12769
Change-Id: I33daad2579f9cfdb8fd121b9c9db73c05f9eccb7
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
... using a context menu on the header views.
Use the feature in the debugger views where it was previously
un-intuitively available as part of the main context menu of
the view, but not in the header.
Task-number: QTCREATORBUG-24384
Change-Id: I3f030c3dd8ce35dc91bad921e37d2273bfe548b5
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Do not change the current editor after hitting a breakpoint if we
already have an editor open in another split, but switch the focus to
that split.
Task-number: QTCREATORBUG-24646
Change-Id: Id85cecdfb522807bafa097e578509853326a2e31
Reviewed-by: hjk <hjk@qt.io>
There are very few reasons to use mainWindow() directly.
Especially for modal dialogs, using dialogParent() is important, since
that guarantees the stacking order in case of other dialogs currently
being open.
Change-Id: I7ad2c23c5034b43195eb35cfe405932a7ea003e6
Reviewed-by: hjk <hjk@qt.io>
Presumably, they were intended for output that shouldn't get an
automatic newline, but if there ever was such a thing as automatic
newlines, it must have evaporated over time. All users of
OutputFormatter provide a newline if they want one.
Change-Id: Ibd219b7305fd503ce075d6f77930d2b538d5e2e8
Reviewed-by: hjk <hjk@qt.io>
If the debugger engine is not running there is anyway no need
to update its data.
Change-Id: I8cda9218985db8b88d96046254847e8916ca37eb
Reviewed-by: hjk <hjk@qt.io>
This patch adds debugger integration from the KEIL uVision IDE:
* http://www2.keil.com/mdk5/uvision/
This IDE has the uVision Socket Interface (UVSC) that allows
to the applications configuration, building and debugging:
* http://www.keil.com/appnotes/docs/apnt_198.asp
Besides, it provides a binary client libraries for Windows, which
are implements some API which we are use in this patch.
Currently implemented the following features:
* Enumeration of a stack frames.
* Enumeration of a threads (tasks).
* Registers view (read/write).
* Local variables view (read/write).
* Watchers view (read/write).
* Disassembler view.
* Current location marker.
* Break-points.
* Step-in.
* Step-over.
* Step-out.
* Step-by-instruction.
* Start/stop/pause/continue debugger.
* Auto-detection for the installed uVision instances (as debuggers).
* Wizard for choosing and configuring of the UVSC debug providers.
At this moment added support only for the 32-bit ARM devices, provided
by the STMicroelectronics:
https://www.st.com/en/microcontrollers-microprocessors/stm32-32-bit-arm-cortex-mcus.html
For this are implemented two debugger providers:
* Simulator - allow to simulate the target device.
* ST-Link v2 - it is a HW debugger.
This implementation tested only with the QBS using the following
target boards:
* NUCLEO-F767ZI (based on STM32F767ZIT6 MCU).
* STM32F4DISCOVERY (based on STM32F407VG MCU).
* STM32F103x (based on STM32F103C8T6 MCU).
A more detailed information about this patch can be found in a
bug-tracker.
Fixes: QTCREATORBUG-23426
Change-Id: Ie36a1f7430b56c33d6665cc35e43fe9bd95d28f1
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
In case of mixed debugging it may happen that the trigger
for add an expression happens on a different debugger
engine than the raise of the watchers window as the
companion engine might have been interrupted and the
current perspective has changed accordingly.
Avoid raising the watchers window for the other engine
in that case.
Fixes: QTCREATORBUG-23545
Change-Id: Ic3472b17c727f1336afd1945b5bc448e75e25b4f
Reviewed-by: hjk <hjk@qt.io>
When debugging a remote machine using ssh, if the ssh connection returns
an error before other workers are fully started, and it will call
destroyPerspective(). Then the other workers will call setState() when
they are in EngineSetupOk and then in EngineRunRequested.
Before calling select() method check if m_perspective is valid.
Fixes: QTCREATORBUG-23415
Change-Id: Ib174015b1d11cdaa5f59e7ccb012b849d49672f1
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Not perfect, e.g. one would probably expect the items to
appear in the context menu of the header views, too, not
just on the main background of the view, but better than
nothing.
Task-number: QTCREATORBUG-23342
Change-Id: Ifdc44dcfd390112faa7b15bb8a51d809e42d7b29
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
When switching between interrupted and continue while
debugging the stack was not updated when the engine
states it is running again, but immediately did so
when clicking into the stack view.
Fix by explicitly updating the stack when the engine
reports it is running.
Change-Id: Ie8cb445e87fe6e45f9ae86b8ee2eec386be78a5c
Reviewed-by: hjk <hjk@qt.io>
When adding a new expression automatically raise the
Expressions widget if it is not shown already.
Change-Id: If89e4e4fbf8cbe57e0f08478cd2d3b9f4797f5ad
Reviewed-by: hjk <hjk@qt.io>
A bit closer to where the functions are used. No real change.
Change-Id: Icbad68bd31d85caa59980316537ee532faf2d7ef
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This feature is useful for the bare-metal programming. It allows
to view the peripheral registers of the debugged device using
the GDB.
An information about the peripheral registers for a concrete
device contains in a special SVD file. A format of this file
described e.g. here:
* https://www.keil.com/pack/doc/CMSIS/SVD/html/svd_Format_pg.html
This feature supported only for ARM devices, and an appropriate
SVD files can be found in the Internet, also this files provides
by KEIL or IAR EW IDE's.
A use case in QtC is that the user should to choose desired SVD
file and set its path to the bare-metal device configuration widget.
After this, the user can enable the "Peripheral Registers" view,
choose a desired register group and to see a peripheral register
values.
Currently the following basic features are implemented:
* Choosing SVD file for a target bare-metal device.
* Choosing any peripheral register group, which is available for
this device.
* Seeing the info about the each peripheral register and its fields.
* Seeing the value for the each peripheral register and its fields.
* Changing the value for the each peripheral register and its fields
(if it is allowed by access for a concrete register or field).
* Changing the format of the values (hexadecimal, decimal, octal,
binary).
Fixes: QTCREATORBUG-18729
Change-Id: I3c38ea50ccd2e128746458f9b918095b4c2d644a
Reviewed-by: hjk <hjk@qt.io>
Remove uses of foreach, ...
Change-Id: I3997d4dffc63d58c386c70b08063ecb894ef1abb
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
For some reason, Q_UNUSED includes already a semicolon, adding one
on the user side creates an additional empty statement.
Change-Id: I9c5e8fac381345a60792cb75e2938fd53958d3b0
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Only append the ".exe" suffix if the the symbol file cannot be
found. Otherwise, this shows an unnecessary warning if an existing
and valid executable file like *.bat or *.cmd is passed.
Change-Id: I129c89deee9d63aefecc84d489ee08e81eaa11ab
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Reviewed-by: David Schulz <david.schulz@qt.io>
This level is meant to take the role of current thread handler
in the long run, allowing per-thread stackviews in each engine.
For now, the additional level holds just a single, invisible
dummy item playing the role of a "current thread".
Change-Id: Ief6131500fc1aa8902f2313038a65840b80b495b
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
More in line with QFileInfo terminonlogy which appears to be
best-of-breed within Qt.
Change-Id: I1d051ff1c8363ebd4ee56376451df45216c4c9ab
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>