summaryrefslogtreecommitdiffstats
path: root/lldb
Commit message (Collapse)AuthorAgeFilesLines
* Remove Timer::Initialize routinePavel Labath2016-02-013-28/+12
| | | | | | | | | | | | | | | | | | | | Summary: I've run into an issue when running unit tests, where the underlying problem turned out to be that we were creating Timer objects (through several layers of indirection) without calling Timer::Initialize. Since Timer's thread-local storage was not properly initialized, we were overwriting gtest's own thread-local storage, causing test failures. Instead of requiring that every test calls Timer::Initialize(), I remove the function altogether: The thread-local storage can be initialized on-demand, and the g_file variable initialized to stdout and never changed, so I have simply removed it. Reviewers: clayborg, zturner, tberghammer Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D16722 llvm-svn: 259356
* Set correct ThreadStopInfo in case of trace eventAbhishek Aggarwal2016-02-014-15/+58
| | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: - The patch solves Bug 23478 and Bug 19311. Resolving Bug 23478 also resolves Bug 23039. Correct ThreadStopInfo is set for Linux and FreeBSD platforms. - Summary: When a trace event is reported, we need to check whether the trace event lands at a breakpoint site. If it lands at a breakpoint site then set the thread's StopInfo with the reason 'breakpoint'. Else, set the reason to be 'Trace'. Change-Id: I0af9765e782fd74bc0cead41548486009f8abb87 Signed-off-by: Abhishek Aggarwal <abhishek.a.aggarwal@intel.com> Reviewers: jingham, emaste, lldb-commits, clayborg, ovyalov Subscribers: emaste Differential Revision: http://reviews.llvm.org/D16720 llvm-svn: 259344
* Fixed a couple of places where we were getting the module from aJim Ingham2016-01-292-5/+21
| | | | | | | section and using it w/o checking that it was valid. This can cause crashes - usually when tearing down a target. llvm-svn: 259237
* Fix this test for the the switch in default for IgnoreBreakpoints in ↵Jim Ingham2016-01-291-1/+6
| | | | | | SBFrame.EvaluateExpression. llvm-svn: 259234
* Revert "fix up missing header from change r259084."Todd Fiala2016-01-291-1/+0
| | | | | | | | This change was made based on a bad signal from the Green Dragon LLDB builder. This change was not needed. Reverting out r259114. llvm-svn: 259216
* Fix crash in lldb-mi when stack variable name is nullptr. This always ↵Eugene Leviant2016-01-293-1/+34
| | | | | | happens when execution stops in try scope with unnamed catch clause llvm-svn: 259189
* Fix linking of lldb-server with BUILD_SHARED_LIBSPavel Labath2016-01-291-16/+11
| | | | | | | | | | | | | | | | | | | | Summary: The BUILD_SHARED_LIBS branch of lldb-server link flags was hopelessly broken, at least since we started restricting the symbols exported by liblldb. lldb-server depends on symbols from the lldb_private namespace, so it cannot link to the public interface of liblldb. Instead I make it link to the individual libraries constituting liblldb, just like it does in the !BUILD_SHARED_LIBS case. This does not make the BUILD_SHARED_LIBS build of lldb fully functional yet, due to the way liblldb dependencies are managed, but it's a step in that direction. Reviewers: zturner, tfiala Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D16678 llvm-svn: 259188
* Ignore breakpoints by default in SBFrame::EvaluateExpressionEugene Leviant2016-01-291-0/+3
| | | | llvm-svn: 259185
* [RenderScript] Remove unused RS commandEwan Crawford2016-01-292-55/+2
| | | | | | | | | | Patch deletes the 'language renderscript module probe' command. This command was present in the initial commit to help debug the plugin. However we haven't used it recently and it's functionality is unclear, so can be removed entirely. Also add back 'kernel coordinate' command, removed by accident in clang format patch r259056. llvm-svn: 259181
* Fix TestDataFormatterScript for Linux.Chaoren Lin2016-01-291-5/+4
| | | | | | | | | | | | | | Summary: m_function_name will contain a dummy name for the auto-generated function from the python script on Linux. Check for script name first. Reviewers: granata.enrico Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D16703 llvm-svn: 259153
* Fix a bug where type <formatter> list would ignore the -w argumentEnrico Granata2016-01-292-0/+7
| | | | | | rdar://24379879 llvm-svn: 259135
* Fix a bug where LLDB would not print the name of the function that a ↵Enrico Granata2016-01-297-3/+109
| | | | | | | | scripted summary is bound to rdar://24380076 llvm-svn: 259131
* fix up missing header from change r259084.Todd Fiala2016-01-281-0/+1
| | | | llvm-svn: 259114
* add back an Xcode-specific Makefile for header installationTodd Fiala2016-01-281-0/+23
| | | | llvm-svn: 259102
* Remove autoconf support from source directories.Eugene Zelenko2016-01-28104-2252/+0
| | | | | | Differential revision: http://reviews.llvm.org/D16662 llvm-svn: 259098
* Fix build after rL259070.Chaoren Lin2016-01-281-1/+1
| | | | llvm-svn: 259086
* Update lldb for API change in clang r259070.Manman Ren2016-01-281-1/+1
| | | | llvm-svn: 259084
* Fix an issue where the type <formatter> list command would not accept a ↵Enrico Granata2016-01-282-1/+27
| | | | | | | | valid argument and instead error out complaining about a malformed regex rdar://problem/24380025 llvm-svn: 259078
* [Renderscript] Clang-format the renderscript plugin.Aidan Dodds2016-01-282-754/+819
| | | | | | Run clang-format over the renderscript plugin and fix common formatting deviations. llvm-svn: 259056
* Fix const cast error for MSVC2015 build.Aidan Dodds2016-01-281-1/+1
| | | | | | | | | The Visual Studio 2015 build was failing with the following error: error C2440: 'initializing': cannot convert from 'const char [12]' to 'char *' This should fix the problem by initializing a non const char array, instead of taking a pointer to const static data. llvm-svn: 259042
* fixed Xcode gtest build failureTodd Fiala2016-01-281-4/+4
| | | | llvm-svn: 259028
* modify Xcode build to use cmake/ninja for internal llvm/clangTodd Fiala2016-01-286-420/+495
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change restores the Xcode build to working after Makefile support was stripped from LLVM and clang recently. With this change, the Xcode build now requires cmake (2.8.12.2+). The cmake must either be on the path that Xcode sees, or it must exist in one of the following locations: * /usr/local/bin/cmake * /opt/local/bin/cmake * $HOME/bin/cmake If the ninja build tool is present on the path, it will be used. If not, ninja will be cloned (via git), bootstrap-built, and used for the llvm/clang build. LLDB now requires a minimum deployment target of OS X 10.9. Prior to this, it was 10.8. The llvm/clang cmake build will not run with Xcode 7.2 or Xcode 7.3 beta's compiler with the minimum deployment target set to anything lower than 10.9. This is related to #include <atomic>. When llvm or clang source code does not exist in the lldb tree, it will be cloned via git using http://llvm.org/git/{project}.git. Previously it used SVN. If this causes any heartache, we can make this smarter, autodetect an embedded svn and use svn instead. (And/or use SVN if a git command is not available). This change also fixes an lldb-mi linkage failure (needed libncurses) as exposed by one of the LLVM libs. llvm-svn: 259027
* A while back in revison 244716 we added support for getting the host OS ↵Greg Clayton2016-01-282-9/+4
| | | | | | | | version info from debugserver. We added keys to "qHostInfo" that were "osmajor", "osminor" and "ospatch", but no one ever parsed those, so I am removing them from debugserver. We accidentally also added a "version" key to qHostInfo instead of "os_version". So now we need to support both "version" and "os_version" in qHostInfo since we have debugserver binaries out in the wild that support this old packet type. I have updated debugserver ot use the correct "os_version" for future compatability or correctness. <rdar://problem/24378699> llvm-svn: 259003
* Revert "Resubmit r258759 with proper unicode handling."Zachary Turner2016-01-272-2/+3
| | | | | | This reverts commit 2c79d60214e146b13b233392a859b4f79340e90e. llvm-svn: 258978
* Resubmit r258759 with proper unicode handling.Zachary Turner2016-01-272-3/+2
| | | | | | | | | Instead of opening the file in unicode mode, we need only encode data which potentially has non-ASCII characters as UTF8 before writing. This should work across both Python versions, and is also far simpler than anything else discussed. llvm-svn: 258969
* Fix some python 3 incompatibilities that went in overnight.Zachary Turner2016-01-272-2/+4
| | | | | | | | * basestring is not a thing anymore. Must use `six.string_types`. * Must use from __future__ import print_function in every new test file. llvm-svn: 258967
* Refactor some of the xfail / skip decorators to share logic.Zachary Turner2016-01-274-74/+122
| | | | | | | | | | | Previously the logic of skipIf and expectedFailure were 99% the same, but they took different sets of arguments since they were maintained separately, and had slightly differences in their behavior. This makes everything consistent, there is now only one real implementation, and the previous ones are changed to use the single master implementation. llvm-svn: 258966
* Don't automtically try to import pexpect in lldbpexpect.Zachary Turner2016-01-271-45/+51
| | | | | | | | | | Since pexpect doesn't exist on Windows, tests which are xfail'ed are not being run at all because they are failing when the file is imported due to the `import pexpect`. This puts the import behind a conditional and makes an empty base class in the case where pexpect is not present. llvm-svn: 258965
* XFail TestCPPAuto on Windows until we can find the root problem.Adrian McCarthy2016-01-271-0/+1
| | | | | | llvm.org/pr26339 llvm-svn: 258943
* Decorarte TestInferiorAssert xfails on AArch64 LinuxOmair Javaid2016-01-271-3/+3
| | | | | | This patch decorates some of TestInferiorAssert test cases with expectedFailureLinux on AArch64. llvm-svn: 258930
* Fix linking with LLVM_LINK_LLVM_DYLIB=ONPavel Labath2016-01-271-2/+2
| | | | | | | | | | | | | | | Linking with LLVM shared libraries currently produces linker errors. This works around the issue (pr24953) by disabling linking with llvm so for lldb libraries. Patch by Evangelos Foutras. Reviewers: zturner Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D16293 llvm-svn: 258921
* [LLDB][MIPS] A small fix in GetBreakableLoadAddress() for MIPSBhushan D. Attarde2016-01-278-13/+143
| | | | | | | | | | | | | SUMMARY: Get the load address for the address given by symbol and function. Earlier, this was done for function only, this patch does it for symbol too. This patch also adds TestAvoidBreakpointInDelaySlot.py to test this change. Reviewers: clayborg Subscribers: labath, zturner, mohit.bhakkad, sagar, jaydeep, lldb-commits Differential Revision: http://reviews.llvm.org/D16049 llvm-svn: 258919
* Revert r258546.Saleem Abdulrasool2016-01-262-2/+0
| | | | | | | | | Seems that the patch was rebased on top of another change which obsoleted the change but wasnt caught. Thanks to nbjoerg for pointing this out! llvm-svn: 258821
* Update for LLVM changeBenjamin Kramer2016-01-263-6/+6
| | | | llvm-svn: 258819
* [RenderScript] Provide option to specify a single allocation to printEwan Crawford2016-01-262-22/+23
| | | | | | | | Patch replaces the 'renderscript allocation list' command flag --refresh, with a new option --id <ID>. This new option only prints the details of a single allocation with a given id, rather than printing all the allocations. Functionality from the removed '--refresh' flag will be moved into its own command in a subsequent commit. llvm-svn: 258800
* Reverting r258759 as it is breaking the OSX buildEnrico Granata2016-01-262-1/+2
| | | | llvm-svn: 258791
* Fix TestRerun.py on Windows.Zachary Turner2016-01-261-25/+6
| | | | | | | | This is another example of a test that was looking for the thread at index 0 instead of requesting the thread that was stopped at the created breakpoint. This assumption isn't true on Windows 10. llvm-svn: 258764
* Fix the lldbinline tests so they make well-formed Makefiles.Sean Callanan2016-01-261-1/+1
| | | | | | | | | lldbinline tests previously did not run correctly unless there was already a Makefile for them. This was because the syntax of the emitted Makefile made the default make rule be the "cleanup" rule, which is pretty unhelpful. Now the default rule is the one included from Makefile.rules, which is much better. llvm-svn: 258763
* Remove XFAIL Windows from a test that was fixed by r258758.Zachary Turner2016-01-261-1/+0
| | | | llvm-svn: 258761
* Write the session log file in UTF-8.Zachary Turner2016-01-262-2/+1
| | | | | | | | | | | Previously we were writing in the default encoding, which depends on the operating system and is not guaranteed to be unicode aware. On Python 3, this would lead to a situation where writing unicode text to the log file generates an exception. The fix here is to write session logs using the proper encoding, which incidentally fixes another test, so xfail is removed from that. llvm-svn: 258759
* Set symbol types for function symbols loaded from PE/COFFAdrian McCarthy2016-01-266-22/+40
| | | | | | | | | | | | | | | | This fixes the regression of several tests on Windows after rL258621. The root problem is that ObjectFilePECOFF was not setting type information for the symbols, and the new CL rejects symbols without type information, breaking functionality like thread step-over. The fix sets the type information for functions (and creates a TODO for other types). Along the way, I fixed some typos and formatting that made the code I was debugging harder to understand. In the long run, we should consider replacing most of ObjectFilePECOFF with the COFF parsing code from LLVM. Differential Revision: http://reviews.llvm.org/D16563 llvm-svn: 258758
* Fix TestSyntheticCapping for Python 3.Zachary Turner2016-01-261-19/+19
| | | | | | | | | | In Python 3, whitespace inconsistences are errors. This synthetic provider had mixed tabs and spaces, as well as inconsistent indentation widths. This led to the file not being imported, and naturally the test failing. No functional change here, just whitespace. llvm-svn: 258751
* Fix some issues with bytes and strings in Python 3.Zachary Turner2016-01-254-14/+15
| | | | | | | | | | | | | | | | | | SBProcess::ReadMemory and other related functions such as WriteMemory are returning Python string() objects. This means that in Python 3 that are returning Unicode objects. In reality they should be returning bytes objects which is the same as a string in Python 2, but different in Python 3. This patch updates the generated SWIG code to return Python bytes objects for all memory related functions. One quirk of this patch is that the C++ signature of ReadCStringFromMemory has it writing c-string data into a void*. This confuses our swig typemaps which expect that a void* means byte data. So I hacked up a custom typemap which maps this specific function to treat the void* as string data instead of byte data. llvm-svn: 258743
* Fix more occurrences of string/bytes/bytearray in swig typemaps.Zachary Turner2016-01-251-20/+44
| | | | llvm-svn: 258742
* Fix swig typemap for SBEvent.Zachary Turner2016-01-254-6/+147
| | | | | | | | | | | This needs to be able to handle bytes, strings, and bytearray objects. In Python 2 this was easy because bytes and strings are the same thing, but in Python 3 the 2 cases need to be handled separately. So as not to mix raw Python C API code with PythonDataObjects code, I've also introduced a PythonByteArray class to PythonDataObjects to make the paradigm used here consistent. llvm-svn: 258741
* Fix TestSourceManager.py on Windows.Adrian McCarthy2016-01-251-7/+6
| | | | | | | | Python 3.5 is picky about writing strings to binary files, so we now open the file in text mode, and we explicitly set the newline mode to avoid re-writing it with CR+LF on Windows (which causes git to think the file had changed). llvm-svn: 258704
* [LLDB][MIPS] Fix TestPrintStackTraces.pySagar Thakur2016-01-251-0/+4
| | | | | | | | | | | Patch by Nitesh Jain. Summary: The thread_start function in libc doesn't contain any epilogue and prologue instructions. Hence unwinding fail when we are stopped in thread_start. Reviewers: ovyalov, clayborg Subscribers: lldb-commits, mohit.bhakkad, sagar, bhushan, jaydeep Differential: reviews.llvm.org/D16136 llvm-svn: 258685
* [LLDB][MIPS] Fix TestExprsChar.pySagar Thakur2016-01-251-0/+1
| | | | | | | | | | | Patch by Nitesh Jain. Summary: When incorrect type used for 'char' then (at least) one of the expression evaluates to incorrect value. Please refer to bug llvm.org/pr23069 Reviewers: ovyalov, clayborg Subscribers: lldb-commits, mohit.bhakkad, sagar, bhushan, jaydeep Differential: reviews.llvm.org/D16132 llvm-svn: 258684
* [LLDB] Consider only valid symbols while resolving by addressMohit K. Bhakkad2016-01-234-1/+50
| | | | | | | | Reviewers: clayborg. Subscribers: jaydeep, bhushan, sagar, nitesh.jain, lldb-commits. Differential Revision: http://reviews.llvm.org/D16397 llvm-svn: 258621
* Skipped IncompleteModulesTestCase on OS XTodd Fiala2016-01-231-2/+1
| | | | | | | | | | | | This is hitting an assert in clang when evaluating the module load. I am seeing it locally on Xcode 7.3 public Beta 1 and on the llvm.org Green Dragon buildbot supposedly running Xcode 7.0. Tracked by: https://llvm.org/bugs/show_bug.cgi?id=26267 llvm-svn: 258602
OpenPOWER on IntegriCloud