Commit Graph

5407 Commits

Author SHA1 Message Date
Jim Ingham 23ef27cd46 Give the clang functions names. This is only for logging.
llvm-svn: 206836
2014-04-22 01:42:22 +00:00
Jim Ingham fd95f8961e Make RunThreadPlan start the timeout clock for each part of the expression evaluation AFTER the
successful resume for that part.  This will make the timeouts more stable when lldb is running
in a busy program.

llvm-svn: 206835
2014-04-22 01:41:52 +00:00
Sylvestre Ledru b96ca6b0c8 Remove useless declaration
llvm-svn: 206764
2014-04-21 17:43:17 +00:00
Ed Maste d4612ad0f3 Switch NULL to C++11 nullptr in source/Symbol and source/Utility
Patch by Robert Matusewicz

llvm-svn: 206713
2014-04-20 13:17:36 +00:00
Ed Maste d78c9576ca Switch NULL to C++11 nullptr in source/Interpreter
Patch by Robert Matusewicz

llvm-svn: 206711
2014-04-20 00:31:37 +00:00
Saleem Abdulrasool 97fb5e128a Utility: fix compilation on Linux
When compiling on Linux with GCC 4.8, compilation would fail due to the use of
the offsetof macro.  This is a standard macro, defined in stddef.h.  Include
this header to ensure that offsetof is declared.

llvm-svn: 206702
2014-04-19 21:18:28 +00:00
Sean Callanan af90cf528c Included <inttypes.h> in a few headers that were
using preprocessor constants for printf() format
specifications.

llvm-svn: 206679
2014-04-19 03:09:28 +00:00
Todd Fiala 3dbe13f6a8 Address hung tests in Linux.
Follow-up patch coming to address test failures exposed by this change.

llvm-svn: 206618
2014-04-18 17:01:01 +00:00
Greg Clayton c71e7bc415 After updating to Xcode.5.1.1 LLDB framework stopped to support partial (only for STDIN) pseudo terminal usage in the debugging process.
Here is the fix resolving this issue.

Patch from Alexey Ushakov.

llvm-svn: 206476
2014-04-17 17:27:28 +00:00
Ed Maste 94ba368946 elf-core: Add FreeBSD signals
Sponsored by: DARPA, AFRL
Differential Revision: http://reviews.llvm.org/D3401

llvm-svn: 206469
2014-04-17 13:09:29 +00:00
Ed Maste 41736e3c0d elf-core: Strip trailing whitespace
llvm-svn: 206468
2014-04-17 13:06:49 +00:00
Ed Maste dbb67c46db Move FreeBSDSignals to Utility
It will shortly be need by FreeBSD elf core support on all hosts.

llvm-svn: 206466
2014-04-17 13:03:10 +00:00
Jim Ingham fe1c34266f Clean up the logic in setting timeouts a bit, and the logging as well.
llvm-svn: 206351
2014-04-16 02:24:48 +00:00
Jim Ingham b8cd5750b4 m_interrupt_sent wasn't being initialized, and wasn't being reset after an
interrupt.  Do both of those.

llvm-svn: 206350
2014-04-16 02:24:17 +00:00
Ed Maste 9b8d847b8f Add FreeBSD-specific SIGTHR and SIGLIBRT signals
llvm-svn: 206319
2014-04-15 20:22:32 +00:00
Sylvestre Ledru a3e4cebd96 Remove trailing spaces
llvm-svn: 206278
2014-04-15 12:08:57 +00:00
Sylvestre Ledru 5ac35ae6f7 Make LLDB builds against the current LLVM sources (modification on createMCDisassembler introduced by r206241)
llvm-svn: 206277
2014-04-15 12:07:25 +00:00
Hafiz Abid Qadeer 224746a400 Remove > 1 check against a boolean.
I saw a complain about this code on the LLVM channel. It looks wrong to me
as has_tag is a boolean. I am committing it as obvious.

llvm-svn: 206270
2014-04-15 10:06:47 +00:00
Jason Molenda c6fa5db747 Add some basic sanity checks to DynamicLoaderDarwinKernel::ReadKextSummaryHeader()
when it is reading the kext table, in case we're reading out of a core file with
corrupt contents in this region.
<rdar://problem/16601915> 

