| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
Differential Revision: http://reviews.llvm.org/D12252
llvm-svn: 245850
|
|
|
|
|
|
|
|
| |
There might be an underlying race condition here that should be
figured out, but this at least prevents the crash for the time
being and doesn't appear to have any adverse effects.
llvm-svn: 245626
|
|
|
|
| |
llvm-svn: 240157
|
|
|
|
| |
llvm-svn: 239284
|
|
|
|
| |
llvm-svn: 237945
|
|
|
|
|
|
|
| |
Differential Revision: http://reviews.llvm.org/D9801
Reviewed by: Adrian McCarthy
llvm-svn: 237817
|
|
|
|
| |
llvm-svn: 237637
|
|
|
|
| |
llvm-svn: 237415
|
|
|
|
| |
llvm-svn: 237392
|
|
|
|
| |
llvm-svn: 236776
|
|
|
|
| |
llvm-svn: 234007
|
|
|
|
| |
llvm-svn: 234005
|
|
|
|
|
|
|
|
| |
This replaces the home-grown initialization mechanism used before.
Differential Revision: http://reviews.llvm.org/D8760
llvm-svn: 233999
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
There were a couple of real bugs here regarding error checking and
signed/unsigned comparisons, but mostly these were just noise.
There was one class of bugs fixed here which is particularly
annoying, dealing with MSVC's non-standard behavior regarding
the underlying type of enums. See the comment in
lldb-enumerations.h for details. In short, from now on please use
FLAGS_ENUM and FLAGS_ANONYMOUS_ENUM when defining enums which
contain values larger than can fit into a signed integer.
llvm-svn: 233943
|
|
|
|
|
|
|
| |
No functional change here, only deletes unnecessary headers
and moves one function's body from the .h file to the .cpp.
llvm-svn: 231145
|
|
|
|
|
|
|
| |
SWIG doesn't like enum : unsigned. Revert this until I can
fix this in a way that swig likes.
llvm-svn: 230531
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The DebuggerThread was detecting the launch error, but it was
ignored by ProcessWindows::DoLaunch, causing LLDB to wait forever
in the debugger loop.
This fixes the test case that explicitly attempts to launch a
process from a non-existant path.
Patch by Adrian McCarthy
Differential Revision: http://reviews.llvm.org/D7874
llvm-svn: 230523
|
|
|
|
|
|
|
|
|
|
|
| |
Earlier this week I was able to get clang-cl on Windows to be
able to self host. This opened the door to being able to
get a whole new slew of warnings for the Windows build.
This patch fixes all of the warnings, many of which were real
bugs.
llvm-svn: 230522
|
|
|
|
| |
llvm-svn: 226742
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This hooks up the changes necessary to set the trap flag on the
CPU and properly manage the process and thread's resume state
and private state so that the ThreadPlan does its thing.
Stepping still doesn't work as of this change, because there are
some issues with stack frames where it doesn't update the thread's
frame list correctly when it breaks inside of a function, but
I will try to fix that separately.
llvm-svn: 226221
|
|
|
|
| |
llvm-svn: 226054
|
|
|
|
|
|
|
| |
These fix various issues with path handling and disable a few tests
which use features of LLVM which are not yet supported on Windows.
llvm-svn: 226042
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This was causing a race condition where DoDestroy() would acquire
the lock and then initiate a shutdown and then wait for it to
complete. But part of the shutdown involved acquiring the same
lock from a different thread. So the main thread would timeout
waiting for the shutdown to complete and return too soon.
The end result of this is that SBProcess::Kill() was broken on
Windows.
llvm-svn: 225297
|
|
|
|
| |
llvm-svn: 223982
|
|
|
|
| |
llvm-svn: 223812
|
|
|
|
| |
llvm-svn: 223498
|
|
|
|
|
|
|
| |
This causes all deferred breakpoints to be correctly resolved as
the modules that they reside in are loaded.
llvm-svn: 223497
|
|
|
|
|
|
|
|
|
| |
This is a temporary workaround to get deferred breakpoint
resolution working until Bug 21720 is addressed. Even with this
workaround, it will only resolve deferred breakpoints in the
executable module, and not in a shared library.
llvm-svn: 223273
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously if we got a DoDestroy while stopped at a breakpoint, we
would detach and then say the process had exited. This is completely
wrong, as it resulted in the python script incorrectly assuming that
the process had actually exited and trying to delete the image, when
in fact it had done no such thing.
The fix employed here is that when we get a DoDestroy, we do 3 steps:
1) initiate a termination sequence on the process
2) If we were stopped handling an exception of any kind, mask it and
let the program resume, causing the program to see the termination
request and exit on its own.
3) Let the program exit normally, and close all of our handles before
returning control back to DoDestroy.
This fixes Bug 21722 and Bug 21723.
llvm-svn: 223272
|
|
|
|
| |
llvm-svn: 223089
|
|
|
|
| |
llvm-svn: 222776
|
|
|
|
|
|
|
|
|
|
| |
These methods are difficult / impossible to implement in a way
that is semantically equivalent to the expectations set by LLDB
for using them. In the future, we should find an alternative
strategy (for example, i/o redirection) for achieving similar
functionality, and hopefully deprecate these APIs someday.
llvm-svn: 222775
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This implements the skeleton of a RegisterContext for Windows.
In particular, this implements support only for x86 general purpose
registers.
After this patch, LLDB on Windows can perform basic debugging
operations in a single-threaded inferior process (breakpoint,
register inspection, frame select, unwinding, etc).
Differential Revision: http://reviews.llvm.org/D6322
Reviewed by: Greg Clayton
llvm-svn: 222474
|
|
|
|
|
|
|
|
| |
Previously using HostThread::GetNativeThread() required an ugly
cast to most-derived type. This solves the issue by simply returning
the derived type directly.
llvm-svn: 222185
|
|
|
|
|
|
|
|
|
|
|
| |
Previously we were directly updating the thread list and stopping
and restarting the process every time threads were created. With
this patch, we queue up thread launches and thread exits, resolve
these all internally, and only update the threads when we get an
UpdateThreadList call. We now only update the private state on
an actual stop (i.e. breakpoint).
llvm-svn: 222178
|
|
|
|
|
|
|
|
|
|
|
| |
This creates a TargetThreadWindows class and updates the thread
list of the Process with the main thread. Additionally, we
fill out a few more overrides of Process base class methods. We
do not yet update the thread list as threads are created and/or
destroyed, and we do not yet propagate stop reasons to threads as
their states change.
llvm-svn: 222148
|
|
|
|
| |
llvm-svn: 222147
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This sends notifications for module load / unload to the process
plugin, and also manages the state more accurately during the
loading sequence.
Similar work by Virgile Bello was referenced during the
implementation of this patch.
Differential Revision: http://reviews.llvm.org/D6224
llvm-svn: 221807
|
|
|
|
|
|
|
|
|
|
|
| |
Due to a previous multi-threaded design involving message
passing, we used message classes to pass event information
to the delegate. Since the multi-threaded design has gone
away, we simplify this by passing event arguments as direct
function parameters, which is more clear and easier to
understand.
llvm-svn: 221806
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch implements basic support for stopping at breakpoints
and resuming later. While a breakpoint is stopped at, LLDB will
cease to process events in the debug loop, effectively suspending
the process, and then resume later when ProcessWindows::DoResume
is called.
As a side effect, this also correctly handles the loader breakpoint
(i.e. the initial stop) so that LLDB goes through the correct state
sequence during the initial process launch.
llvm-svn: 221642
|
|
|
|
| |
llvm-svn: 221637
|
|
|
|
|
|
|
|
|
|
| |
Originally the idea was that we would queue requests to a master
thread that would dispatch them to other slave threads each
responsible for debugging an individual process. This might make
some scenarios more scalable and responsive, but for now it seems
to be unwarranted complexity for no observable benefit.
llvm-svn: 221561
|
|
|
|
|
|
|
|
|
| |
In the llgs world, ProcessWindows will eventually go away and
we'll implement a different protocol. This patch decouples
ProcessWindows from the core debug loop so that this transition
will not be more difficult than it needs to be.
llvm-svn: 221405
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When processes are launched for debugging on Windows now, LLDB
will detect changes such as DLL loads and unloads, breakpoints,
thread creation and deletion, etc.
These notifications are not yet propagated to LLDB in a way that
LLDB understands what is happening with the process. This only
picks up the notifications from the OS in a way that they can be
sent to LLDB with subsequent patches.
Reviewed by: Scott Graham
Differential Revision: http://reviews.llvm.org/D6037
llvm-svn: 221207
|
|
|
|
| |
llvm-svn: 220574
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This implements Host::LaunchProcess for windows, and in doing so
does some minor refactor to move towards a more modular process
launching design.
The original motivation for this is that launching processes on
windows needs some very windows specific code, which would live
most appropriately in source/Host/windows somewhere. However,
there is already some common code that all platforms use when
launching a process before delegating to the platform specific
stuff, which lives in source/Host/common/Host.cpp which would
be nice to reuse without duplicating.
This commonality has been abstracted into MonitoringProcessLauncher,
a class which abstracts out the notion of launching a process using
an arbitrary algorithm, and then monitoring it for state changes.
The windows specific launching code lives in ProcessLauncherWindows,
and the posix specific launching code lives in ProcessLauncherPosix.
When launching a process MonitoringProcessLauncher is created, and
then an appropriate delegate launcher is created and given to the
MonitoringProcessLauncher.
Reviewed by: Greg Clayton
Differential Revision: http://reviews.llvm.org/D5781
llvm-svn: 219731
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
FileAction was previously a nested class in ProcessLaunchInfo.
This led to some unfortunate style consequences, such as requiring
the AddPosixSpawnFileAction() funciton to be defined in the Target
layer, instead of the more appropriate Host layer. This patch
makes FileAction its own independent class in the Target layer,
and then moves AddPosixSpawnFileAction() into Host as a result.
Differential Revision: http://reviews.llvm.org/D4877
llvm-svn: 215649
|
|
|
|
| |
llvm-svn: 214816
|
|
This patch creates a simple ProcessWindows process plugin.
The only thing it knows how to do currently is create processes.
Differential Revision: http://reviews.llvm.org/D4681
llvm-svn: 214094
|