A redefinition of append_if in CompilerRTUtils causes the append_if to fail.
Manually append the values to the flags.
Thanks to Kuba Ober for pointing this out!
llvm-svn: 204311
This is a mechanical cleanup of unused functions. In the case where the
functions are referenced (in comment form), I've simply commented out the
functions. A second pass to clean that up is warranted.
The functions which are otherwise unused have been removed. Some of these were
introduced in the initial commit and not in use prior to that point!
NFC
llvm-svn: 204310
TestPromptFormats appears as though it may be a useful unit test.
Unfortunately, there is no invocation mechanism in place right now. It is
unclear how to add a unit test for this scenario to the existing tests. It
would be ideal to remove this entirely, but I am hopeful that this can/will be
pulled out into a test still since it uses a user accessible interface.
llvm-svn: 204309
so mark as expected fail. And find another way to check that we hit our constructor
breakpoint, so we don't need to expected fail the Disassembly tests.
llvm-svn: 204209
The standard JIT has been discarded in favour of MCJIT. USE_STANDARD_JIT is no
longer defined. Furthermore, the execution engine is now built in
IRExecutionUnit. Simply remove inclusion of both JIT headers.
llvm-svn: 204112
Multichar constants are not portable as the byte order is undefined. Use a
constant value instead. This avoids a warning when compiling with gcc 4.8+
(-Wmultichar) and makes the code more portable.
llvm-svn: 204110
The gain with multithreading is large, but turning it on requires
an environment variable and so is hard for users to discover. This
gives users a way to discover the feature by printing out a message
when the environment variable is not set.
llvm-svn: 204018
libxml2's include path was unconditionally set to /usr/include/libxml2. This
would work previously, however, Mavericks removed the /usr/include directory.
Since LLDB already requires clang, which via LLVM's build infrastructure
searches for libxml2, we have a proper include path for libxml2. If
LIBXML2_FOUND is set, do not touch the libxml2 search path. Instead, allow the
clang's definition to propagate throughout the LLVM build. Otherwise, switch to
find_package(LibXml2) as clang does. This will ensure that the correct path is
used for libxml2 irrespective of the platform.
Furthermore, treat libxml2 as a system provided library. It is not part of the
LLVM source base so it is of little value to enable all warnings on its headers.
This unifies the treatment of libxml2 across clang and LLDB.
llvm-svn: 203955
for customizing "step-in" behavior (e.g. step-in doesn't step into code with no debug info), but also
the behavior of step-in/step-out and step-over when they step out of the frame they started in.
I also added as a proof of concept of this reworking a mode for stepping where stepping out of a frame
into a frame with no debug information will continue stepping out till it arrives at a frame that does
have debug information. This is useful when you are debugging callback based code where the callbacks
are separated from the code that initiated them by some library glue you don't care about, among other
things.
llvm-svn: 203747
Fix Windows build by adding JITLoaderGDB and ProcessElfCore.
RegisterContext: fixes for Windows build: sizeof(GPR::register) didn't work, switched to sizeof(((GPR*)NULL)->register).
llvm-svn: 203667
erroneously completing Objective-C classes sourced
from the Objective-C runtime without checking if
there was an authoritative version in the debug
information.
<rdar://problem/16065049>
llvm-svn: 203600
This header is generally not available on mingw and can cause build errors.
The windows host code does provide timespec definition that can be used for
mingw case.
llvm-svn: 203555
Check if the compiler actually supports the flags that are being added.
Previously, the compiler flags would be used improperly push the flags to the
compiler. Particularly, on Darwin, the option would be pushed to the compiler
even if it does not support it.
llvm-svn: 203532
What was use_iterator is now user_iterator. Also switch to range-based
APIs, as in Clang r203365.
(This part of the change was missed in r203463)
Differential Revision: http://llvm-reviews.chandlerc.com/D3030
llvm-svn: 203475
Seed the QueueItem objects with the item_refs and addresses when they are fetched
in one batch. If additional information is needed from the QueueItem, fetch it
lazily one pending item per function call.
<rdar://problem/16270007>, <rdar://problem/16032150>
llvm-svn: 203449
changing the data it returns; this change accepts either the old format or
the new format. It doesn't yet benefit from the new format's additions -
but I need to get this checked in so we aren't rev-locked.
Also add a missing .i entry for SBQueue::GetNumRunningItems() missing from
the last checkin.
<rdar://problem/16272115>
llvm-svn: 203421
items; the backing Queue object has the number of pending items
already cached. Also, add SBQueue::GetNumRunningItems() to provide
that information.
<rdar://problem/16272016>
llvm-svn: 203420
memcpy cannot be passed NULL. Ensuring that the destination pointer is non-NULL
requires checking success. Rather than performing the success check at that
point, increasing indentation an additional level, fold it into the previous
statement.
llvm-svn: 203359
After hitting the malloc() breakpoint on FreeBSD our top frame is actually
an inlined function malloc_init.
* frame #0: 0x0000000800dcba19 libc.so.7`malloc [inlined] malloc_init at malloc.c:5397
frame #1: 0x0000000800dcba19 libc.so.7`malloc(size=1024) + 9 at malloc.c:5949
frame #2: 0x00000000004006e5 test_step_out_of_malloc_into_function_b_with_dwarf`b(val=1) + 37 at main2.cpp:29
Add a heuristic to keep stepping out until we come to a non-malloc caller,
before checking if it is our desired caller from the test code.
llvm.org/pr17944
llvm-svn: 203268
A freebsd issue with rm prevents '[g]make clean' from working if $(DSYM)
is empty (fts_open(3) fails if passed an empty argument).
To work around this, simplify the clean target by using three separate
rm invocations: one for the common files, one for the case of non-empty
$(DYLIB_NAME), and one for non-empty $(DSYM).
Issue diagnosed (and reported to FreeBSD) by John Wolfe.
llvm.org/pr17933
llvm-svn: 203253
not going to key off of the ELF object file like I'd intended.
Revert my change in r203205; also revert Greg's change in
r203107 which builds ProcessElfCore on non-Linux/FreeBSD systems
for the moment until we can straighten this out.
llvm-svn: 203207
ProcessMachCore because it doesn't check the format of the file up front. (this is only now
happening because of Greg's change in r203178 to build ProcessElfCore for non-Linux/FreeBSD
hosts).
<rdar://problem/16257533>
llvm-svn: 203205
It speeds up running the full test suite on my HP z620 Ubuntu machine with 32 hyperthreaded CPUs from 11 minutes to about 1m13s (about 9x).
The default behavior is to run single-threaded as before. If the environment variable LLDB_TEST_THREADS is set, a Python work queue is set up with that many worker threads.
To avoid collisions within a test directory where multiple tests make use of the same prebuilt executable, the unit of work for the worker threads is a single directory (that is, all tests within a directory are processed in the normal serial way by a single thread).
tfiala & I have run this way a number of times; the only issue I found was that the TestProcessAttach.py test failed once, when attempting to attach to the process "a.out" by name. I assume this is because some other thread was running an executable of that name at the same time, and we were attempting to attach to the wrong one, so I changed that test to use a different executable name (that change is also included in this commit).
llvm-svn: 203180
Author: ace2001ac
Date: Thu Mar 6 05:30:34 2014
New Revision: 203107
URL: http://llvm.org/viewvc/llvm-project?rev=203107&view=rev
Log:
Fix Windows build break introduced in r203035.
Add '#if defined(__linux__) || defined(__FreeBSD__)' around JITLoaderGDB
and ProcessElfCore, which are only built on Linux and FreeBSD.
Modified:
lldb/trunk/source/lldb.cpp
Windows will need to start building all files necessary so that JITLoaderGDB and ProcessElfCore can build since they should work on all platforms.
llvm-svn: 203178
Please do not add header files that are required in public APIs without first checking with us. This broke the LLDB builds at Apple because the lldb-dll-export.h wasn't included in the LLDB.framework and it was being included by public API header files.
llvm-svn: 203177
Add '#if defined(__linux__) || defined(__FreeBSD__)' around JITLoaderGDB
and ProcessElfCore, which are only built on Linux and FreeBSD.
llvm-svn: 203107
hold a strong pointer to that extended backtrace thread in the Process
just like we do for asking a thread's extended backtrace.
Also, give extended backtrace threads an invalid ThreadIndexID number.
We'll still give them valid thread_id's. Clients who want to know the
original thread's IndexID can call GetExtendedBacktraceOriginatingIndexID().
<rdar://problem/16126034>
llvm-svn: 203088
ProcessGDBRemote::GetAuxvData obtains the auxv from a remote gdbserver (via a binary-data packet), and returns the data as a DataBufferSP.
The patch includes a small fix to GDBRemoteCommunicationClient::SendPacketsAndConcatenateResponses() to support binary file format packet returns (by not assuming each binary packet is a null-terminated string when concatenating them).
llvm-svn: 202907
This change uses a fixed known offset for the Linux i386 DR0 register.
This change also undoes the 32-bit wordsize change from r169645 that
revolved around being 32-bit/64-bit friendly in
WriteRegOperation::Execute within the Linux ProcessMonitor.cpp. I ran
all the tests on x86_64 Linux with no failures. I also ran some simple
tests with 32-bit Linux exe on x86_64 host and 32-bit linux exe on
i686 32-bit host and these worked fine.
Note (from Todd): the UserData struct in the Linux i386 register
context (only used by Linux i386 host running Linux 32-bit inferior)
is out of sync with what shows up in the sys/user.h for an 32-bit
Linux build (per an earlier change of mine to make it look more like
x86_64 host running x86 exe). I think we should (1) make i386 Linux
targets run using the same register context (and correct ones) on i386
and x86_64 linux hosts if that is possible, and (2) we could use some
tests around the register handling, particularly to verify things like
DR0 registers are in the right spots on host/target combos that we can
verify vs. known correct values.
Change by Matthew Gardiner.
llvm-svn: 202887
The following two tests showed up as XFAIL even though they should
always be skipped on Linux, due to the @unittest2.expectedFailure
annotation appearing above the @dsym_test annotation:
TestObjCNewSyntax.ObjCNewSyntaxTestCase.test_expr_with_dsym
TestBlocks.BlocksTestCase.test_expr_with_dsym.
For those two, I simply moved the @dsym_test annotation to the top so
that it would be marked for skip ahead of being marked for XFAIL.
TestObjCNewSyntax.ObjCNewSyntaxTestCase.test_expr_with_dwarf I marked
as @skipIfLinux since my understanding is that isn't a valid test to
run on Linux. So rather than categorize as a fail (i.e. something
wrong to be fixed), just skip it. (My recent changes to Linux tests
have been following that model: if it could never work, skip; if it's
broken, mark XFAIL so we can easily track, fix, notice the fix and
adjust accordingly).
TestDeadStrip.DeadStripTestCase.test_with_dwarf I had previously
marked as XFAIL but this would never work on Linux with the current
linker AFAICT. Marked it as skip.
llvm-svn: 202788
read during materialization. First of all, report
if we can't read the data for some reason. Second,
consult the ValueObject's error and report that if
there's some problem.
<rdar://problem/16074201>
llvm-svn: 202552
This seems a little more straightforward and is equivalent to r201457
for ELF core files. A case for FreeBSD i386 is also added (it was
incorrectly using the 64-bit register context and corrupting mememory).
Better (user-facing) error handling is still needed.
Review: http://llvm-reviews.chandlerc.com/D2765
llvm-svn: 202549
This change adds a missing include path to the
ObjC LanguageRuntime path to the MacOSX SystemRuntime
plugin's Makefile.
It also adds the panel and curses library to the liblldb
shared library linkage step.
Changes by Jevin Sweval with a minor tweak.
llvm-svn: 202547
I carefully reviewed exactly how the IOHandlers interact and found places where we weren't properly controlling things. There should be no overlapping prompts and all output should now come out in a controlled fashion.
<rdar://problem/16111293>
llvm-svn: 202525
I suspect I may have misrun the test previously for check-in
r202456 re: pr15258. This test fails consistently on my end.
I changed the test to expected failure on Linux.
llvm-svn: 202517
TestRegisterVariables.test_with_dwarf_and_run_command was being
skipped on Linux due to issues with clang. I converted it to a
@expectedFailureClang and no longer skip on Linux.
llvm-svn: 202515
TestConstVariables.py was disabled on Linux and marked as
unconditional expected failure. This change removes the Linux disable
and makes the expected failure conditional on using clang. The test
runs fine on gcc-built lldb.
llvm-svn: 202514