Johnny Chen
f5fe34ff9c
Remove extra whitespace.
...
llvm-svn: 132692
2011-06-06 21:36:56 +00:00
Greg Clayton
a658fd26c3
Created a std::string in the base StopInfo class for the description and
...
cleaned up all base classes that had their own copy. Added a SetDescription
accessor to the StopInfo class.
llvm-svn: 132615
2011-06-04 01:26:29 +00:00
Greg Clayton
54e8ac5562
Make sure we are ok to stop in a thread plan and have no stop reason for
...
the thread we were running on (other thread crashed or had exceptional stop
reason).
llvm-svn: 132599
2011-06-03 22:12:42 +00:00
Greg Clayton
3b292a1ed3
Don't codesign with lldb_codesign for non MacOSX SDKs.
...
llvm-svn: 132597
2011-06-03 22:08:56 +00:00
Johnny Chen
c95f5de211
Add InferiorCallPOSIX.cpp/.h into the xcode project file to fix build error.
...
llvm-svn: 132594
2011-06-03 21:27:28 +00:00
Peter Collingbourne
6b5f17a586
Fix some order-of-initialisation warnings
...
llvm-svn: 132588
2011-06-03 20:41:09 +00:00
Peter Collingbourne
10bc01032c
Implement RegisterContextLinux_x86_64::{Read,Write}AllRegisterValues
...
llvm-svn: 132587
2011-06-03 20:41:02 +00:00
Peter Collingbourne
5a6fa540dc
Move SaveFrameZeroState and RestoreSaveFrameZero implementations to Thread base class
...
llvm-svn: 132586
2011-06-03 20:40:54 +00:00
Peter Collingbourne
70969ef102
Implement ProcessLinux::Do{Allocate,Deallocate}Memory using inferior mmap/munmap calls
...
llvm-svn: 132585
2011-06-03 20:40:44 +00:00
Peter Collingbourne
99f9aa02c2
Move inferior mmap/munmap call code into their own functions in utility lib
...
llvm-svn: 132584
2011-06-03 20:40:38 +00:00
Peter Collingbourne
1740be7cd9
Disable MCJIT on non-Darwin platforms
...
Currently the runtime dynamic linker lacks object file support for anything
other than Mach-O.
llvm-svn: 132583
2011-06-03 20:40:12 +00:00
Peter Collingbourne
b4aabeb8d7
Scan dynamic symbol table of ELF object files
...
llvm-svn: 132582
2011-06-03 20:39:58 +00:00
Caroline Tice
cbc0c247e1
Make a few minor changes/corrections to scripting
...
example on the web.
llvm-svn: 132554
2011-06-03 16:38:17 +00:00
Jim Ingham
5b52f0c785
Added Debugger::GetAsync{Output/Error}Stream, and use it to print parse errors when we go to run a breakpoint condition.
...
llvm-svn: 132517
2011-06-02 23:58:26 +00:00
Greg Clayton
cbd2e3b001
Cleanup the sidebar and include a link to the new python scripting tutorial.
...
llvm-svn: 132515
2011-06-02 23:50:04 +00:00
Caroline Tice
54923eced3
Add the web page for the 'Using Python Scripting to
...
Debug a Program in LLDB' example.
llvm-svn: 132513
2011-06-02 23:40:56 +00:00
Caroline Tice
2e9dd93e26
Add source files for Python scripting example (coming soon).
...
llvm-svn: 132512
2011-06-02 23:23:47 +00:00
Johnny Chen
b1fa6b466b
Bail out if we have an invalid thumb instruction.
...
llvm-svn: 132511
2011-06-02 23:19:06 +00:00
Johnny Chen
8a71c0b771
Turn the commented-out assert()'s into appropriate bail-out actions.
...
llvm-svn: 132507
2011-06-02 23:07:03 +00:00
Johnny Chen
6ef2735631
When emulating an ill-formed instruction, we should bail out instead of asserting and bringing down the whole process.
...
llvm-svn: 132506
2011-06-02 22:50:51 +00:00
Greg Clayton
79884f3896
Bumped Xcode project version for lldb-60.
...
llvm-svn: 132502
2011-06-02 22:25:27 +00:00
Greg Clayton
850cc8998c
Remove asserts that will crash LLDB. These should be changed to return
...
true/false in an extra boolean parameter and not cause the the binary that
us using the LLDB framework to crash.
llvm-svn: 132501
2011-06-02 22:23:35 +00:00
Greg Clayton
dd0e5a5258
Make sure we don't lose our stop reply packet in the case where the other
...
GDB server doesn't support the LLDB specific qThreadStopInfo packet.
llvm-svn: 132499
2011-06-02 22:22:38 +00:00
Greg Clayton
8672996e4d
Update the handle many of the packets that our current LLDB debugserver
...
handles. Also fixed a case where the packet wouldn't be dumped if it returned
the unimplemented packet.
llvm-svn: 132498
2011-06-02 22:21:38 +00:00
Caroline Tice
c928f59c90
Use Py_InitializeEx(0) instead of Py_Initialize,
...
to prevent Python from installing its own signal
handlers.
llvm-svn: 132492
2011-06-02 22:09:43 +00:00
Johnny Chen
8a742f5f37
EmulateShiftReg() also accepts shifter type of SRType_ROR.
...
llvm-svn: 132484
2011-06-02 21:00:34 +00:00
Caroline Tice
d5a0a01b2d
Create new class, InputReaderStack, to better handle
...
mutexes around input readers and prevent deadlocking; modify
Debugger to use the new class.
llvm-svn: 132475
2011-06-02 19:18:55 +00:00
Johnny Chen
b5964212f4
Add comment about Thread::GetStatus(), which returns the number of frames shown.
...
llvm-svn: 132470
2011-06-02 18:02:15 +00:00
Greg Clayton
a13ad2adcf
Use the correct accessor on CXXRecordDecl to know when a C++ class is dynamic.
...
llvm-svn: 132449
2011-06-02 01:26:44 +00:00
Johnny Chen
f7626eff37
Turn off printing of command sent to the pexpect-spawned child process to make the script more robotic.
...
llvm-svn: 132441
2011-06-01 23:53:57 +00:00
Jim Ingham
190b959273
If somebody has deleted the breakpoint while we are testing the condition, then just continue.
...
llvm-svn: 132440
2011-06-01 23:52:47 +00:00
Jim Ingham
b7bac4a50e
Remove the "a.out" argument from somewhere on Greg's machine in the lldb-tool run scheme.
...
llvm-svn: 132439
2011-06-01 23:52:04 +00:00
Johnny Chen
1dba2230b5
Exercise the 'thread backtrace all' command instead of the currently 'thread backtrace' command.
...
This serves as a regression test against rdar://problem/9530511.
llvm-svn: 132438
2011-06-01 23:35:20 +00:00
Johnny Chen
f2ddc71310
The 'thread backtrace all' logical branch had the if (thread->GetStatus()) condition inverted.
...
rdar://problem/9530511
llvm-svn: 132435
2011-06-01 23:19:52 +00:00
Johnny Chen
8831e18b17
Make 'run-until-faulted.py' script more interesting by modifying the example main.c program
...
to seg fault randomly instead of deterministically.
Example:
[15:10:43] johnny:/Volumes/data/lldb/svn/trunk/utils/test $ clang -g main.c
[15:10:46] johnny:/Volumes/data/lldb/svn/trunk/utils/test $ ./run-until-faulted.py -l $PWD/../../build/Debug/lldb -e a.out
lldb command: /Volumes/data/lldb/svn/trunk/utils/test/../../build/Debug/lldb
executable: a.out
executable options:
(lldb) sending 'file a.out' command...
file a.out
Current executable set to 'a.out' (x86_64).
(lldb) sending 'process launch -- ' command... (iteration: 0)
process launch --
Process 63630 launched: '/Volumes/data/lldb/svn/trunk/utils/test/a.out' (x86_64)
Hello, fault!
val=9
Better luck next time!
[KProcess 63630 exited with status = 0 (0x00000000)
(lldb) sending 'process launch -- ' command... (iteration: 1)
process launch --
Process 63633 launched: '/Volumes/data/lldb/svn/trunk/utils/test/a.out' (x86_64)
[KProcess 63633 exited with status = 0 (0x00000000)
sending 'process launch -- ' command... (iteration: 2)
[KHello, fault!
val=0
Better luck next time!
(lldb) process launch --
Process 63637 launched: '/Volumes/data/lldb/svn/trunk/utils/test/a.out' (x86_64)
Hello, fault!
val=15
Better luck next time!
[KProcess 63637 exited with status = 0 (0x00000000)
(lldb) sending 'process launch -- ' command... (iteration: 3)
process launch --
Process 63640 launched: '/Volumes/data/lldb/svn/trunk/utils/test/a.out' (x86_64)
Hello, fault!
val=2
Better luck next time!
[KProcess 63640 exited with status = 0 (0x00000000)
sending 'process launch -- ' command... (iteration: 4)
(lldb) process launch --
Process 63643 launched: '/Volumes/data/lldb/svn/trunk/utils/test/a.out' (x86_64)
[KProcess 63643 stopped
* thread #1 : tid = 0x2d03, 0x0000000100000e93 a.out`main + 99 at main.c:11, stop reason = EXC_BAD_ACCESS (code=1, address=0x0)
frame #0 : 0x0000000100000e93 a.out`main + 99 at main.c:11
8 u_int32_t val = (arc4random() & 0x0f);
9 printf("val=%u\n", val);
10 if (val == 0x07) // Lucky 7 :-)
-> 11 printf("Now segfault %d\n", *null_ptr);
12 else
13 printf("Better luck next time!\n");
14 }
(lldb)
* thread #1 : tid = 0x2d03, 0x0000000100000e93 a.out`main + 99 at main.c:11, stop reason = EXC_BAD_ACCESS (code=1, address=0x0)
frame #0 : 0x0000000100000e93 a.out`main + 99 at main.c:11
8 u_int32_t val = (arc4random() & 0x0f);
9 printf("val=%u\n", val);
10 if (val == 0x07) // Lucky 7 :-)
-> 11 printf("Now segfault %d\n", *null_ptr);
12 else
13 printf("Better luck next time!\n");
14 }
[KHello, fault!
val=7
(lldb)
llvm-svn: 132430
2011-06-01 22:12:27 +00:00
Johnny Chen
755faf7744
Make it clear that the Python script modify-python-lldb.py is responsible for post-processing
...
the SWIG-generated lldb.py module by adding comments in the post-processed file in order to
facilitate reading of the code.
llvm-svn: 132417
2011-06-01 19:21:08 +00:00
Johnny Chen
2ced507a1e
Fix comment.
...
llvm-svn: 132412
2011-06-01 18:40:11 +00:00
Charles Davis
4ce288e3e4
Fix remaining Python issues leftover from my previous patch.
...
- The Swig post-processing scripts are now run.
- edit-swig-python-wrapper-file.py has been modified so it can be run
from the Makefile.
- The issue that prompted me to pass -classic to swig is fixed by this,
so -classic isn't passed anymore.
Python shouldn't complain anymore about a missing method 'FindDebuggerByID'
on the SBDebugger object whenever lldb is run.
llvm-svn: 132383
2011-06-01 02:33:12 +00:00
Johnny Chen
4533dada39
Fix out-dated module docstring for lldbtest.py. Also wrap some lldb attribute references
...
inside a try-except block in case the test is not invoked through the dotest.py test driver.
llvm-svn: 132372
2011-05-31 23:21:42 +00:00
Johnny Chen
aacf92ebb4
Move some comments to the docstrings.
...
llvm-svn: 132367
2011-05-31 22:16:51 +00:00
Greg Clayton
5ad639415f
Fix dynamic value objects to do the right thing when the
...
value fails to evaluate.
llvm-svn: 132354
2011-05-31 20:18:39 +00:00
Greg Clayton
21e69cef08
Revert previous changes.
...
llvm-svn: 132308
2011-05-30 01:18:45 +00:00
Greg Clayton
007d5be653
lldb-59.
...
llvm-svn: 132304
2011-05-30 00:49:24 +00:00
Greg Clayton
5d2fbfed4d
Disable dynamic types being on by default until kinks get worked out when
...
they don't update correctly. Currently if a variable is unavailable due to
a register not being available in a higher frame or due to the PC value
not being a valid location list value, "<unknown type>" will get displayed
as the variable type. I am not sure what other things will fail, so I am
disabling it for now just by letting the default enumeration value default
to it being disabled.
llvm-svn: 132303
2011-05-30 00:39:48 +00:00
Greg Clayton
15184db092
Protect the input reader stack with a recursive mutex.
...
llvm-svn: 132301
2011-05-29 23:07:38 +00:00
Greg Clayton
18d85eedda
Make sure if an enumeration "settings" value has a valid default setting in
...
its definition, that the first enumeration doesn't always get used as the
default.
llvm-svn: 132289
2011-05-29 19:21:37 +00:00
Greg Clayton
71f96fef42
lldb-58
...
llvm-svn: 132281
2011-05-29 04:10:48 +00:00
Greg Clayton
fc3f027d33
Don't have the debugger default to ignoring EOF. This is only what the driver
...
(or anything running in a terminal) wants. Not what a UI (Xcode) would want
where it creates a debugger per debug window. The current code had an infinite
loop after a debug session ended.
llvm-svn: 132280
2011-05-29 04:06:55 +00:00
Greg Clayton
2dfd12fb22
lldb-57
...
llvm-svn: 132271
2011-05-29 01:30:02 +00:00
Greg Clayton
c0ea046a80
Fixed an issue that could cause LLDB to spin indefinitely.
...
llvm-svn: 132270
2011-05-29 00:45:15 +00:00