llvm-svn: 206233
2014-04-15 01:04:00 +00:00
Greg Clayton 3434b578be Fix LLDB to build with top of tree LLVM/Clang.
Patch from Michael Tao.

llvm-svn: 206213
2014-04-14 21:33:38 +00:00
Greg Clayton 8334e14efc Fixed SBThread.GetStopReasonDataAtIndex() to correctly return breakpoint location ID.
Patch from Vyacheslav Karpukhin.

llvm-svn: 206040
2014-04-11 17:27:02 +00:00
Enrico Granata bd4885f129 <rdar://problem/16540961>
The "unexpected value" message only matters to me, but is bound to make the experience more confusing for people when some uninitialized memory looks like an NSNumber and then can't be formatted properly, and that error comes out in the UI

Just drop the error message entirely - nobody but me cares

llvm-svn: 205978
2014-04-10 18:17:30 +00:00
Enrico Granata 1ac6296376 <rdar://problem/12055586>
Enable data formatters to see-through pointers/references to typedefs

For instance, if Foo is a typedef to Bar, and there is a formatter for any/all of Bar*, Bar&, Bar&&, then Foo*, Foo&, and Foo&& should pick these up if Foo-specific formatters don't exist

llvm-svn: 205939
2014-04-10 00:14:07 +00:00
Enrico Granata 699e14f3ce When trying to extract the type info for an r-value reference type, dont' cast to an l-value reference type
llvm-svn: 205932
2014-04-09 21:54:17 +00:00
Enrico Granata a0db6ed44b <rdar://problem/16477472>
Set the correct FormatManager revision before starting to figure out the new formatters
This can avoid entering some corner cases where as part of figuring out formatters we try to figure out dynamic types, and in turn that causes us to go back in trying to fetch new formatters - it is not only a futile exercise, it's also prone to endless recursion

This would only cause a behavior change if getting this chain started would eventually cause something to run and alter the formatters, a very unlikely if at all possible sequence of events

llvm-svn: 205928
2014-04-09 21:06:11 +00:00
Ed Maste 5b031ebc70 Use the default TID format in curses UI
TIDs are conventionally shown as decimal values on FreeBSD and Linux.
Thus, use the ${thread.id%tid} format string to display the thread ID,
instead of a fixed hex format.

llvm.org/pr19380

llvm-svn: 205912
2014-04-09 16:39:30 +00:00
Sean Callanan 131be99d24 Fixed a problem where IRForTarget wasn't ignoring
dbg_value intrinsics appropriately.

<rdar://problem/16504649>

llvm-svn: 205825
2014-04-09 00:59:41 +00:00
Jim Ingham 35878c4752 Fix the behavior when hand-calling a function times out on one thread,
but by the time we go to halt, it has already stopped by hitting the 
function end breakpoint.  That wasn't being shown to the threads so the
Function call thread plan didn't know its job was done.

<rdar://problem/16515785>

llvm-svn: 205803
2014-04-08 21:33:21 +00:00
Jim Ingham 7e9eff664c This function should be const.
llvm-svn: 205790
2014-04-08 20:24:45 +00:00
Enrico Granata 2b8fc66df2 Fix the GetArrayElementType() call so it will not crash when called on a non-array thing
Also, the stride is now a pointer so one can avoid passing it if it's not required

llvm-svn: 205782
2014-04-08 18:36:09 +00:00
Ed Maste 42c549b346 Revert r205769 as it breaks the build on FreeBSD:
error: declaration of constexpr static data member 'spec' requires an
initializer

llvm-svn: 205776
2014-04-08 17:02:25 +00:00
Ed Maste 4a06df95b9 Accept DWARF version 2 and 3 in debug_line tables
Issue reported by Matthew Gardiner.  Further work is necessary to
synchronize LLDB's DWARF classes with the derivatives now in LLVM.

llvm-svn: 205771
2014-04-08 15:12:07 +00:00
Virgile Bello 97a70e4f7e Added i686 architecture (ArchSpec::Core::eCore_x86_32_i686).
llvm-svn: 205770
2014-04-08 14:48:48 +00:00
Virgile Bello 8250ebdd8a Improve demangler to compile with MSVC.
llvm-svn: 205769
2014-04-08 14:46:44 +00:00
Greg Clayton 86e70cb3ac Fixed an issue where if you called:
SBTarget::AddModule(const char *path,
                    const char *triple,
                    const char *uuid_cstr,
                    const char *symfile);
                    
