Commit Graph

410 Commits

Author SHA1 Message Date
Jason Molenda d251c9d163 Han Ming's commit in r168228 had a bunch of 4-space tabs
in the source files.  Expand to spaces.  No content changes,
just whitespace.

llvm-svn: 168238
2012-11-17 01:41:04 +00:00
Han Ming Ong c811d382f0 Follow up on <rdar://12720514>. Removed commented out code.
llvm-svn: 168232
2012-11-17 00:33:14 +00:00
Han Ming Ong ab3b8b22a1 <rdar://problem/12720514> Sub-TLF: Provide service to profile the inferior
This allows client to query profiling states on the inferior.

llvm-svn: 168228
2012-11-17 00:21:04 +00:00
Greg Clayton 1cb5951a2f Added a posix_spawn based launchd plist for always using posix_spawn to launch programs.
llvm-svn: 167563
2012-11-08 00:06:59 +00:00
Greg Clayton 9eb4e03873 <rdar://problem/12647273>
Added the ability to get the full process list when using the --applist option in debugserver.

llvm-svn: 167502
2012-11-06 23:36:26 +00:00
Sean Callanan 84dcccd14b Switched debugserver to use C++11/libc++.
<rdar://problem/12624679>

llvm-svn: 167303
2012-11-02 18:30:51 +00:00
Jason Molenda 0b2dbe0ebe Fix an error message in debugserver so it doesn't print "Unable to
launch process (null)" because we changed argv while doing argument
parsing.

llvm-svn: 167202
2012-11-01 02:02:59 +00:00
Jim Ingham 490bccd659 Switch from using KERN_PROCARGS2 to get the path to the executed process to proc_pidpath. The former was flakey, and the whole point of libproc is to protect us from potential flakiness at that level...
<rdar://problem/12594781>

llvm-svn: 167194
2012-11-01 01:04:46 +00:00
Greg Clayton d9c2370b33 Added the plists to the debugserver project and fixed the labels for the new plists.
llvm-svn: 167183
2012-10-31 23:49:14 +00:00
Greg Clayton e11b43bc69 More launchd style plists.
llvm-svn: 167182
2012-10-31 23:43:37 +00:00
Greg Clayton 48baf7a788 Resolve any bundle paths we are given when the specified executable is a bundle.
llvm-svn: 167175
2012-10-31 21:44:39 +00:00
Jason Molenda 67c3cf5357 eArgTypePath was removed in r166533; change -c to
expect eArgTypeFilename.

llvm-svn: 166542
2012-10-24 03:29:40 +00:00
Enrico Granata 430e540b6b Removing the two extra GetXSize(bool) calls since we do not desire to support them long-term
llvm-svn: 166060
2012-10-16 21:11:14 +00:00
Enrico Granata cd4d24d5e9 <rdar://problem/12446320> Fixing an issue with our Driver where setting an immediate output would not cause suppression of the final printout. This allows effective output redirection for Python commands
llvm-svn: 166058
2012-10-16 20:57:12 +00:00
Greg Clayton 01db0c6823 Provide an SSL context ref in case SLL is needed for communication.
llvm-svn: 165856
2012-10-13 00:18:18 +00:00
Greg Clayton 3e672345bc <rdar://problem/12042500>
Fixed an issue where we would try to launch an application twice and the second failure would cover up the first.

llvm-svn: 165756
2012-10-11 22:05:13 +00:00
Greg Clayton 1698be7352 Fix build warnings.
llvm-svn: 165755
2012-10-11 22:04:01 +00:00
Jim Ingham 4f465cff8a Change the Thread constructor over to take a Process& rather than a ProcessSP. We can't create Threads with a NULL ProcessSP, so it makes no sense to use the SP.
Then make the Thread a Broadcaster, and get it to broadcast when the selected frame is changed (but only from the Command Line) and when Thread::ReturnFromFrame 
changes the stack.
Made the Driver use this notification to print the new thread status rather than doing it in the command.
Fixed a few places where people were setting their broadcaster class by hand rather than using the static broadcaster class call.

<rdar://problem/12383087>

llvm-svn: 165640
2012-10-10 18:32:14 +00:00
Jason Molenda 65c28cb47a Fix the extra space char being emitted in this message when breakpoints resolve -
1 location  added to breakpoint 2

llvm-svn: 164810
2012-09-28 01:50:47 +00:00
Greg Clayton dcadc5cfb7 Re-adding this previously removed file.
llvm-svn: 164331
2012-09-20 23:08:52 +00:00
Greg Clayton b85248da95 This file is causing problems. I am going to remove it and try re-adding it.
llvm-svn: 164328
2012-09-20 23:08:12 +00:00
Jason Molenda 944cc67eba Bump to lldb-168, debugserver-193.
llvm-svn: 164291
2012-09-20 06:42:30 +00:00
Greg Clayton 813ddfcdd0 <rdar://problem/12219840>
Don't leak mach ports when calling "mach_thread_self()".

llvm-svn: 164152
2012-09-18 18:19:49 +00:00
Greg Clayton 43e0af06b4 Stop using the "%z" size_t modifier and cast all size_t values to uint64_t. Some platforms don't support this modification.
llvm-svn: 164148
2012-09-18 18:04:04 +00:00
Filipe Cabecinhas d0b87d81a1 Some more typing-related fixes.
llvm-svn: 163641
2012-09-11 18:11:16 +00:00
Greg Clayton 85fb1b93f3 <rdar://problem/11935492>
Fixed an issue where if we call "Process::Destroy()" and the process is running, if we try to stop it and get "exited" back as the stop reason, we will still deliver the exited event.

