History log of /external/lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
e0ee393523f63b80ec77bc92fa685d8290e9b82a 18-Jul-2013 Jim Ingham <jingham@apple.com> Didn't get the right version of these files in the checkin for r186132.


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@186596 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h
4e49a5bfccc0a51185eadf69b3e23f68e70f1676 12-Jul-2013 Jim Ingham <jingham@apple.com> Get debugserver to call task_set_state to prime the control registers so that watchpoints
take for threads created while the program is running. Remove the testcase skips from TestConcurrentEvents.py,
since they all pass now, and fix TestWatchpointMultipleThreads.py - which should have caught this problem -
so it doesn't artificially break on new thread creation before the watchpoint triggers.

llvm.org/pr16566
<rdar://problem/14383244>


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@186132 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h
59752d199bb19ffde140b67da147b0afa67f2e88 25-Jun-2013 Jason Molenda <jmolenda@apple.com> Remove some unnecessary uses of nub_break_t in the arm specific
support files for debugserver to fix a build failure for arm. Also
remove some of the code used for software-driven single instruction
stepping; this is slowly being yanked out and these particular bits
overlap with the nub_break_t going away.



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@184828 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h
aed59619469c06e7eba11e64bd40e7a02f68eaaa 09-Mar-2013 Jason Molenda <jmolenda@apple.com> Remove use of the ARMDisassembler framework from
DNBArchImplARM. This framework is no longer around;
all armv7 devices support using hardware breakpoints
to instruction single step.


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@176761 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h
9a725f0e1d0589254d5e96fa3516d56a30799950 23-Mar-2012 Johnny Chen <johnny.chen@apple.com> Make arm debugserver handle setting a watchpoint on, for example, (uint64_t)variable.
We do this by delegating to two available Watchpoint Register Pairs (wvr, wcr). With
each pair handling the 4 bytes of (uint64_t)variable.


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@153300 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h
cf88842d06049af7dffa1b299964a3a573283cc4 22-Mar-2012 Johnny Chen <johnny.chen@apple.com> Previous check-ins allow to hit the arm hardware watchpoint, with a workaound to handle the issue
that the inferior cannot execute past the watchpoint-triggering instruction.

The solution is disable the watchpoint before resuming the inferior and make it hardware single step;
when the inferior stops again due to single step, re-enable the watchpoint and disable the single step
to make the inferior able to continue again without obstacle.

rdar://problem/9667960


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@153273 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h
7d0356fdfa7ee04b39e84946fb0497f227cc894f 22-Mar-2012 Johnny Chen <johnny.chen@apple.com> Fixed a bug with the r153228 check-in earlier today in that the cached watchpoint
member variables were not reset appropriately.


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@153239 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h
33de0386250de1ded3dc2fdfb607970e52d83420 22-Mar-2012 Johnny Chen <johnny.chen@apple.com> WIP snapshot of hardware watchpoints for arm. A simple watchpoint has triggered.
However, the debugserver cannot get past the instruction which triggered the watchpoint.
So a workaround is in place for the time being which disables the triggered watchpoint
before resuming.

Lots of commented out printf's remain in the source which needs to be cleaned up.

WIP rdar://problem/9667960


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@153228 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h
e350394e5b4bd5c32f70951a035a889bfd0194e4 24-Feb-2012 Johnny Chen <johnny.chen@apple.com> Add a class method HasWatchpointOccurred() to inspect the "method of debug entry" field
of the DSCR to check whether it was because of watchpoint occurred.


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@151333 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h
305f38588817f823f05100e8236745e8e4d70320 11-Jan-2012 Johnny Chen <johnny.chen@apple.com> Snapshot of initial work for ARM watchpoint support on the debugserver.
It is incomplete and untested; passes the compilation only.


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@147901 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h
6c7559ae5255ad791a197dc08e1d0ce9130a3988 10-Jan-2012 Greg Clayton <gclayton@apple.com> Disable ARMDisassembler.framework support which was used for software single stepping.



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@147886 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h
1f5c0c368c1dfeb67b3b9fca8ef869206554e25a 08-Dec-2011 Jason Molenda <jmolenda@apple.com> Expose the DNBArchMachARM::DBG typedef, specify the type with the
class scoping in DumpDBGState()'s definiton.



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@146128 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h
46b27f25b970cb7a26495402b44c4a5ed981e4b8 06-Dec-2011 Johnny Chen <johnny.chen@apple.com> Add a typedef for arm_debug_state_t as DBG. Plus some minor comment changes.


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@145978 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h
24bc5d9bfad2a1c562c27e7cf37e1c56d85c45e7 30-Mar-2011 Greg Clayton <gclayton@apple.com> Many improvements to the Platform base class and subclasses. The base Platform
class now implements the Host functionality for a lot of things that make
sense by default so that subclasses can check:

int
PlatformSubclass::Foo ()
{
if (IsHost())
return Platform::Foo (); // Let the platform base class do the host specific stuff

// Platform subclass specific code...
int result = ...
return result;
}

Added new functions to the platform:

virtual const char *Platform::GetUserName (uint32_t uid);
virtual const char *Platform::GetGroupName (uint32_t gid);

The user and group names are cached locally so that remote platforms can avoid
sending packets multiple times to resolve this information.

Added the parent process ID to the ProcessInfo class.

Added a new ProcessInfoMatch class which helps us to match processes up
and changed the Host layer over to using this new class. The new class allows
us to search for processs:
1 - by name (equal to, starts with, ends with, contains, and regex)
2 - by pid
3 - And further check for parent pid == value, uid == value, gid == value,
euid == value, egid == value, arch == value, parent == value.

This is all hookup up to the "platform process list" command which required
adding dumping routines to dump process information. If the Host class
implements the process lookup routines, you can now lists processes on
your local machine:

machine1.foo.com % lldb
(lldb) platform process list
PID PARENT USER GROUP EFF USER EFF GROUP TRIPLE NAME
====== ====== ========== ========== ========== ========== ======================== ============================
99538 1 username usergroup username usergroup x86_64-apple-darwin FileMerge
94943 1 username usergroup username usergroup x86_64-apple-darwin mdworker
94852 244 username usergroup username usergroup x86_64-apple-darwin Safari
94727 244 username usergroup username usergroup x86_64-apple-darwin Xcode
92742 92710 username usergroup username usergroup i386-apple-darwin debugserver


This of course also works remotely with the lldb-platform:

machine1.foo.com % lldb-platform --listen 1234

machine2.foo.com % lldb
(lldb) platform create remote-macosx
Platform: remote-macosx
Connected: no
(lldb) platform connect connect://localhost:1444
Platform: remote-macosx
Triple: x86_64-apple-darwin
OS Version: 10.6.7 (10J869)
Kernel: Darwin Kernel Version 10.7.0: Sat Jan 29 15:17:16 PST 2011; root:xnu-1504.9.37~1/RELEASE_I386
Hostname: machine1.foo.com
Connected: yes
(lldb) platform process list
PID PARENT USER GROUP EFF USER EFF GROUP TRIPLE NAME
====== ====== ========== ========== ========== ========== ======================== ============================
99556 244 username usergroup username usergroup x86_64-apple-darwin trustevaluation
99548 65539 username usergroup username usergroup x86_64-apple-darwin lldb
99538 1 username usergroup username usergroup x86_64-apple-darwin FileMerge
94943 1 username usergroup username usergroup x86_64-apple-darwin mdworker
94852 244 username usergroup username usergroup x86_64-apple-darwin Safari

The lldb-platform implements everything with the Host:: layer, so this should
"just work" for linux. I will probably be adding more stuff to the Host layer
for launching processes and attaching to processes so that this support should
eventually just work as well.

Modified the target to be able to be created with an architecture that differs
from the main executable. This is needed for iOS debugging since we can have
an "armv6" binary which can run on an "armv7" machine, so we want to be able
to do:

% lldb
(lldb) platform create remote-ios
(lldb) file --arch armv7 a.out

Where "a.out" is an armv6 executable. The platform then can correctly decide
to open all "armv7" images for all dependent shared libraries.

Modified the disassembly to show the current PC value. Example output:

