Cleanup the iOS simulator code.

Fixes include:
- Don't say that "<arch>-apple-ios" is compatible with "<arch>-apple-macosx"
- Fixed DynamicLoaderMacOSXDYLD so specify an architecture that was converted solely from a cputype and subtype, just specify the file + UUID.
- Fixed PlatformiOSSimulator::GetSupportedArchitectureAtIndex() so it returns the correct archs
- Fixed SymbolFileDWARFDebugMap to load .o files correctly by just specifying the architecture without the vendor and OS now that "<arch>-apple-ios" is not compatible with "<arch>-apple-macosx" so we can load .o files correctly for DWARF with debug map
- Fixed the coded in TargetList::CreateTarget() so it does the right thing with an underspecified triple where just the arch is specified.



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@212783 91177308-0d34-0410-b5e6-96231b3b80d8
Get the python scripting interface working on Windows.

This patch fixes a number of issues with embedded Python on
Windows.  In particular:

1) The script that builds the python modules was normalizing the
   case of python filenames during copies.  The module name is
   the filename, and is case-sensitive, so this was breaking code.

2) Changes the build to not attempt to link against python27.lib
   (e.g. the release library) when linking against msvcrt debug
   library.  Doing a debug build of LLDB with embedded python
   support now requires you to provide your own self-compiled
   debug version of python.

3) Don't import termios when initializing the interpreter.  This
   is part of a larger effort to remove the dependency on termios
   since it is not available on Windows.  This particular instance
   was unnecessary and unused.

Reviewed by: Todd Fiala

Differential Revision: http://reviews.llvm.org/D4441

git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@212785 91177308-0d34-0410-b5e6-96231b3b80d8
Remove code that was merged incorrectly.



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@212791 91177308-0d34-0410-b5e6-96231b3b80d8
Enable the ability to enable debug info generation when evaluating expressions.



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@212792 91177308-0d34-0410-b5e6-96231b3b80d8
Prevent ObjectFileELF::GetSectionHeaderInfo() from reparsing section headers.

If we have any section headers in the collection, we already parsed them.
Therefore, don't reparse the section headers when the section_headers collection
is not empty.

See this thread for more details:
http://lists.cs.uiuc.edu/pipermail/lldb-commits/Week-of-Mon-20140707/011721.html

Change by Matthew Gardiner


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@212822 91177308-0d34-0410-b5e6-96231b3b80d8
Modify ObjectFileELF::GetArchitecture() to avoid calling ParseSectionHeaders() when we have headers.

Change by Matthew Gardiner.


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@212825 91177308-0d34-0410-b5e6-96231b3b80d8
Don't use "lldb." global variables in LLDB commands.



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@212852 91177308-0d34-0410-b5e6-96231b3b80d8
Don't crash when a SBType is handed out through the API and later used after the module that owns the type is deleted.

The fix adds a std::weak_ptr<Module> into the TypeImpl and fills in the weak pointer when possible. It also checks to make sure the module is still alive prior to using it which should make our API safer to use.

<rdar://problem/15455145> 



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@212853 91177308-0d34-0410-b5e6-96231b3b80d8
Added llgs --named-pipe support and program_name-version_number printout support.

Added a unit test to test debugserver and llgs compliance on --named-pipe support.

Modified llgs to implement --named-pipe support.  (Note: need to revisit with
new generic pipe support).


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@212854 91177308-0d34-0410-b5e6-96231b3b80d8
Remove assert now that we have a 'i' character that might come through as well as the 'q' character on the interrupt pipe.

<rdar://problem/15840749>



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@212856 91177308-0d34-0410-b5e6-96231b3b80d8
Allow generic ARM cores to match any more specific ARM architecture.

<rdar://problem/15932248>



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@212863 91177308-0d34-0410-b5e6-96231b3b80d8
lldb needs to support DW_op_piece masks for values in subregister and also to be able to piece together a value that is spread across multiple registers.

Patch from Adrian Prantl.

<rdar://problem/16040521> 



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@212867 91177308-0d34-0410-b5e6-96231b3b80d8
llgs: implement --setsid.

The --setsid (-S) option changes the session id for the lldb-gdbserver process.
This is used by tools such as lldb-platform and allows the user to prevent
llgs from being in the same session as a calling terminal session.
This will prevents terminal group control signals from affecting
lldb-gdbserver.

See also:
https://github.com/tfiala/lldb/issues/38


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@212873 91177308-0d34-0410-b5e6-96231b3b80d8
Add FreeBSD decorator for TestMultipleDebuggers

llvm.org/pr20282


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@212877 91177308-0d34-0410-b5e6-96231b3b80d8
Add FreeBSD failure decorator for TestCallStopAndContinue

The testrun now completes successfully on my FreeBSD 11.0-CURRENT
laptop.  There are some intermittent failures on the FreeBSD buildbot
still, which should be addressed in later commits.

llvm.org/pr20274


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@212878 91177308-0d34-0410-b5e6-96231b3b80d8
llgs: modify to accept --native-regs flag.

This is the last flag sent by lldb-platform that was not accepted
by llgs and is accepted by debugserver.

Conditionalized out a bit more code in prep for Windows
support one day based on _WIN32 define.

Updated the lldb-gdbserver usage string to represent
recent updates to command line arguments (and some older
ones like --attach pid).

Implements https://github.com/tfiala/lldb/issues/37


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@212879 91177308-0d34-0410-b5e6-96231b3b80d8
Fix lldb-gdbserver build 

s_listen_thread had the wrong type.


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@212884 91177308-0d34-0410-b5e6-96231b3b80d8
Modified gdb-remote tests to run with automatically-chosen ports.

Now that llgs supports communicating the 0-port choose-a-port
mechanism and can communicate that back to a caller via the
--named-pipe option (at parity with debugserver), we use this
mechanism to always start llgs and debugserver gdb-remote
protocol tests without needing to use some port arbitration
mechanism.  This eliminates some potential intermittent failures vs. the
previous random port and collision-avoidance strategy used.


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@212923 91177308-0d34-0410-b5e6-96231b3b80d8