llvm-svn: 163591
2012-09-11 02:33:37 +00:00
Sean Callanan 3ff3199e61 Fixed a bug where the LLDB_VERSION wasn't properly
truncated during install-headers.

<rdar://problem/12268130>

llvm-svn: 163559
2012-09-10 22:43:22 +00:00
Sean Callanan 433c8a1f44 Committed a simple dtrace script that tracks
process termination, which can be useful to track
debugserver's delivery of signals.

llvm-svn: 162104
2012-08-17 16:30:13 +00:00
Johnny Chen eb46f78b08 rdar://problem/12096295
Add an lldb command line option to specify a core file: --core/-c.
For consistency, change the "target create" command to also use --core.

llvm-svn: 161993
2012-08-15 22:10:42 +00:00
Sean Callanan d5e37e4d2b Updating Xcode project version numbers for lldb-165 and debugserver-192
llvm-svn: 161374
2012-08-07 00:32:29 +00:00
Sean Callanan c40b0f38b3 Updating Xcode project version numbers for lldb-164 and debugserver-191
llvm-svn: 161209
2012-08-02 20:40:53 +00:00
Jim Ingham cfc0935ed9 Added an lldb_private & equivalent SB API to send an AsyncInterrupt to the event loop.
Convert from calling Halt in the lldb Driver.cpp's input reader's sigint handler to sending this AsyncInterrupt so it can be handled in the 
event loop.
If you are attaching and get an async interrupt, abort the attach attempt.
Also remember to destroy the process if get interrupted while attaching.
Getting this to work also required handing the eBroadcastBitInterrupt in a few more places in Process WaitForEvent & friends.

<rdar://problem/10792425>

llvm-svn: 160903
2012-07-27 23:57:19 +00:00
Sean Callanan 6981f1d856 Updating Xcode project version numbers for lldb-163 and debugserver-190
llvm-svn: 160770
2012-07-26 01:42:37 +00:00
Jim Ingham 279ceecf65 Add a call to "sync" a thread state before checkpointing registers in preparation for
calling functions.  This is necessary on Mac OS X, since bad things can happen if you set
the registers of a thread that's sitting in a kernel trap.

<rdar://problem/11145013>

llvm-svn: 160756
2012-07-25 21:12:43 +00:00
Jim Ingham 1bfe4f6417 Use a more efficient API to tell if a process belongs to springboard or not.
llvm-svn: 160655
2012-07-24 01:23:53 +00:00
Jim Ingham cd16df9154 Add "vAttachOrWait" to debugserver, so you can implement "attach to the process if it exists OR wait for it" without race conditions. Use that in lldb.
llvm-svn: 160578
2012-07-20 21:37:13 +00:00
Greg Clayton 7dab2be287 <rdar://problem/11908082>
Allow debugserver to match process names that are longer than MAXCOMLEN (16) characters. We do this by digging up argv[0] from another sysctl if the process name supplied is longer than 16 characters.

llvm-svn: 160487
2012-07-19 02:45:35 +00:00
Greg Clayton 9773542933 Update the project and schemes to the Xcode recommended settings.
llvm-svn: 160391
2012-07-17 19:47:06 +00:00
Greg Clayton 23f59509a8 Ran the static analyzer on the codebase and found a few things.
llvm-svn: 160338
2012-07-17 03:23:13 +00:00
Jim Ingham 73472eef4d Fix an off by one error when handling a packet where our read buffer size truncates the first chunk of the packet
between the two chars representing the checksum.

<rdar://problem/11882074>

llvm-svn: 160310
2012-07-16 18:56:05 +00:00
Jason Molenda 64e1d4abc7 Bump to lldb-162 / debugserver-189.
llvm-svn: 160212
2012-07-14 01:12:03 +00:00
Enrico Granata f04a21917c <rdar://problem/11782789> Changes to the watchpoint implementation on ARM so that we single-step before stopping at the WP. This is necessary because on ARM the WP triggers before the opcode is actually executed, so we would be unable to continue since we would keep hitting the WP. We work around this by disabling the WP, single stepping and then putting the WP back in place.
llvm-svn: 160199
2012-07-13 23:18:48 +00:00
Jim Ingham 9aa15a4562 Unify how we get host version on Mac OS X & iOS.
Also remove our dependency on UIKit & AppKit.
Cleaned up the project files a bit.

<rdar://problem/11814498>

llvm-svn: 160147
2012-07-12 23:16:43 +00:00
Sean Callanan 9690a41e18 Added an editline fix to make the delete key act
as expected on Mac OS X.

<rdar://problem/11813365>

llvm-svn: 160091
2012-07-11 22:55:32 +00:00
Jason Molenda 84d32ddfc8 Bump versions to lldb-161, debugserver-188.
llvm-svn: 159798
2012-07-06 01:32:10 +00:00
Greg Clayton 503cd42259 Spelling fixes.
llvm-svn: 159466
2012-06-29 21:58:00 +00:00
Enrico Granata c76715f3be <rdar://problem/11679380> Make sure we do not fallback to software stepping when hardware stepping should work but fails to get enabled. Also removing dead code paths
llvm-svn: 159322
2012-06-28 01:23:30 +00:00
Filipe Cabecinhas 2f42bb03b7 DNBLogThreadedIf already inserts a newline
llvm-svn: 158995
2012-06-22 13:54:32 +00:00
Johnny Chen 9a63cfaf8d rdar://problem/11649610
lldb confused by single quote in executable path

Also add a test case.

llvm-svn: 158693
2012-06-19 00:56:55 +00:00
Johnny Chen be4e208103 rdar://problem/11390100
debugserver needs to be able to posix_spawn debugging apps that have ".app" in their path that aren't bundles

llvm-svn: 158327
2012-06-11 21:05:26 +00:00