(lldb) disassemble --frame
a.out`main:
0x1eb7: pushl %ebp
0x1eb8: movl %esp, %ebp
0x1eba: pushl %ebx
0x1ebb: subl $20, %esp
0x1ebe: calll 0x1ec3 ; main + 12 at test.c:18
0x1ec3: popl %ebx
-> 0x1ec4: calll 0x1f12 ; getpid
0x1ec9: movl %eax, 4(%esp)
0x1ecd: leal 199(%ebx), %eax
0x1ed3: movl %eax, (%esp)
0x1ed6: calll 0x1f18 ; printf
0x1edb: leal 213(%ebx), %eax
0x1ee1: movl %eax, (%esp)
0x1ee4: calll 0x1f1e ; puts
0x1ee9: calll 0x1f0c ; getchar
0x1eee: movl $20, (%esp)
0x1ef5: calll 0x1e6a ; sleep_loop at test.c:6
0x1efa: movl $12, %eax
0x1eff: addl $20, %esp
0x1f02: popl %ebx
0x1f03: leave
0x1f04: ret

This can be handy when dealing with the new --line options that was recently
added:

(lldb) disassemble --line
a.out`main + 13 at test.c:19
18 {
-> 19 printf("Process: %i\n\n", getpid());
20 puts("Press any key to continue..."); getchar();
-> 0x1ec4: calll 0x1f12 ; getpid
0x1ec9: movl %eax, 4(%esp)
0x1ecd: leal 199(%ebx), %eax
0x1ed3: movl %eax, (%esp)
0x1ed6: calll 0x1f18 ; printf

Modified the ModuleList to have a lookup based solely on a UUID. Since the
UUID is typically the MD5 checksum of a binary image, there is no need
to give the path and architecture when searching for a pre-existing
image in an image list.

Now that we support remote debugging a bit better, our lldb_private::Module
needs to be able to track what the original path for file was as the platform
knows it, as well as where the file is locally. The module has the two
following functions to retrieve both paths:

const FileSpec &Module::GetFileSpec () const;
const FileSpec &Module::GetPlatformFileSpec () const;





git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@128563 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h
20d338fad87eba91de65aa9bec76e01c04472848 18-Nov-2010 Greg Clayton <gclayton@apple.com> Fixed Process::Halt() as it was broken for "process halt" after recent changes
to the DoHalt down in ProcessGDBRemote. I also moved the functionality that
was in ProcessGDBRemote::DoHalt up into Process::Halt so not every class has
to implement a tricky halt/resume on the internal state thread. The
functionality is the same as it was before with two changes:
- when we eat the event we now just reuse the event we consume when the private
state thread is paused and set the interrupted bool on the event if needed
- we also properly update the Process::m_public_state with the state of the
event we consume.

Prior to this, if you issued a "process halt" it would eat the event, not
update the process state, and then produce a new event with the interrupted
bit set and send it. Anyone listening to the event would get the stopped event
with a process that whose state was set to "running".

Fixed debugserver to not have to be spawned with the architecture of the
inferior process. This worked fine for launching processes, but when attaching
to processes by name or pid without a file in lldb, it would fail.

Now debugserver can support multiple architectures for a native debug session
on the current host. This currently means i386 and x86_64 are supported in
the same binary and a x86_64 debugserver can attach to a i386 executable.
This change involved a lot of changes to make sure we dynamically detect the
correct registers for the inferior process.



git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@119680 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h
0a7f75f9e375911ca91a884968b0efa36f18588d 09-Sep-2010 Greg Clayton <gclayton@apple.com> Got the ARM version of debugserver up to date.

Renamed the "dispatchqaddr" setting that was coming back for stop reply packets
to be named "qaddr" so that gdb doesn't thing it is a register number. gdb
was checking the first character and assuming "di" was a hex register number
because 'd' is a hex digit. It has been shortened so gdb can safely ignore it.



git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@113475 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h
24943d2ee8bfaa7cf5893e4709143924157a5c1e 08-Jun-2010 Chris Lattner <sabre@nondot.org> Initial checkin of lldb code from internal Apple repo.


git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@105619 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h