If "symfile" was filled in, it would cause us to not correctly add the module. Same goes for:

SBTarget::AddModule(SBModuleSpec ...)

Where you filled in the symfile.

<rdar://problem/16529799>

llvm-svn: 205750
2014-04-07 23:50:17 +00:00
Greg Clayton c7797accb8 Fixed a case where we could spin indefinitely if we got an error from fgets that isn't EINTR.
<rdar://problem/16535437>

llvm-svn: 205740
2014-04-07 21:37:59 +00:00
Greg Clayton 78d1019703 Cleanup the code a bit.
llvm-svn: 205739
2014-04-07 21:37:03 +00:00
Greg Clayton 521c2278ab Disable JITLoaderGDB on "vendor == apple" for now due to performance slowdowns for every first run process as a global name lookup in all shared libraries if performed.
<rdar://problem/16542894>

llvm-svn: 205734
2014-04-07 20:13:57 +00:00
Greg Clayton d20deac32d Xcode 5 crashes if lldb stops at breakpoint if long c++ template lists are present.
This fix reduces the stack size of SymbolFileDWARF::ParseType(). It seems that clang is not very good at sharing locations on the stack with local variables in large functions that have many blocks and each variable gets unique locations. The reduction in size was done by:
1 - removing some large locals that were default constructed by not used
2 - Placing some larger local variables into std::unique_ptr<> to make them on the heap
3 - removing local variables there were large and being populated but not being used
4 - reducing the size of some typedefs to llvm::SmallVector<T, N> so that N wasn’t excessively large


<rdar://problem/16431645>

llvm-svn: 205640
2014-04-04 18:15:18 +00:00
Greg Clayton c9cf579837 Don’t exit the command interpreter if we get interrupted by an EINTR when calling fgets().
llvm-svn: 205638
2014-04-04 18:11:31 +00:00
Jim Ingham 2e3881c0f5 Remember to clear the cached data for the OptionValueFileSpec in SetValueFromCString.
<rdar://problem/16179718> target.expr-prefix contents appear to be cached for an entire session

llvm-svn: 205636
2014-04-04 18:06:54 +00:00
Greg Clayton 7ec287cda3 Don’t crash when we get an invalid .debug_aranges set, just ignore it. Also print out warning messages if LLDB_CONFIGURATION_DEBUG is defined.
<rdar://problem/16516343>

llvm-svn: 205634
2014-04-04 17:53:30 +00:00
Saleem Abdulrasool 324a103619 sweep up -Wformat warnings from gcc
This is a purely mechanical change explicitly casting any parameters for printf
style conversion.  This cleans up the warnings emitted by gcc 4.8 on Linux.

llvm-svn: 205607
2014-04-04 04:06:10 +00:00
Ed Maste 0fdeb7158e Avoid crash if symbol returns a null name
llvm-svn: 205555
2014-04-03 19:27:39 +00:00
Jim Ingham 2f4693aa77 Get "dis -c -s" working again.
pr19324

llvm-svn: 205544
2014-04-03 17:16:17 +00:00
Jim Ingham 6c9ed91cca Make the fail messages
llvm-svn: 205497
2014-04-03 01:26:14 +00:00
Jason Molenda 987cbaa09b Add a missing arm64 idef.
llvm-svn: 205488
2014-04-02 23:52:55 +00:00
Jim Ingham 46d005dbc4 Workaround for collision between enum members in LLVM's MachO.h and system headers
on Mac OS X (in particular mach/machine.h).

<rdar://problem/16494607>

llvm-svn: 205480
2014-04-02 22:53:21 +00:00
Greg Clayton 711861fec5 Don’t #include "llvm/Support/MachO.h” as it isn’t needed here.
llvm-svn: 205462
2014-04-02 20:39:20 +00:00
Greg Clayton 3657e9c592 Don’t include “llvm/Support/MachO.h” as it isn’t needed here.
llvm-svn: 205461
2014-04-02 20:38:03 +00:00